summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/8021q/vlan_core.c11
-rw-r--r--net/core/dev.c17
2 files changed, 7 insertions, 21 deletions
diff --git a/net/8021q/vlan_core.c b/net/8021q/vlan_core.c
index 2d6e405fc49..6227248597c 100644
--- a/net/8021q/vlan_core.c
+++ b/net/8021q/vlan_core.c
@@ -79,6 +79,9 @@ static int vlan_gro_common(struct napi_struct *napi, struct vlan_group *grp,
{
struct sk_buff *p;
+ if (netpoll_rx_on(skb))
+ return GRO_NORMAL;
+
if (skb_bond_should_drop(skb))
goto drop;
@@ -98,7 +101,7 @@ static int vlan_gro_common(struct napi_struct *napi, struct vlan_group *grp,
return dev_gro_receive(napi, skb);
drop:
- return 2;
+ return GRO_DROP;
}
int vlan_gro_receive(struct napi_struct *napi, struct vlan_group *grp,
@@ -106,9 +109,6 @@ int vlan_gro_receive(struct napi_struct *napi, struct vlan_group *grp,
{
skb_gro_reset_offset(skb);
- if (netpoll_receive_skb(skb))
- return NET_RX_DROP;
-
return napi_skb_finish(vlan_gro_common(napi, grp, vlan_tci, skb), skb);
}
EXPORT_SYMBOL(vlan_gro_receive);
@@ -121,9 +121,6 @@ int vlan_gro_frags(struct napi_struct *napi, struct vlan_group *grp,
if (!skb)
return NET_RX_DROP;
- if (netpoll_receive_skb(skb))
- return NET_RX_DROP;
-
return napi_frags_finish(napi, skb,
vlan_gro_common(napi, grp, vlan_tci, skb));
}
diff --git a/net/core/dev.c b/net/core/dev.c
index 033d7ca28e6..7bd3c29c5a7 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -135,14 +135,6 @@
/* This should be increased if a protocol with a bigger head is added. */
#define GRO_MAX_HEAD (MAX_HEADER + 128)
-enum {
- GRO_MERGED,
- GRO_MERGED_FREE,
- GRO_HELD,
- GRO_NORMAL,
- GRO_DROP,
-};
-
/*
* The list of packet types we will receive (as opposed to discard)
* and the routines to invoke.
@@ -2474,6 +2466,9 @@ static int __napi_gro_receive(struct napi_struct *napi, struct sk_buff *skb)
{
struct sk_buff *p;
+ if (netpoll_rx_on(skb))
+ return GRO_NORMAL;
+
for (p = napi->gro_list; p; p = p->next) {
NAPI_GRO_CB(p)->same_flow = !compare_ether_header(
skb_mac_header(p), skb_gro_mac_header(skb));
@@ -2487,9 +2482,6 @@ int napi_skb_finish(int ret, struct sk_buff *skb)
{
int err = NET_RX_SUCCESS;
- if (netpoll_receive_skb(skb))
- return NET_RX_DROP;
-
switch (ret) {
case GRO_NORMAL:
return netif_receive_skb(skb);
@@ -2587,9 +2579,6 @@ int napi_frags_finish(struct napi_struct *napi, struct sk_buff *skb, int ret)
{
int err = NET_RX_SUCCESS;
- if (netpoll_receive_skb(skb))
- return NET_RX_DROP;
-
switch (ret) {
case GRO_NORMAL:
case GRO_HELD: