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: <f7e414eaef1f722ae125cf3601a0567136f973fc@linux.dev>
Date: Wed, 01 Oct 2025 00:56:49 +0000
From: "Zqiang" <qiang.zhang@...ux.dev>
To: "Jakub Kicinski" <kuba@...nel.org>
Cc: horms@...nel.org, davem@...emloft.net, pabeni@...hat.com,
 netdev@...r.kernel.org
Subject: Re: [PATCH] usbnet: Fix using smp_processor_id() in preemptible code
 warnings

> 
> On Wed, 01 Oct 2025 00:39:18 +0000 Zqiang wrote:
> 
> > 
> > We also call netif_rx() which historically wanted to be in bh context.
> >  I think that disabling bh in usbnet_resume_rx() may be a better idea. 
> >  
> >  Actually, the netif_rx() will disable bh internally when call from
> >  process context.
> > 
> Sigh. I said "historically". Commit under Fixes is very old
> so the fix needs to be backported. Look thru the git history 
> you'll see that netif_rx() did not disable BH when the bad commit 
> was written.
> 
> > 
> > but the skb_defer_rx_timestamp() is usually called in the bh or
> >  interrupt context.
> >  
> >  Anyway, I will disable bh in usbnet_resume_rx() and resend.
> > 
> If you think you have better solution, please do not hesitate 
> to propose.

Maybe we can use netif_receive_skb() instead of skb_defer_rx_timestamp()
and netif_rcv() in the usbnet_skb_return() and disbale bh in usbnet_resume_rx().

Any thoughts ?

Thanks
Zqiang

> 
> Also make sure you read
> https://www.kernel.org/doc/html/next/process/maintainer-netdev.html
> if you haven't already.
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ