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]
Date:   Tue, 17 May 2022 15:27:53 -0700
From:   Jakub Kicinski <kuba@...nel.org>
To:     Michael Trimarchi <michael@...rulasolutions.com>
Cc:     Joakim Zhang <qiangqing.zhang@....com>,
        Liam Girdwood <lgirdwood@...il.com>,
        Eric Dumazet <edumazet@...gle.com>,
        Paolo Abeni <pabeni@...hat.com>, netdev@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH] net: fec: Avoid to allocate rx buffer using ATOMIC
 in ndo_open

On Tue, 17 May 2022 12:05:44 +0200 Michael Trimarchi wrote:
> Subject: [RFC PATCH] net: fec: Avoid to allocate rx buffer using ATOMIC in ndo_open

nit: "Avoid allocating"

We need a commit message, guessing your motivation something like this
would be enough IMHO:

 Make ndo_open less sensitive to memory pressure.

> Signed-off-by: Michael Trimarchi <michael@...rulasolutions.com>
> ---
>  drivers/net/ethernet/freescale/fec_main.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/freescale/fec_main.c b/drivers/net/ethernet/freescale/fec_main.c
> index 9f33ec838b52..09eb6ea9a584 100644
> --- a/drivers/net/ethernet/freescale/fec_main.c
> +++ b/drivers/net/ethernet/freescale/fec_main.c
> @@ -3076,7 +3076,7 @@ fec_enet_alloc_rxq_buffers(struct net_device *ndev, unsigned int queue)
>  	rxq = fep->rx_queue[queue];
>  	bdp = rxq->bd.base;
>  	for (i = 0; i < rxq->bd.ring_size; i++) {
> -		skb = netdev_alloc_skb(ndev, FEC_ENET_RX_FRSIZE);
> +		skb = __netdev_alloc_skb(ndev, FEC_ENET_RX_FRSIZE, GFP_KERNEL);
>  		if (!skb)
>  			goto err_alloc;
>  

The patch LGTM, feel free to repost as non-RFC.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ