summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/broadcom/bnxt/bnxt.c
diff options
context:
space:
mode:
authorMichael Chan <mchan@broadcom.com>2015-10-26 05:27:57 +0300
committerDavid S. Miller <davem@davemloft.net>2015-10-26 08:36:15 +0300
commitd1611c3aba11ffa281bdd027aace52f5a370b8c5 (patch)
tree8684d9f42b7dd75b6a4ccfccdc0c709af0e6ff25 /drivers/net/ethernet/broadcom/bnxt/bnxt.c
parent3ed770f60317a02a5a5e4a7345dc13d8819f56e8 (diff)
downloadlinux-d1611c3aba11ffa281bdd027aace52f5a370b8c5.tar.xz
bnxt_en: Fix compile warnings when CONFIG_INET is not set.
bnxt_gro_skb() has unused variables when CONFIG_INET is not set. We really cannot support hardware GRO if CONFIG_INET is not set, so compile out bnxt_gro_skb() completely and define BNXT_FLAG_GRO to be 0 if CONFIG_INET is not set. This will effectively always disable hardware GRO if CONFIG_INET is not set. Signed-off-by: Michael Chan <mchan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/broadcom/bnxt/bnxt.c')
-rw-r--r--drivers/net/ethernet/broadcom/bnxt/bnxt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c
index 9e36f83e68f0..6c2e0c622831 100644
--- a/drivers/net/ethernet/broadcom/bnxt/bnxt.c
+++ b/drivers/net/ethernet/broadcom/bnxt/bnxt.c
@@ -852,6 +852,7 @@ static inline struct sk_buff *bnxt_gro_skb(struct bnxt_tpa_info *tpa_info,
struct rx_tpa_end_cmp_ext *tpa_end1,
struct sk_buff *skb)
{
+#ifdef CONFIG_INET
struct tcphdr *th;
int payload_off, tcp_opt_len = 0;
int len, nw_off;
@@ -866,7 +867,6 @@ static inline struct sk_buff *bnxt_gro_skb(struct bnxt_tpa_info *tpa_info,
if (TPA_END_GRO_TS(tpa_end))
tcp_opt_len = 12;
-#ifdef CONFIG_INET
if (tpa_info->gso_type == SKB_GSO_TCPV4) {
struct iphdr *iph;