aboutsummaryrefslogtreecommitdiffstats
path: root/net/sctp/sm_make_chunk.c
diff options
context:
space:
mode:
authorVlad Yasevich <vladislav.yasevich@hp.com>2007-10-24 16:10:00 -0400
committerVlad Yasevich <vladislav.yasevich@hp.com>2007-11-07 11:39:27 -0500
commit0ed90fb0f668fd07f14ae2007a809e8b26cd27a6 (patch)
tree114e48301b89a8e82f7238d8b691880607842947 /net/sctp/sm_make_chunk.c
parentb6157d8e03e1e780660a328f7183bcbfa4a93a19 (diff)
SCTP: Update RCU handling during the ADD-IP case
After learning more about rcu, it looks like the ADD-IP hadling doesn't need to call call_rcu_bh. All the rcu critical sections use rcu_read_lock, so using call_rcu_bh is wrong here. Now, restore the local_bh_disable() code blocks and use normal call_rcu() calls. Also restore the missing return statement. Signed-off-by: Vlad Yasevich <vladislav.yasevich@hp.com>
Diffstat (limited to 'net/sctp/sm_make_chunk.c')
-rw-r--r--net/sctp/sm_make_chunk.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/net/sctp/sm_make_chunk.c b/net/sctp/sm_make_chunk.c
index 5de4729fe993..c60564dd169d 100644
--- a/net/sctp/sm_make_chunk.c
+++ b/net/sctp/sm_make_chunk.c
@@ -2953,13 +2953,17 @@ static int sctp_asconf_param_success(struct sctp_association *asoc,
2953 /* This is always done in BH context with a socket lock 2953 /* This is always done in BH context with a socket lock
2954 * held, so the list can not change. 2954 * held, so the list can not change.
2955 */ 2955 */
2956 local_bh_disable();
2956 list_for_each_entry(saddr, &bp->address_list, list) { 2957 list_for_each_entry(saddr, &bp->address_list, list) {
2957 if (sctp_cmp_addr_exact(&saddr->a, &addr)) 2958 if (sctp_cmp_addr_exact(&saddr->a, &addr))
2958 saddr->use_as_src = 1; 2959 saddr->use_as_src = 1;
2959 } 2960 }
2961 local_bh_enable();
2960 break; 2962 break;
2961 case SCTP_PARAM_DEL_IP: 2963 case SCTP_PARAM_DEL_IP:
2962 retval = sctp_del_bind_addr(bp, &addr, call_rcu_bh); 2964 local_bh_disable();
2965 retval = sctp_del_bind_addr(bp, &addr);
2966 local_bh_enable();
2963 list_for_each(pos, &asoc->peer.transport_addr_list) { 2967 list_for_each(pos, &asoc->peer.transport_addr_list) {
2964 transport = list_entry(pos, struct sctp_transport, 2968 transport = list_entry(pos, struct sctp_transport,
2965 transports); 2969 transports);