]> Pileus Git - ~andy/linux/blobdiff - net/sctp/input.c
hlist: drop the node parameter from iterators
[~andy/linux] / net / sctp / input.c
index 8bd3c279427ef773ab1779a9d643d0fc1af2a183..4b2c83146aa7e5c47b46b8148d701a4fc3d2189e 100644 (file)
@@ -468,8 +468,7 @@ void sctp_icmp_proto_unreachable(struct sock *sk,
        } else {
                struct net *net = sock_net(sk);
 
-               if (timer_pending(&t->proto_unreach_timer) &&
-                   del_timer(&t->proto_unreach_timer))
+               if (del_timer(&t->proto_unreach_timer))
                        sctp_association_put(asoc);
 
                sctp_do_sm(net, SCTP_EVENT_T_OTHER,
@@ -785,13 +784,12 @@ static struct sctp_endpoint *__sctp_rcv_lookup_endpoint(struct net *net,
        struct sctp_hashbucket *head;
        struct sctp_ep_common *epb;
        struct sctp_endpoint *ep;
-       struct hlist_node *node;
        int hash;
 
        hash = sctp_ep_hashfn(net, ntohs(laddr->v4.sin_port));
        head = &sctp_ep_hashtable[hash];
        read_lock(&head->lock);
-       sctp_for_each_hentry(epb, node, &head->chain) {
+       sctp_for_each_hentry(epb, &head->chain) {
                ep = sctp_ep(epb);
                if (sctp_endpoint_is_match(ep, net, laddr))
                        goto hit;
@@ -877,7 +875,6 @@ static struct sctp_association *__sctp_lookup_association(
        struct sctp_ep_common *epb;
        struct sctp_association *asoc;
        struct sctp_transport *transport;
-       struct hlist_node *node;
        int hash;
 
        /* Optimize here for direct hit, only listening connections can
@@ -887,7 +884,7 @@ static struct sctp_association *__sctp_lookup_association(
                                 ntohs(peer->v4.sin_port));
        head = &sctp_assoc_hashtable[hash];
        read_lock(&head->lock);
-       sctp_for_each_hentry(epb, node, &head->chain) {
+       sctp_for_each_hentry(epb, &head->chain) {
                asoc = sctp_assoc(epb);
                transport = sctp_assoc_is_match(asoc, net, local, peer);
                if (transport)