lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20201209033314.GA38@DESKTOP-8REGVGF.localdomain>
Date:   Wed, 9 Dec 2020 11:33:14 +0800
From:   Sieng Piaw Liew <liew.s.piaw@...il.com>
To:     Eric Dumazet <eric.dumazet@...il.com>
Cc:     Florian Fainelli <f.fainelli@...il.com>,
        bcm-kernel-feedback-list@...adcom.com, netdev@...r.kernel.org,
        liew.s.piaw@...il.com
Subject: Re: [PATCH net-next] bcm63xx_enet: batch process rx path

On Fri, Dec 04, 2020 at 10:50:45AM +0100, Eric Dumazet wrote:
> 
> 
> On 12/4/20 6:46 AM, Sieng Piaw Liew wrote:
> > Use netif_receive_skb_list to batch process rx skb.
> > Tested on BCM6328 320 MHz using iperf3 -M 512, increasing performance
> > by 12.5%.
> > 
> 
> 
> 
> Well, the real question is why you do not simply use GRO,
> to get 100% performance gain or more for TCP flows.
> 
> 
> netif_receive_skb_list() is no longer needed,
> GRO layer already uses batching for non TCP packets.
> 
> We probably should mark is deprecated.
> 
> diff --git a/drivers/net/ethernet/broadcom/bcm63xx_enet.c b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
> index 916824cca3fda194c42fefec7f514ced1a060043..6fdbe231b7c1b27f523889bda8a20ab7eaab65a6 100644
> --- a/drivers/net/ethernet/broadcom/bcm63xx_enet.c
> +++ b/drivers/net/ethernet/broadcom/bcm63xx_enet.c
> @@ -391,7 +391,7 @@ static int bcm_enet_receive_queue(struct net_device *dev, int budget)
>                 skb->protocol = eth_type_trans(skb, dev);
>                 dev->stats.rx_packets++;
>                 dev->stats.rx_bytes += len;
> -               netif_receive_skb(skb);
> +               napi_gro_receive_skb(&priv->napi, skb);
>  
>         } while (--budget > 0);
>  

The bcm63xx router SoC does not have enough CPU power nor hardware
accelerator to process checksum validation fast enough for GRO/GSO.

I have tested napi_gro_receive() on LAN-WAN setup. The resulting
bandwidth dropped from 95Mbps wire speed down to 80Mbps. And it's
inconsistent, with spikes and drops of >5Mbps.

The ag71xx driver for ath79 router SoC reverted its use for the same
reason.
http://lists.infradead.org/pipermail/lede-commits/2017-October/004864.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ