From 213ade8ca8c854435d99e4d2927655b2ae4191e9 Mon Sep 17 00:00:00 2001 From: Jesse Gross Date: Fri, 24 Jun 2011 14:24:35 +0000 Subject: [PATCH] vmxnet3: Enable GRO support. When receiving packets from another guest on the same hypervisor, it's generally possible to receive large packets because no segmentation is necessary and these packets are handled by LRO. However, when doing routing or bridging we must disable LRO and lose this benefit. In these cases GRO can still be used and it is very effective because the packets which are segmented in the hypervisor are received very close together and can easily be merged. CC: Shreyas Bhatewara CC: Scott Goldman CC: VMware PV-Drivers Signed-off-by: Jesse Gross Signed-off-by: Scott J. Goldman Signed-off-by: David S. Miller --- drivers/net/vmxnet3/vmxnet3_drv.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/net/vmxnet3/vmxnet3_drv.c b/drivers/net/vmxnet3/vmxnet3_drv.c index c84b1dd..2c14736 100644 --- a/drivers/net/vmxnet3/vmxnet3_drv.c +++ b/drivers/net/vmxnet3/vmxnet3_drv.c @@ -1234,7 +1234,10 @@ vmxnet3_rq_rx_complete(struct vmxnet3_rx_queue *rq, if (unlikely(rcd->ts)) __vlan_hwaccel_put_tag(skb, rcd->tci); - netif_receive_skb(skb); + if (adapter->netdev->features & NETIF_F_LRO) + netif_receive_skb(skb); + else + napi_gro_receive(&rq->napi, skb); ctx->skb = NULL; } -- 2.7.4