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: <20250613105653.1860729-1-bigeasy@linutronix.de>
Date: Fri, 13 Jun 2025 12:56:52 +0200
From: Sebastian Andrzej Siewior <bigeasy@...utronix.de>
To: linux-kernel@...r.kernel.org,
	linux-rt-devel@...ts.linux.dev
Cc: Clark Williams <clrkwllms@...nel.org>,
	Ingo Molnar <mingo@...hat.com>,
	Peter Zijlstra <peterz@...radead.org>,
	Steven Rostedt <rostedt@...dmis.org>,
	Thomas Gleixner <tglx@...utronix.de>,
	Valentin Schneider <vschneid@...hat.com>,
	Sebastian Andrzej Siewior <bigeasy@...utronix.de>
Subject: [RFC PATCH 0/1] softirq: Allow to drop the softirq-BKL lock on PREEMPT_RT

After auditing the tree most of the local-BH locks are in tree now or
the code has been changed to avoid the per-CPU ressource.

There are still a few places missing. While those are worked on, this
patch allows to test the unlocked behaviour. Without the explicit
softirq synchronisation, one softirq can interrupt and nest within.

This is what the behaviour can look like:

|     ktimers/20-204  [020] ..s.1   33.291036: softirq_entry: vec=1 [action=TIMER]
|     ktimers/20-204  [020] d.s42   33.291054: sched_wakeup: comm=kworker/u133:3 pid=1215 prio=120 target_cpu=020
|     ktimers/20-204  [020] d.H22   33.291146: irq_handler_entry: irq=37 name=ahci[0000:00:1f.2]
|     ktimers/20-204  [020] d.H22   33.291147: irq_handler_exit: irq=37 ret=handled
|     ktimers/20-204  [020] dNH52   33.291152: sched_wakeup: comm=irq/37-ahci[000 pid=810 prio=49 target_cpu=020
|     ktimers/20-204  [020] d.s22   33.291162: sched_switch: prev_comm=ktimers/20 prev_pid=204 prev_prio=98 prev_state=R+ ==> next_comm=irq/37-ahci[000 next_pid=810 next_prio=49
|irq/37-ahci[000-810  [020] D..12   33.291177: softirq_raise: vec=4 [action=BLOCK]
|irq/37-ahci[000-810  [020] ..s.1   33.291179: softirq_entry: vec=4 [action=BLOCK]
^^
|irq/37-ahci[000-810  [020] ..s.1   33.291187: softirq_exit: vec=4 [action=BLOCK]
|irq/37-ahci[000-810  [020] d..2.   33.291195: sched_switch: prev_comm=irq/37-ahci[000 prev_pid=810 prev_prio=49 prev_state=S ==> next_comm=ktimers/20 next_pid=204 next_prio=98
|     ktimers/20-204  [020] ..s.1   33.291227: softirq_exit: vec=1 [action=TIMER]


Sebastian Andrzej Siewior (1):
  softirq: Allow to drop the softirq-BKL lock on PREEMPT_RT

 kernel/Kconfig.preempt | 13 +++++++
 kernel/softirq.c       | 83 ++++++++++++++++++++++++++++++++----------
 2 files changed, 76 insertions(+), 20 deletions(-)

-- 
2.49.0


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ