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-next>] [day] [month] [year] [list]
Message-ID: <20250212103619.2560503-1-bigeasy@linutronix.de>
Date: Wed, 12 Feb 2025 11:36:17 +0100
From: Sebastian Andrzej Siewior <bigeasy@...utronix.de>
To: linux-rt-devel@...ts.linux.dev,
	linux-kernel@...r.kernel.org
Cc: Peter Zijlstra <peterz@...radead.org>,
	Ingo Molnar <mingo@...hat.com>,
	Will Deacon <will@...nel.org>,
	Boqun Feng <boqun.feng@...il.com>,
	Waiman Long <longman@...hat.com>,
	Guenter Roeck <linux@...ck-us.net>,
	Clark Williams <clrkwllms@...nel.org>,
	Steven Rostedt <rostedt@...dmis.org>,
	Sebastian Andrzej Siewior <bigeasy@...utronix.de>
Subject: [PATCH 0/2] lockdep: disable_irq_nosync_lockdep.*() for PREEMPT_RT.

Guenter reported a sleeping-while-atomic warning on PREEMPT_RT with the
NE2K card. Turns out it is a questionable construct which requires
lockdep tweak to not get reported. It was added long time ago to deal
with the NE2K and has today two users.

The way I see, we could convert NE2K to NAPI and avoid the construct. It
would do the slow-part/ spin (in the reset case) with "just" BH disabled
which is what it is doing now since all callers disable BH before
calling. There are however many parts using the driver which have to be
touched (CS, PCI, …) and I have just qemu here so I am not too
comfortable doing it. Also I haven't looked what is wrong forcedeth yet.

I have no idea why nobody converted NE2K to NAPI in the last 20 years.
The annotation was added in 2007 while NAPI was added in 2002 via
   abb85ec3ab0ba ("Integrate NAPI work done by Jamal Hadi Salim, Robert Olsson, and Alexey Kuznetsov.…)

The easy part is to just avoid disabling interrupt on PREEMPT_RT since
there is no difference.

Sebastian Andrzej Siewior (2):
  lockdep: Don't disable interrupts on RT in
    disable_irq_nosync_lockdep.*()
  lockdep: Remove disable_irq_lockdep().

 include/linux/interrupt.h | 16 ++++------------
 1 file changed, 4 insertions(+), 12 deletions(-)

-- 
2.47.2


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ