* [PATCH v2] vmxnet3: Enable GRO support.
@ 2011-06-25 0:24 Jesse Gross
2011-06-25 1:43 ` Scott Goldman
2011-06-28 5:09 ` David Miller
0 siblings, 2 replies; 3+ messages in thread
From: Jesse Gross @ 2011-06-25 0:24 UTC (permalink / raw)
To: David Miller; +Cc: netdev, Shreyas Bhatewara, Scott Goldman, VMware PV-Drivers
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 <sbhatewara@vmware.com>
CC: Scott Goldman <scottjg@vmware.com>
CC: VMware PV-Drivers <pv-drivers@vmware.com>
Signed-off-by: Jesse Gross <jesse@nicira.com>
---
This applies on top of my previous vmxnet3 patch
"vmxnet3: Convert to new vlan model."
v2: Only use GRO when LRO is not active as suggested by Scott Goldman.
---
drivers/net/vmxnet3/vmxnet3_drv.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
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;
}
--
1.7.4.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* RE: [PATCH v2] vmxnet3: Enable GRO support.
2011-06-25 0:24 [PATCH v2] vmxnet3: Enable GRO support Jesse Gross
@ 2011-06-25 1:43 ` Scott Goldman
2011-06-28 5:09 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: Scott Goldman @ 2011-06-25 1:43 UTC (permalink / raw)
To: Jesse Gross, David Miller
Cc: netdev@vger.kernel.org, Shreyas Bhatewara, VMware PV-Drivers
Thanks again.
> 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 <sbhatewara@vmware.com>
> CC: Scott Goldman <scottjg@vmware.com>
> CC: VMware PV-Drivers <pv-drivers@vmware.com>
> Signed-off-by: Jesse Gross <jesse@nicira.com>
Signed-off-by: Scott J. Goldman <scottjg@vmware.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH v2] vmxnet3: Enable GRO support.
2011-06-25 0:24 [PATCH v2] vmxnet3: Enable GRO support Jesse Gross
2011-06-25 1:43 ` Scott Goldman
@ 2011-06-28 5:09 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2011-06-28 5:09 UTC (permalink / raw)
To: jesse; +Cc: netdev, sbhatewara, scottjg, pv-drivers
From: Jesse Gross <jesse@nicira.com>
Date: Fri, 24 Jun 2011 17:24:35 -0700
> 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 <sbhatewara@vmware.com>
> CC: Scott Goldman <scottjg@vmware.com>
> CC: VMware PV-Drivers <pv-drivers@vmware.com>
> Signed-off-by: Jesse Gross <jesse@nicira.com>
Applied, thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-06-28 5:09 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-06-25 0:24 [PATCH v2] vmxnet3: Enable GRO support Jesse Gross
2011-06-25 1:43 ` Scott Goldman
2011-06-28 5:09 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox