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] [thread-next>] [day] [month] [year] [list]
Message-ID: <20260108090514.375a23fb@pumpkin>
Date: Thu, 8 Jan 2026 09:05:14 +0000
From: David Laight <david.laight.linux@...il.com>
To: Kunihiko Hayashi <hayashi.kunihiko@...ionext.com>
Cc: Andrew Lunn <andrew+netdev@...n.ch>, "David S. Miller"
 <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski
 <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>, netdev@...r.kernel.org,
 linux-kernel@...r.kernel.org
Subject: Re: [PATCH net 2/2] net: ethernet: ave: Replace udelay with
 usleep_range

On Thu,  8 Jan 2026 15:46:41 +0900
Kunihiko Hayashi <hayashi.kunihiko@...ionext.com> wrote:

> Replace udelay() with usleep_range() as notified by checkpatch.pl.

Nak.
Look at the code...

> 
>     CHECK: usleep_range is preferred over udelay; see function description
>     of usleep_range() and udelay().
>     #906: FILE: drivers/net/ethernet/socionext/sni_ave.c:906:
>     +       udelay(50);
> 
> Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@...ionext.com>
> ---
>  drivers/net/ethernet/socionext/sni_ave.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/ethernet/socionext/sni_ave.c b/drivers/net/ethernet/socionext/sni_ave.c
> index 4700998c4837..a3735d81a862 100644
> --- a/drivers/net/ethernet/socionext/sni_ave.c
> +++ b/drivers/net/ethernet/socionext/sni_ave.c
> @@ -903,11 +903,11 @@ static void ave_rxfifo_reset(struct net_device *ndev)
>  
>  	/* assert reset */
>  	writel(AVE_GRR_RXFFR, priv->base + AVE_GRR);
> -	udelay(50);
> +	usleep_range(50, 100);
>  
>  	/* negate reset */
>  	writel(0, priv->base + AVE_GRR);
> -	udelay(20);
> +	usleep_range(20, 40);
>  
>  	/* negate interrupt status */
>  	writel(AVE_GI_RXOVF, priv->base + AVE_GISR);


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ