summaryrefslogtreecommitdiff
path: root/drivers/net/xen-netfront.c
diff options
context:
space:
mode:
authorWei Liu <wei.liu2@citrix.com>2013-09-30 16:46:34 +0400
committerDavid S. Miller <davem@davemloft.net>2013-10-02 23:54:11 +0400
commit99d3d587b2b4314ccc8ea066cb327dfb523d598e (patch)
treef0778a5abe8e82de603cb28e8f2574fbcb1aa2a0 /drivers/net/xen-netfront.c
parentee002b64ec81db846b5518d73fd724a53b27fbf2 (diff)
downloadlinux-99d3d587b2b4314ccc8ea066cb327dfb523d598e.tar.xz
xen-netfront: convert to GRO API
Anirban was seeing netfront received MTU size packets, which downgraded throughput. The following patch makes netfront use GRO API which improves throughput for that case. Signed-off-by: Wei Liu <wei.liu2@citrix.com> Cc: Anirban Chakraborty <abchak@juniper.net> Cc: Ian Campbell <ian.campbell@citrix.com> Acked-by: Konrad Wilk <konrad.wilk@oracle.com> Acked-by: Ian Campbell <ian.campbell@citrix.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/xen-netfront.c')
-rw-r--r--drivers/net/xen-netfront.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/net/xen-netfront.c b/drivers/net/xen-netfront.c
index 36808bf25677..dd1011e55cb5 100644
--- a/drivers/net/xen-netfront.c
+++ b/drivers/net/xen-netfront.c
@@ -952,7 +952,7 @@ static int handle_incoming_queue(struct net_device *dev,
u64_stats_update_end(&stats->syncp);
/* Pass it up. */
- netif_receive_skb(skb);
+ napi_gro_receive(&np->napi, skb);
}
return packets_dropped;
@@ -1051,6 +1051,8 @@ err:
if (work_done < budget) {
int more_to_do = 0;
+ napi_gro_flush(napi, false);
+
local_irq_save(flags);
RING_FINAL_CHECK_FOR_RESPONSES(&np->rx, more_to_do);