X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=net%2Fsctp%2Finput.c;h=db76f1ab4ac2cb16b4568f0d9fbe4e3b90deaa1c;hb=31b055ef0c6116a27e9a787304ecf87a77d34764;hp=49d2cc751386f3208c67eed17ec9c3f15b801f50;hpb=718e47a573a43dba9a1673e0fc29fb36d3ef9769;p=deliverable%2Flinux.git diff --git a/net/sctp/input.c b/net/sctp/input.c index 49d2cc751386..db76f1ab4ac2 100644 --- a/net/sctp/input.c +++ b/net/sctp/input.c @@ -221,7 +221,7 @@ int sctp_rcv(struct sk_buff *skb) goto discard_release; /* Create an SCTP packet structure. */ - chunk = sctp_chunkify(skb, asoc, sk); + chunk = sctp_chunkify(skb, asoc, sk, GFP_ATOMIC); if (!chunk) goto discard_release; SCTP_INPUT_CB(skb)->chunk = chunk; @@ -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; }