]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - net/ipv4/fou.c
Merge tag 'for-linus-20180906' of git://git.kernel.dk/linux-block
[linux.git] / net / ipv4 / fou.c
index c9ec1603666bffcfb24597b933a05f53b6d83440..500a59906b8719eb40fc3f37a0dc535b10b3069e 100644 (file)
@@ -224,14 +224,14 @@ static int gue_udp_recv(struct sock *sk, struct sk_buff *skb)
        return 0;
 }
 
-static struct sk_buff **fou_gro_receive(struct sock *sk,
-                                       struct sk_buff **head,
-                                       struct sk_buff *skb)
+static struct sk_buff *fou_gro_receive(struct sock *sk,
+                                      struct list_head *head,
+                                      struct sk_buff *skb)
 {
-       const struct net_offload *ops;
-       struct sk_buff **pp = NULL;
        u8 proto = fou_from_sock(sk)->protocol;
        const struct net_offload **offloads;
+       const struct net_offload *ops;
+       struct sk_buff *pp = NULL;
 
        /* We can clear the encap_mark for FOU as we are essentially doing
         * one of two possible things.  We are either adding an L4 tunnel
@@ -305,13 +305,13 @@ static struct guehdr *gue_gro_remcsum(struct sk_buff *skb, unsigned int off,
        return guehdr;
 }
 
-static struct sk_buff **gue_gro_receive(struct sock *sk,
-                                       struct sk_buff **head,
-                                       struct sk_buff *skb)
+static struct sk_buff *gue_gro_receive(struct sock *sk,
+                                      struct list_head *head,
+                                      struct sk_buff *skb)
 {
        const struct net_offload **offloads;
        const struct net_offload *ops;
-       struct sk_buff **pp = NULL;
+       struct sk_buff *pp = NULL;
        struct sk_buff *p;
        struct guehdr *guehdr;
        size_t len, optlen, hdrlen, off;
@@ -397,7 +397,7 @@ static struct sk_buff **gue_gro_receive(struct sock *sk,
 
        skb_gro_pull(skb, hdrlen);
 
-       for (p = *head; p; p = p->next) {
+       list_for_each_entry(p, head, list) {
                const struct guehdr *guehdr2;
 
                if (!NAPI_GRO_CB(p)->same_flow)