|
|
Subscribe / Log in / New account

Allow to drop the softirq-BKL lock on PREEMPT_RT

From:  Sebastian Andrzej Siewior <bigeasy-AT-linutronix.de>
To:  linux-rt-devel-AT-lists.linux.dev, linux-kernel-AT-vger.kernel.org
Subject:  [PATCH v3 0/3] Allow to drop the softirq-BKL lock on PREEMPT_RT
Date:  Thu, 04 Sep 2025 16:25:22 +0200
Message-ID:  <20250904142526.1845999-1-bigeasy@linutronix.de>
Cc:  Clark Williams <clrkwllms-AT-kernel.org>, Ingo Molnar <mingo-AT-redhat.com>, Lai Jiangshan <jiangshanlai-AT-gmail.com>, Peter Zijlstra <peterz-AT-infradead.org>, Steven Rostedt <rostedt-AT-goodmis.org>, Tejun Heo <tj-AT-kernel.org>, Thomas Gleixner <tglx-AT-linutronix.de>, Sebastian Andrzej Siewior <bigeasy-AT-linutronix.de>
Archive-link:  Article

Users which rely on synchronisation within a BH-disabled section as in
- access to per-CPU data
- per-CPU timers
- synchronisation against another user within a BH-disabled section

rely on the local_lock_t lock in local_bh_disable() on PREEMPT_RT.
Almost all users dropped their dependency. The remaining (identified)
user in networking (pipapo) is in net-next.
What is left is the infrastructure as in tasklet and workqueue (for
bh-worker).
Both are part of this series. The last patch in the series adds an
option to drop the lock.

v1…v2: https://lore.kernel.org/all/20250901163811.963326-1-bigea...
  - In workqueue, __flush_work(), replace wq_pool_mutex with RCU locking.

v1 tasklet https://lore.kernel.org/all/20250812143930.22RBn5BW@linut...
v1 workqueue https://lore.kernel.org/all/20250820103657.vDuDuLx6@linut...
v1 lock-drop https://lore.kernel.org/all/20250613105653.1860729-2-bige...

Sebastian Andrzej Siewior (3):
  workqueue: Provide a handshake for canceling BH workers
  softirq: Provide a handshake for canceling tasklets via polling
  softirq: Allow to drop the softirq-BKL lock on PREEMPT_RT

 kernel/Kconfig.preempt |  13 ++++
 kernel/softirq.c       | 145 ++++++++++++++++++++++++++++++++++-------
 kernel/workqueue.c     |  50 +++++++++++---
 3 files changed, 174 insertions(+), 34 deletions(-)

-- 
2.51.0




Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds