]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
bnxt_en: Refactor TPA code path.
authorMichael Chan <michael.chan@broadcom.com>
Thu, 29 Dec 2016 17:13:35 +0000 (12:13 -0500)
committerChuck Anderson <chuck.anderson@oracle.com>
Mon, 6 Mar 2017 21:35:18 +0000 (13:35 -0800)
Orabug: 25645429

Call tcp_gro_complete() in the common code path instead of the chip-
specific method.  The newer 5731x method is missing the call.

Signed-off-by: Michael Chan <michael.chan@broadcmo.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit 5910906ca9ee32943f67db24917f78a9ad1087db)
Signed-off-by: Brian Maly <brian.maly@oracle.com>
drivers/net/ethernet/broadcom/bnxt/bnxt.c

index c3f56b4060aad1eb9d371f89aa3beb7142f4a0f9..183e35bdf87623ee8df45bbfbbce886e6a95ed4b 100644 (file)
@@ -1131,7 +1131,6 @@ static struct sk_buff *bnxt_gro_func_5730x(struct bnxt_tpa_info *tpa_info,
                dev_kfree_skb_any(skb);
                return NULL;
        }
-       tcp_gro_complete(skb);
 
        if (nw_off) { /* tunnel */
                struct udphdr *uh = NULL;
@@ -1181,6 +1180,8 @@ static inline struct sk_buff *bnxt_gro_skb(struct bnxt *bp,
                       RX_TPA_END_CMP_PAYLOAD_OFFSET) >>
                      RX_TPA_END_CMP_PAYLOAD_OFFSET_SHIFT;
        skb = bp->gro_func(tpa_info, payload_off, TPA_END_GRO_TS(tpa_end), skb);
+       if (likely(skb))
+               tcp_gro_complete(skb);
 #endif
        return skb;
 }