* [PATCH] bgmac: Remove all offloading features, including GRO.
@ 2017-09-16 0:23 Rosen Penev
2017-09-16 0:34 ` Eric Dumazet
0 siblings, 1 reply; 16+ messages in thread
From: Rosen Penev @ 2017-09-16 0:23 UTC (permalink / raw)
To: netdev; +Cc: Rosen Penev
On a linksys E1200v1 (actually a crossflashed E1000v2), the offloading features give no measurable benefit to speed or latency. Furthermore, disabling GRO actually improves iperf performance by a whoppimg 3mbps. Results:
Currently:
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52410
[ ID] Interval Transfer Bandwidth Reads Dist(bin=16.0K)
[ 4] 0.00-10.02 sec 52.4 MBytes 43.8 Mbits/sec 641 75:181:12:1:1:0:0:371
[ 5] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52412
[ 5] 0.00-10.02 sec 52.4 MBytes 43.8 Mbits/sec 629 51:194:13:1:0:1:0:369
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52414
[ 4] 0.00-10.02 sec 51.9 MBytes 43.4 Mbits/sec 695 126:203:1:0:0:0:2:363
[ 5] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52416
[ 5] 0.00-10.01 sec 52.4 MBytes 43.9 Mbits/sec 626 57:186:10:0:0:0:0:373
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52420
[ 4] 0.00-10.02 sec 52.4 MBytes 43.8 Mbits/sec 605 36:179:16:1:0:1:0:372
[ 5] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52422
After disabling everything - including GRO:
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52440
[ ID] Interval Transfer Bandwidth Reads Dist(bin=16.0K)
[ 4] 0.00-10.01 sec 55.1 MBytes 46.2 Mbits/sec 672 180:82:0:0:1:0:0:409
[ 5] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52442
[ 5] 0.00-10.01 sec 56.0 MBytes 46.9 Mbits/sec 636 117:96:0:0:1:0:0:422
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52444
[ 4] 0.00-10.01 sec 55.4 MBytes 46.4 Mbits/sec 675 172:92:0:0:1:0:0:410
[ 5] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52446
[ 5] 0.00-10.01 sec 56.0 MBytes 46.9 Mbits/sec 633 119:90:0:1:1:0:0:422
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52448
[ 4] 0.00-10.01 sec 55.2 MBytes 46.3 Mbits/sec 688 157:123:0:0:2:0:0:406
v2: Changed napi_gro_receive to netif_receive_skb. Seems to have an identical result.
Signed-off-by: Rosen Penev <rosenp@gmail.com>
---
drivers/net/ethernet/broadcom/bgmac.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/broadcom/bgmac.c b/drivers/net/ethernet/broadcom/bgmac.c
index 48d672b204a4..1fb0053aeee7 100644
--- a/drivers/net/ethernet/broadcom/bgmac.c
+++ b/drivers/net/ethernet/broadcom/bgmac.c
@@ -483,7 +483,7 @@ static int bgmac_dma_rx_read(struct bgmac *bgmac, struct bgmac_dma_ring *ring,
skb->protocol = eth_type_trans(skb, bgmac->net_dev);
bgmac->net_dev->stats.rx_bytes += len;
bgmac->net_dev->stats.rx_packets++;
- napi_gro_receive(&bgmac->napi, skb);
+ netif_receive_skb(skb);
handled++;
} while (0);
--
2.13.5
^ permalink raw reply related [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-16 0:23 [PATCH] bgmac: Remove all offloading features, including GRO Rosen Penev
@ 2017-09-16 0:34 ` Eric Dumazet
2017-09-16 0:38 ` rosenp
0 siblings, 1 reply; 16+ messages in thread
From: Eric Dumazet @ 2017-09-16 0:34 UTC (permalink / raw)
To: Rosen Penev; +Cc: netdev
On Fri, 2017-09-15 at 17:23 -0700, Rosen Penev wrote:
> On a linksys E1200v1 (actually a crossflashed E1000v2), the offloading features give no measurable benefit to speed or latency. Furthermore, disabling GRO actually improves iperf performance by a whoppimg 3mbps. Results:
>
> Currently:
>
> v2: Changed napi_gro_receive to netif_receive_skb. Seems to have an identical result.
>
> Signed-off-by: Rosen Penev <rosenp@gmail.com>
> ---
> drivers/net/ethernet/broadcom/bgmac.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/broadcom/bgmac.c b/drivers/net/ethernet/broadcom/bgmac.c
> index 48d672b204a4..1fb0053aeee7 100644
> --- a/drivers/net/ethernet/broadcom/bgmac.c
> +++ b/drivers/net/ethernet/broadcom/bgmac.c
> @@ -483,7 +483,7 @@ static int bgmac_dma_rx_read(struct bgmac *bgmac, struct bgmac_dma_ring *ring,
> skb->protocol = eth_type_trans(skb, bgmac->net_dev);
> bgmac->net_dev->stats.rx_bytes += len;
> bgmac->net_dev->stats.rx_packets++;
> - napi_gro_receive(&bgmac->napi, skb);
> + netif_receive_skb(skb);
> handled++;
> } while (0);
>
And have you tested 1Gbit link speed ?
( Or 2.5 Gbit link speed )
If you want to disable GRO on your host, fine : you can use ethtool -K
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-16 0:34 ` Eric Dumazet
@ 2017-09-16 0:38 ` rosenp
2017-09-16 6:04 ` Florian Fainelli
0 siblings, 1 reply; 16+ messages in thread
From: rosenp @ 2017-09-16 0:38 UTC (permalink / raw)
To: Eric Dumazet; +Cc: netdev
I have not. Unfortunately I own no gigabit hardware to test this on.
The MIPS CPU runs at 300MHz on my unit.
On Fri, 2017-09-15 at 17:34 -0700, Eric Dumazet wrote:
> On Fri, 2017-09-15 at 17:23 -0700, Rosen Penev wrote:
> > On a linksys E1200v1 (actually a crossflashed E1000v2), the
> > offloading features give no measurable benefit to speed or latency.
> > Furthermore, disabling GRO actually improves iperf performance by a
> > whoppimg 3mbps. Results:
> >
> > Currently:
> >
> > v2: Changed napi_gro_receive to netif_receive_skb. Seems to have an
> > identical result.
> >
> > Signed-off-by: Rosen Penev <rosenp@gmail.com>
> > ---
> > drivers/net/ethernet/broadcom/bgmac.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/net/ethernet/broadcom/bgmac.c
> > b/drivers/net/ethernet/broadcom/bgmac.c
> > index 48d672b204a4..1fb0053aeee7 100644
> > --- a/drivers/net/ethernet/broadcom/bgmac.c
> > +++ b/drivers/net/ethernet/broadcom/bgmac.c
> > @@ -483,7 +483,7 @@ static int bgmac_dma_rx_read(struct bgmac
> > *bgmac, struct bgmac_dma_ring *ring,
> > skb->protocol = eth_type_trans(skb, bgmac-
> > >net_dev);
> > bgmac->net_dev->stats.rx_bytes += len;
> > bgmac->net_dev->stats.rx_packets++;
> > - napi_gro_receive(&bgmac->napi, skb);
> > + netif_receive_skb(skb);
> > handled++;
> > } while (0);
> >
>
> And have you tested 1Gbit link speed ?
> ( Or 2.5 Gbit link speed )
>
> If you want to disable GRO on your host, fine : you can use ethtool
> -K
>
>
>
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-16 0:38 ` rosenp
@ 2017-09-16 6:04 ` Florian Fainelli
2017-09-20 21:27 ` rosenp
0 siblings, 1 reply; 16+ messages in thread
From: Florian Fainelli @ 2017-09-16 6:04 UTC (permalink / raw)
To: rosenp, Eric Dumazet; +Cc: netdev
On September 15, 2017 5:38:42 PM PDT, rosenp@gmail.com wrote:
>I have not. Unfortunately I own no gigabit hardware to test this on.
>The MIPS CPU runs at 300MHz on my unit.
>
bgmac is used on Gigabit capable hardware, like Northstar and Northstar Plus, and others too, so unless you can get access to such HW or get confirmation from someone that your patches changes something, I would just drop this change and not bother. This is already not 100mbits/sec linerate...
>On Fri, 2017-09-15 at 17:34 -0700, Eric Dumazet wrote:
>> On Fri, 2017-09-15 at 17:23 -0700, Rosen Penev wrote:
>> > On a linksys E1200v1 (actually a crossflashed E1000v2), the
>> > offloading features give no measurable benefit to speed or latency.
>> > Furthermore, disabling GRO actually improves iperf performance by a
>> > whoppimg 3mbps. Results:
>> >
>> > Currently:
>> >
>> > v2: Changed napi_gro_receive to netif_receive_skb. Seems to have an
>> > identical result.
>> >
>> > Signed-off-by: Rosen Penev <rosenp@gmail.com>
>> > ---
>> > drivers/net/ethernet/broadcom/bgmac.c | 2 +-
>> > 1 file changed, 1 insertion(+), 1 deletion(-)
>> >
>> > diff --git a/drivers/net/ethernet/broadcom/bgmac.c
>> > b/drivers/net/ethernet/broadcom/bgmac.c
>> > index 48d672b204a4..1fb0053aeee7 100644
>> > --- a/drivers/net/ethernet/broadcom/bgmac.c
>> > +++ b/drivers/net/ethernet/broadcom/bgmac.c
>> > @@ -483,7 +483,7 @@ static int bgmac_dma_rx_read(struct bgmac
>> > *bgmac, struct bgmac_dma_ring *ring,
>> > skb->protocol = eth_type_trans(skb, bgmac-
>> > >net_dev);
>> > bgmac->net_dev->stats.rx_bytes += len;
>> > bgmac->net_dev->stats.rx_packets++;
>> > - napi_gro_receive(&bgmac->napi, skb);
>> > + netif_receive_skb(skb);
>> > handled++;
>> > } while (0);
>> >
>>
>> And have you tested 1Gbit link speed ?
>> ( Or 2.5 Gbit link speed )
>>
>> If you want to disable GRO on your host, fine : you can use ethtool
>> -K
>>
>>
>>
(please don't top-post)
--
Florian
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-16 6:04 ` Florian Fainelli
@ 2017-09-20 21:27 ` rosenp
2017-09-20 21:32 ` Florian Fainelli
0 siblings, 1 reply; 16+ messages in thread
From: rosenp @ 2017-09-20 21:27 UTC (permalink / raw)
To: Florian Fainelli, Eric Dumazet; +Cc: netdev
Sorry for the noise. After more testing I've found out that the cause
was that I had BBR enabled on my laptop. Switching back to CUBIC fixed
the issue.
In other words, this patch is detrimental.
~67mbps - gro off
~87mbps - gro on
On Fri, 2017-09-15 at 23:04 -0700, Florian Fainelli wrote:
> On September 15, 2017 5:38:42 PM PDT, rosenp@gmail.com wrote:
> > I have not. Unfortunately I own no gigabit hardware to test this
> > on.
> > The MIPS CPU runs at 300MHz on my unit.
> >
>
> bgmac is used on Gigabit capable hardware, like Northstar and
> Northstar Plus, and others too, so unless you can get access to such
> HW or get confirmation from someone that your patches changes
> something, I would just drop this change and not bother. This is
> already not 100mbits/sec linerate...
>
> > On Fri, 2017-09-15 at 17:34 -0700, Eric Dumazet wrote:
> > > On Fri, 2017-09-15 at 17:23 -0700, Rosen Penev wrote:
> > > > On a linksys E1200v1 (actually a crossflashed E1000v2), the
> > > > offloading features give no measurable benefit to speed or
> > > > latency.
> > > > Furthermore, disabling GRO actually improves iperf performance
> > > > by a
> > > > whoppimg 3mbps. Results:
> > > >
> > > > Currently:
> > > >
> > > > v2: Changed napi_gro_receive to netif_receive_skb. Seems to
> > > > have an
> > > > identical result.
> > > >
> > > > Signed-off-by: Rosen Penev <rosenp@gmail.com>
> > > > ---
> > > > drivers/net/ethernet/broadcom/bgmac.c | 2 +-
> > > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > > >
> > > > diff --git a/drivers/net/ethernet/broadcom/bgmac.c
> > > > b/drivers/net/ethernet/broadcom/bgmac.c
> > > > index 48d672b204a4..1fb0053aeee7 100644
> > > > --- a/drivers/net/ethernet/broadcom/bgmac.c
> > > > +++ b/drivers/net/ethernet/broadcom/bgmac.c
> > > > @@ -483,7 +483,7 @@ static int bgmac_dma_rx_read(struct bgmac
> > > > *bgmac, struct bgmac_dma_ring *ring,
> > > > skb->protocol = eth_type_trans(skb,
> > > > bgmac-
> > > > > net_dev);
> > > >
> > > > bgmac->net_dev->stats.rx_bytes += len;
> > > > bgmac->net_dev->stats.rx_packets++;
> > > > - napi_gro_receive(&bgmac->napi, skb);
> > > > + netif_receive_skb(skb);
> > > > handled++;
> > > > } while (0);
> > > >
> > >
> > > And have you tested 1Gbit link speed ?
> > > ( Or 2.5 Gbit link speed )
> > >
> > > If you want to disable GRO on your host, fine : you can use
> > > ethtool
> > > -K
> > >
> > >
> > >
>
> (please don't top-post)
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-20 21:27 ` rosenp
@ 2017-09-20 21:32 ` Florian Fainelli
0 siblings, 0 replies; 16+ messages in thread
From: Florian Fainelli @ 2017-09-20 21:32 UTC (permalink / raw)
To: rosenp, Eric Dumazet; +Cc: netdev
On 09/20/2017 02:27 PM, rosenp@gmail.com wrote:
> Sorry for the noise. After more testing I've found out that the cause
> was that I had BBR enabled on my laptop. Switching back to CUBIC fixed
> the issue.
>
> In other words, this patch is detrimental.
Quite unsurprisingly, thanks for coming back, and please don't top-post
on netdev.
>
> ~67mbps - gro off
> ~87mbps - gro on
>
> On Fri, 2017-09-15 at 23:04 -0700, Florian Fainelli wrote:
>> On September 15, 2017 5:38:42 PM PDT, rosenp@gmail.com wrote:
>>> I have not. Unfortunately I own no gigabit hardware to test this
>>> on.
>>> The MIPS CPU runs at 300MHz on my unit.
>>>
>>
>> bgmac is used on Gigabit capable hardware, like Northstar and
>> Northstar Plus, and others too, so unless you can get access to such
>> HW or get confirmation from someone that your patches changes
>> something, I would just drop this change and not bother. This is
>> already not 100mbits/sec linerate...
>>
>>> On Fri, 2017-09-15 at 17:34 -0700, Eric Dumazet wrote:
>>>> On Fri, 2017-09-15 at 17:23 -0700, Rosen Penev wrote:
>>>>> On a linksys E1200v1 (actually a crossflashed E1000v2), the
>>>>> offloading features give no measurable benefit to speed or
>>>>> latency.
>>>>> Furthermore, disabling GRO actually improves iperf performance
>>>>> by a
>>>>> whoppimg 3mbps. Results:
>>>>>
>>>>> Currently:
>>>>>
>>>>> v2: Changed napi_gro_receive to netif_receive_skb. Seems to
>>>>> have an
>>>>> identical result.
>>>>>
>>>>> Signed-off-by: Rosen Penev <rosenp@gmail.com>
>>>>> ---
>>>>> drivers/net/ethernet/broadcom/bgmac.c | 2 +-
>>>>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>>>>
>>>>> diff --git a/drivers/net/ethernet/broadcom/bgmac.c
>>>>> b/drivers/net/ethernet/broadcom/bgmac.c
>>>>> index 48d672b204a4..1fb0053aeee7 100644
>>>>> --- a/drivers/net/ethernet/broadcom/bgmac.c
>>>>> +++ b/drivers/net/ethernet/broadcom/bgmac.c
>>>>> @@ -483,7 +483,7 @@ static int bgmac_dma_rx_read(struct bgmac
>>>>> *bgmac, struct bgmac_dma_ring *ring,
>>>>> skb->protocol = eth_type_trans(skb,
>>>>> bgmac-
>>>>>> net_dev);
>>>>>
>>>>> bgmac->net_dev->stats.rx_bytes += len;
>>>>> bgmac->net_dev->stats.rx_packets++;
>>>>> - napi_gro_receive(&bgmac->napi, skb);
>>>>> + netif_receive_skb(skb);
>>>>> handled++;
>>>>> } while (0);
>>>>>
>>>>
>>>> And have you tested 1Gbit link speed ?
>>>> ( Or 2.5 Gbit link speed )
>>>>
>>>> If you want to disable GRO on your host, fine : you can use
>>>> ethtool
>>>> -K
>>>>
>>>>
>>>>
>>
>> (please don't top-post)
--
Florian
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-16 0:03 ` Eric Dumazet
2017-09-16 0:10 ` rosenp
@ 2017-09-16 3:56 ` David Miller
1 sibling, 0 replies; 16+ messages in thread
From: David Miller @ 2017-09-16 3:56 UTC (permalink / raw)
To: eric.dumazet; +Cc: f.fainelli, rosenp, netdev, zajec5, nbd
From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Fri, 15 Sep 2017 17:03:30 -0700
> On Fri, 2017-09-15 at 15:54 -0700, Florian Fainelli wrote:
>> On September 15, 2017 3:22:18 PM PDT, Rosen Penev <rosenp@gmail.com>
>> wrote:
>> >On a linksys E1200v1 (actually a crossflashed E1000v2), the
>> offloading
>> >features give no measurable benefit to speed or latency. Furthermore,
>> >disabling GRO actually improves iperf performance by a whoppimg
>> 3mbps.
>>
>> Do you have a way to generate gigabit tests and see what results you
>> are getting? We probably are not going to see a 30% improvement just
>> by extrapolation.
>>
> +1
>
> It seems silly to remove NETIF_F_SG | NETIF_F_IP_CSUM |
> NETIF_F_IPV6_CSUM from dev->features, yet leave the dead-code in the
> driver to handle these features.
>
> And of course GRO was not removed, meaning the bench results were non
> conclusive.
My sentiments exactly, I think this is a completely unwise change.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-16 0:18 ` Eric Dumazet
2017-09-16 0:24 ` rosenp
@ 2017-09-16 0:25 ` Denys Fedoryshchenko
1 sibling, 0 replies; 16+ messages in thread
From: Denys Fedoryshchenko @ 2017-09-16 0:25 UTC (permalink / raw)
To: Eric Dumazet; +Cc: rosenp, Florian Fainelli, netdev, zajec5, nbd, netdev-owner
On 2017-09-16 03:18, Eric Dumazet wrote:
> On Fri, 2017-09-15 at 17:10 -0700, rosenp@gmail.com wrote:
>> Ok fair enough. Will only disable GRO in the driver.
>
> Well, do not even try.
>
> NETIF_F_SOFT_FEATURES is set by core networking stack in
> register_netdevice(), ( commit 212b573f5552c60265da721ff9ce32e3462a2cdd
> )
>
> Absolutely no driver disables GRO (excepts the ones playing with LRO)
I believe also iperf is definitely inconclusive test.
Except iperf there is lot of different workloads and configurations,
that might have different results.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-16 0:18 ` Eric Dumazet
@ 2017-09-16 0:24 ` rosenp
2017-09-16 0:25 ` Denys Fedoryshchenko
1 sibling, 0 replies; 16+ messages in thread
From: rosenp @ 2017-09-16 0:24 UTC (permalink / raw)
To: Eric Dumazet; +Cc: Florian Fainelli, netdev, zajec5, nbd
netif_receive_skb seems to have the same effect as "ethtool -K eth0 gro
off".
On Fri, 2017-09-15 at 17:18 -0700, Eric Dumazet wrote:
> On Fri, 2017-09-15 at 17:10 -0700, rosenp@gmail.com wrote:
> > Ok fair enough. Will only disable GRO in the driver.
>
> Well, do not even try.
>
> NETIF_F_SOFT_FEATURES is set by core networking stack in
> register_netdevice(), ( commit
> 212b573f5552c60265da721ff9ce32e3462a2cdd
> )
>
> Absolutely no driver disables GRO (excepts the ones playing with LRO)
>
>
>
>
>
>
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-16 0:10 ` rosenp
@ 2017-09-16 0:18 ` Eric Dumazet
2017-09-16 0:24 ` rosenp
2017-09-16 0:25 ` Denys Fedoryshchenko
0 siblings, 2 replies; 16+ messages in thread
From: Eric Dumazet @ 2017-09-16 0:18 UTC (permalink / raw)
To: rosenp; +Cc: Florian Fainelli, netdev, zajec5, nbd
On Fri, 2017-09-15 at 17:10 -0700, rosenp@gmail.com wrote:
> Ok fair enough. Will only disable GRO in the driver.
Well, do not even try.
NETIF_F_SOFT_FEATURES is set by core networking stack in
register_netdevice(), ( commit 212b573f5552c60265da721ff9ce32e3462a2cdd
)
Absolutely no driver disables GRO (excepts the ones playing with LRO)
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-16 0:03 ` Eric Dumazet
@ 2017-09-16 0:10 ` rosenp
2017-09-16 0:18 ` Eric Dumazet
2017-09-16 3:56 ` David Miller
1 sibling, 1 reply; 16+ messages in thread
From: rosenp @ 2017-09-16 0:10 UTC (permalink / raw)
To: Eric Dumazet, Florian Fainelli; +Cc: netdev, zajec5, nbd
Ok fair enough. Will only disable GRO in the driver.
Tests were done using "ethtool -K eth0 gro off" and on.
On Fri, 2017-09-15 at 17:03 -0700, Eric Dumazet wrote:
> On Fri, 2017-09-15 at 15:54 -0700, Florian Fainelli wrote:
> > On September 15, 2017 3:22:18 PM PDT, Rosen Penev <rosenp@gmail.com
> > >
> > wrote:
> > > On a linksys E1200v1 (actually a crossflashed E1000v2), the
> >
> > offloading
> > > features give no measurable benefit to speed or latency.
> > > Furthermore,
> > > disabling GRO actually improves iperf performance by a whoppimg
> >
> > 3mbps.
> >
> > Do you have a way to generate gigabit tests and see what results
> > you
> > are getting? We probably are not going to see a 30% improvement
> > just
> > by extrapolation.
> >
>
> +1
>
> It seems silly to remove NETIF_F_SG | NETIF_F_IP_CSUM |
> NETIF_F_IPV6_CSUM from dev->features, yet leave the dead-code in the
> driver to handle these features.
>
> And of course GRO was not removed, meaning the bench results were non
> conclusive.
>
>
>
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-15 22:54 ` Florian Fainelli
@ 2017-09-16 0:03 ` Eric Dumazet
2017-09-16 0:10 ` rosenp
2017-09-16 3:56 ` David Miller
0 siblings, 2 replies; 16+ messages in thread
From: Eric Dumazet @ 2017-09-16 0:03 UTC (permalink / raw)
To: Florian Fainelli; +Cc: Rosen Penev, netdev, zajec5, nbd
On Fri, 2017-09-15 at 15:54 -0700, Florian Fainelli wrote:
> On September 15, 2017 3:22:18 PM PDT, Rosen Penev <rosenp@gmail.com>
> wrote:
> >On a linksys E1200v1 (actually a crossflashed E1000v2), the
> offloading
> >features give no measurable benefit to speed or latency. Furthermore,
> >disabling GRO actually improves iperf performance by a whoppimg
> 3mbps.
>
> Do you have a way to generate gigabit tests and see what results you
> are getting? We probably are not going to see a 30% improvement just
> by extrapolation.
>
+1
It seems silly to remove NETIF_F_SG | NETIF_F_IP_CSUM |
NETIF_F_IPV6_CSUM from dev->features, yet leave the dead-code in the
driver to handle these features.
And of course GRO was not removed, meaning the bench results were non
conclusive.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-15 23:14 ` David Miller
@ 2017-09-15 23:55 ` rosenp
0 siblings, 0 replies; 16+ messages in thread
From: rosenp @ 2017-09-15 23:55 UTC (permalink / raw)
To: David Miller; +Cc: netdev, zajec5, nbd
you're absolutely correct. will send an updated version shortly.
On Fri, 2017-09-15 at 16:14 -0700, David Miller wrote:
> From: Rosen Penev <rosenp@gmail.com>
> Date: Fri, 15 Sep 2017 15:22:18 -0700
>
> > On a linksys E1200v1 (actually a crossflashed E1000v2), the
> offloading features give no measurable benefit to speed or latency.
> Furthermore, disabling GRO actually improves iperf performance by a
> whoppimg 3mbps. Results:
> ...
> > - net_dev->features = NETIF_F_SG | NETIF_F_IP_CSUM |
> NETIF_F_IPV6_CSUM;
> > + net_dev->features &= NETIF_F_GRO;
> > net_dev->hw_features = net_dev->features;
>
> This doesn't disable GRO.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-15 22:22 Rosen Penev
2017-09-15 22:54 ` Florian Fainelli
@ 2017-09-15 23:14 ` David Miller
2017-09-15 23:55 ` rosenp
1 sibling, 1 reply; 16+ messages in thread
From: David Miller @ 2017-09-15 23:14 UTC (permalink / raw)
To: rosenp; +Cc: netdev, zajec5, nbd
From: Rosen Penev <rosenp@gmail.com>
Date: Fri, 15 Sep 2017 15:22:18 -0700
> On a linksys E1200v1 (actually a crossflashed E1000v2), the offloading features give no measurable benefit to speed or latency. Furthermore, disabling GRO actually improves iperf performance by a whoppimg 3mbps. Results:
...
> - net_dev->features = NETIF_F_SG | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM;
> + net_dev->features &= NETIF_F_GRO;
> net_dev->hw_features = net_dev->features;
This doesn't disable GRO.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] bgmac: Remove all offloading features, including GRO.
2017-09-15 22:22 Rosen Penev
@ 2017-09-15 22:54 ` Florian Fainelli
2017-09-16 0:03 ` Eric Dumazet
2017-09-15 23:14 ` David Miller
1 sibling, 1 reply; 16+ messages in thread
From: Florian Fainelli @ 2017-09-15 22:54 UTC (permalink / raw)
To: Rosen Penev, netdev, zajec5, nbd
On September 15, 2017 3:22:18 PM PDT, Rosen Penev <rosenp@gmail.com> wrote:
>On a linksys E1200v1 (actually a crossflashed E1000v2), the offloading
>features give no measurable benefit to speed or latency. Furthermore,
>disabling GRO actually improves iperf performance by a whoppimg 3mbps.
Do you have a way to generate gigabit tests and see what results you are getting? We probably are not going to see a 30% improvement just by extrapolation.
--
Florian
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH] bgmac: Remove all offloading features, including GRO.
@ 2017-09-15 22:22 Rosen Penev
2017-09-15 22:54 ` Florian Fainelli
2017-09-15 23:14 ` David Miller
0 siblings, 2 replies; 16+ messages in thread
From: Rosen Penev @ 2017-09-15 22:22 UTC (permalink / raw)
To: netdev, zajec5, nbd; +Cc: Rosen Penev
On a linksys E1200v1 (actually a crossflashed E1000v2), the offloading features give no measurable benefit to speed or latency. Furthermore, disabling GRO actually improves iperf performance by a whoppimg 3mbps. Results:
Currently:
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52410
[ ID] Interval Transfer Bandwidth Reads Dist(bin=16.0K)
[ 4] 0.00-10.02 sec 52.4 MBytes 43.8 Mbits/sec 641 75:181:12:1:1:0:0:371
[ 5] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52412
[ 5] 0.00-10.02 sec 52.4 MBytes 43.8 Mbits/sec 629 51:194:13:1:0:1:0:369
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52414
[ 4] 0.00-10.02 sec 51.9 MBytes 43.4 Mbits/sec 695 126:203:1:0:0:0:2:363
[ 5] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52416
[ 5] 0.00-10.01 sec 52.4 MBytes 43.9 Mbits/sec 626 57:186:10:0:0:0:0:373
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52420
[ 4] 0.00-10.02 sec 52.4 MBytes 43.8 Mbits/sec 605 36:179:16:1:0:1:0:372
[ 5] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52422
After disabling everything - including GRO:
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52440
[ ID] Interval Transfer Bandwidth Reads Dist(bin=16.0K)
[ 4] 0.00-10.01 sec 55.1 MBytes 46.2 Mbits/sec 672 180:82:0:0:1:0:0:409
[ 5] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52442
[ 5] 0.00-10.01 sec 56.0 MBytes 46.9 Mbits/sec 636 117:96:0:0:1:0:0:422
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52444
[ 4] 0.00-10.01 sec 55.4 MBytes 46.4 Mbits/sec 675 172:92:0:0:1:0:0:410
[ 5] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52446
[ 5] 0.00-10.01 sec 56.0 MBytes 46.9 Mbits/sec 633 119:90:0:1:1:0:0:422
[ 4] local 192.168.1.1 port 5001 connected with 192.168.1.100 port 52448
[ 4] 0.00-10.01 sec 55.2 MBytes 46.3 Mbits/sec 688 157:123:0:0:2:0:0:406
Signed-off-by: Rosen Penev <rosenp@gmail.com>
---
drivers/net/ethernet/broadcom/bgmac.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/broadcom/bgmac.c b/drivers/net/ethernet/broadcom/bgmac.c
index 48d672b204a4..c2db5673b073 100644
--- a/drivers/net/ethernet/broadcom/bgmac.c
+++ b/drivers/net/ethernet/broadcom/bgmac.c
@@ -1534,7 +1534,7 @@ int bgmac_enet_probe(struct bgmac *bgmac)
goto err_dma_free;
}
- net_dev->features = NETIF_F_SG | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM;
+ net_dev->features &= NETIF_F_GRO;
net_dev->hw_features = net_dev->features;
net_dev->vlan_features = net_dev->features;
--
2.13.5
^ permalink raw reply related [flat|nested] 16+ messages in thread
end of thread, other threads:[~2017-09-20 21:32 UTC | newest]
Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-16 0:23 [PATCH] bgmac: Remove all offloading features, including GRO Rosen Penev
2017-09-16 0:34 ` Eric Dumazet
2017-09-16 0:38 ` rosenp
2017-09-16 6:04 ` Florian Fainelli
2017-09-20 21:27 ` rosenp
2017-09-20 21:32 ` Florian Fainelli
-- strict thread matches above, loose matches on Subject: below --
2017-09-15 22:22 Rosen Penev
2017-09-15 22:54 ` Florian Fainelli
2017-09-16 0:03 ` Eric Dumazet
2017-09-16 0:10 ` rosenp
2017-09-16 0:18 ` Eric Dumazet
2017-09-16 0:24 ` rosenp
2017-09-16 0:25 ` Denys Fedoryshchenko
2017-09-16 3:56 ` David Miller
2017-09-15 23:14 ` David Miller
2017-09-15 23:55 ` rosenp
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).