diff options
author | David S. Miller <davem@davemloft.net> | 2016-02-17 15:41:55 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-02-17 15:41:55 -0500 |
commit | 7530e44c5403308e80b838fbe2d74f8a6ee007b5 (patch) | |
tree | 3296c8c8aa3a0f09f11df7f55afd34f330f289e1 /net/sctp/input.c | |
parent | bd4508e8507cbeee3c0fd96a1f96327b07c490b9 (diff) | |
parent | 1cd4d5c4326a7ed3bb0e346bd7d20f5057a80ae6 (diff) | |
download | blackbird-obmc-linux-7530e44c5403308e80b838fbe2d74f8a6ee007b5.tar.gz blackbird-obmc-linux-7530e44c5403308e80b838fbe2d74f8a6ee007b5.zip |
Merge branch 'sctp-cleanups'
Xin Long says:
====================
sctp: some cleanups for sctp
There are some unused function and redundant rcu locks should be
removed.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sctp/input.c')
-rw-r--r-- | net/sctp/input.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/sctp/input.c b/net/sctp/input.c index 49d2cc751386..21a2d6b7abaf 100644 --- a/net/sctp/input.c +++ b/net/sctp/input.c @@ -937,7 +937,6 @@ static struct sctp_association *__sctp_lookup_association( struct sctp_transport *t; struct sctp_association *asoc = NULL; - rcu_read_lock(); t = sctp_addrs_lookup_transport(net, local, peer); if (!t || !sctp_transport_hold(t)) goto out; @@ -949,7 +948,6 @@ static struct sctp_association *__sctp_lookup_association( sctp_transport_put(t); out: - rcu_read_unlock(); return asoc; } @@ -962,7 +960,9 @@ struct sctp_association *sctp_lookup_association(struct net *net, { struct sctp_association *asoc; + rcu_read_lock(); asoc = __sctp_lookup_association(net, laddr, paddr, transportp); + rcu_read_unlock(); return asoc; } |