* [PATCH 0/2] docs: Remove the unsupported preempt= modes
@ 2026-10-28 2:43 Jinjie Ruan
2026-10-28 2:43 ` [PATCH 1/2] docs: kernel-parameters: Drop " Jinjie Ruan
2026-10-28 2:43 ` [PATCH 2/2] docs: sched-preemption: Fix the list of runtime-selectable models Jinjie Ruan
0 siblings, 2 replies; 7+ messages in thread
From: Jinjie Ruan @ 2026-10-28 2:43 UTC (permalink / raw)
To: corbet, skhan, rdunlap, bigeasy, clrkwllms, rostedt, rppt, arnd,
bp, kmehltretter, dapeng1.mi, elver, enelsonmoore, jlayton,
quchaosheng000406, linux-doc, linux-kernel, linux-rt-devel
Cc: ruanjinjie
The none and voluntary preemption models can no longer be selected with
CONFIG_PREEMPT_DYNAMIC:
- commit 7dadeaa6e851 ("sched: Further restrict the preemption modes")
stopped PREEMPT_NONE and PREEMPT_VOLUNTARY from being offered on
architectures that select ARCH_HAS_PREEMPT_LAZY;
- commit d3d16750693b ("sched: dynamic: Make PREEMPT_DYNAMIC depend on
ARCH_HAS_PREEMPT_LAZY") made that dependency official and removed the
code that parsed "preempt=none" and "preempt=voluntary".
Two documentation files still describe both as runtime options. The first
patch drops them from the preempt= entry in kernel-parameters.txt, the
second fixes the model table in sched-preemption.rst, which also misstates
why an architecture may or may not offer them.
Nothing in the code changes.
Jinjie Ruan (2):
docs: kernel-parameters: Drop unsupported preempt= modes
docs: sched-preemption: Fix the list of runtime-selectable models
Documentation/admin-guide/kernel-parameters.txt | 2 --
Documentation/scheduler/sched-preemption.rst | 13 ++++++-------
2 files changed, 6 insertions(+), 9 deletions(-)
--
2.34.1
^ permalink raw reply [flat|nested] 7+ messages in thread* [PATCH 1/2] docs: kernel-parameters: Drop unsupported preempt= modes
2026-10-28 2:43 [PATCH 0/2] docs: Remove the unsupported preempt= modes Jinjie Ruan
@ 2026-10-28 2:43 ` Jinjie Ruan
2026-10-28 15:40 ` Daniel Pereira
2026-11-02 13:34 ` Sebastian Andrzej Siewior
2026-10-28 2:43 ` [PATCH 2/2] docs: sched-preemption: Fix the list of runtime-selectable models Jinjie Ruan
1 sibling, 2 replies; 7+ messages in thread
From: Jinjie Ruan @ 2026-10-28 2:43 UTC (permalink / raw)
To: corbet, skhan, rdunlap, bigeasy, clrkwllms, rostedt, rppt, arnd,
bp, kmehltretter, dapeng1.mi, elver, enelsonmoore, jlayton,
quchaosheng000406, linux-doc, linux-kernel, linux-rt-devel
Cc: ruanjinjie
Since commit d3d16750693b ("sched: dynamic: Make PREEMPT_DYNAMIC depend
on ARCH_HAS_PREEMPT_LAZY") only "full" and "lazy" are accepted with
CONFIG_PREEMPT_DYNAMIC: every architecture that supports it selects
ARCH_HAS_PREEMPT_LAZY, which excludes the none and voluntary models.
Passing either is rejected with "Dynamic Preempt: unsupported mode".
Remove the two lines so the parameter reference matches the code.
Signed-off-by: Jinjie Ruan <ruanjinjie@huawei.com>
---
Documentation/admin-guide/kernel-parameters.txt | 2 --
1 file changed, 2 deletions(-)
diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
index fce0d52b9cfe..11f0b700d56a 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -5428,8 +5428,6 @@ Kernel parameters
preempt= [KNL]
Select preemption mode if you have CONFIG_PREEMPT_DYNAMIC
- none - Limited to cond_resched() calls
- voluntary - Limited to cond_resched() and might_sleep() calls
full - Any section that isn't explicitly preempt disabled
can be preempted anytime. Tasks will also yield
contended spinlocks (if the critical section isn't
--
2.34.1
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [PATCH 1/2] docs: kernel-parameters: Drop unsupported preempt= modes
2026-10-28 2:43 ` [PATCH 1/2] docs: kernel-parameters: Drop " Jinjie Ruan
@ 2026-10-28 15:40 ` Daniel Pereira
2026-11-02 13:34 ` Sebastian Andrzej Siewior
1 sibling, 0 replies; 7+ messages in thread
From: Daniel Pereira @ 2026-10-28 15:40 UTC (permalink / raw)
To: ruanjinjie; +Cc: corbet, skhan, rdunlap, linux-doc, linux-kernel
Em ter., 27 de out. de 2026 às 23:45, Jinjie Ruan
<ruanjinjie@huawei.com> escreveu:
>
> Since commit d3d16750693b ("sched: dynamic: Make PREEMPT_DYNAMIC depend
> on ARCH_HAS_PREEMPT_LAZY") only "full" and "lazy" are accepted with
> CONFIG_PREEMPT_DYNAMIC: every architecture that supports it selects
> ARCH_HAS_PREEMPT_LAZY, which excludes the none and voluntary models.
> Passing either is rejected with "Dynamic Preempt: unsupported mode".
>
Hi Jinjie,
Thanks for the patch. I checked it against current mainline:
PREEMPT_DYNAMIC now depends on ARCH_HAS_PREEMPT_LAZY (d3d16750693b),
sched_dynamic_mode() only accepts "full" and "lazy", and all six
architectures that select HAVE_PREEMPT_DYNAMIC also select
ARCH_HAS_PREEMPT_LAZY. So dropping "none" and "voluntary" from the
preempt= entry matches the code.
checkpatch is clean, and the admin-guide build (SPHINXDIRS=admin-guide)
renders the preempt= entry correctly with only "full" and "lazy".
Reviewed-by: Daniel Pereira <danielmaraboo@gmail.com>
Best regards,
Daniel
^ permalink raw reply [flat|nested] 7+ messages in thread* Re: [PATCH 1/2] docs: kernel-parameters: Drop unsupported preempt= modes
2026-10-28 2:43 ` [PATCH 1/2] docs: kernel-parameters: Drop " Jinjie Ruan
2026-10-28 15:40 ` Daniel Pereira
@ 2026-11-02 13:34 ` Sebastian Andrzej Siewior
1 sibling, 0 replies; 7+ messages in thread
From: Sebastian Andrzej Siewior @ 2026-11-02 13:34 UTC (permalink / raw)
To: Jinjie Ruan
Cc: corbet, skhan, rdunlap, clrkwllms, rostedt, rppt, arnd, bp,
kmehltretter, dapeng1.mi, elver, enelsonmoore, jlayton,
quchaosheng000406, linux-doc, linux-kernel, linux-rt-devel
On 2026-10-28 10:43:32 [+0800], Jinjie Ruan wrote:
> Since commit d3d16750693b ("sched: dynamic: Make PREEMPT_DYNAMIC depend
> on ARCH_HAS_PREEMPT_LAZY") only "full" and "lazy" are accepted with
> CONFIG_PREEMPT_DYNAMIC: every architecture that supports it selects
> ARCH_HAS_PREEMPT_LAZY, which excludes the none and voluntary models.
> Passing either is rejected with "Dynamic Preempt: unsupported mode".
>
> Remove the two lines so the parameter reference matches the code.
>
> Signed-off-by: Jinjie Ruan <ruanjinjie@huawei.com>
Reviewed-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Sebastian
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH 2/2] docs: sched-preemption: Fix the list of runtime-selectable models
2026-10-28 2:43 [PATCH 0/2] docs: Remove the unsupported preempt= modes Jinjie Ruan
2026-10-28 2:43 ` [PATCH 1/2] docs: kernel-parameters: Drop " Jinjie Ruan
@ 2026-10-28 2:43 ` Jinjie Ruan
2026-10-28 15:43 ` Daniel Pereira
2026-11-02 13:34 ` Sebastian Andrzej Siewior
1 sibling, 2 replies; 7+ messages in thread
From: Jinjie Ruan @ 2026-10-28 2:43 UTC (permalink / raw)
To: corbet, skhan, rdunlap, bigeasy, clrkwllms, rostedt, rppt, arnd,
bp, kmehltretter, dapeng1.mi, elver, enelsonmoore, jlayton,
quchaosheng000406, linux-doc, linux-kernel, linux-rt-devel
Cc: ruanjinjie
CONFIG_PREEMPT_DYNAMIC now depends on CONFIG_ARCH_HAS_PREEMPT_LAZY, so the
none and voluntary models can no longer be selected at runtime; passing
either to preempt= is rejected with "Dynamic Preempt: unsupported mode".
Drop them from the table of runtime-selectable models, and describe the
build-time situation instead of implying the choice simply depends on the
architecture offering lazy preemption. Keep the per-model descriptions
below, which still explain how a scheduling request is honoured under
models used by other kernels.
Signed-off-by: Jinjie Ruan <ruanjinjie@huawei.com>
---
Documentation/scheduler/sched-preemption.rst | 13 ++++++-------
1 file changed, 6 insertions(+), 7 deletions(-)
diff --git a/Documentation/scheduler/sched-preemption.rst b/Documentation/scheduler/sched-preemption.rst
index b48e53587a7a..0b5ddf7d26f2 100644
--- a/Documentation/scheduler/sched-preemption.rst
+++ b/Documentation/scheduler/sched-preemption.rst
@@ -20,9 +20,6 @@ change.
The models selectable at runtime are:
========= ====================================================
- none No preemption of kernel code other than at explicit
- ``cond_resched()`` / blocking points.
- voluntary As ``none``, plus ``might_sleep()`` sites.
full Any section that is not explicitly preempt disabled
may be preempted at any time.
lazy As ``full``, except that the scheduling request is
@@ -31,10 +28,12 @@ The models selectable at runtime are:
apply to real-time tasks.
========= ====================================================
-Not every model is available on every kernel. An architecture that provides
-lazy-preempt support offers only ``full`` and ``lazy``, and ``none`` and
-``voluntary`` are rejected there. A PREEMPT_RT kernel always offers ``full``,
-and ``lazy`` as well if the architecture provides it.
+CONFIG_PREEMPT_DYNAMIC depends on CONFIG_ARCH_HAS_PREEMPT_LAZY, so ``none``
+and ``voluntary`` are never selectable at runtime; passing either is
+rejected with "Dynamic Preempt: unsupported mode". The two models are only
+left as build-time choices on architectures without lazy-preempt support.
+A PREEMPT_RT kernel always offers ``full``, and ``lazy`` as well if the
+architecture provides it.
The model that is actually active is reported in the boot log::
--
2.34.1
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 2/2] docs: sched-preemption: Fix the list of runtime-selectable models
2026-10-28 2:43 ` [PATCH 2/2] docs: sched-preemption: Fix the list of runtime-selectable models Jinjie Ruan
@ 2026-10-28 15:43 ` Daniel Pereira
2026-11-02 13:34 ` Sebastian Andrzej Siewior
1 sibling, 0 replies; 7+ messages in thread
From: Daniel Pereira @ 2026-10-28 15:43 UTC (permalink / raw)
To: ruanjinjie; +Cc: corbet, skhan, rdunlap, linux-doc, linux-kernel
On Tue, Oct 27, 2026 11:44 PM, Jinjie Ruan <ruanjinjie@huawei.com> wrote:
>
> CONFIG_PREEMPT_DYNAMIC now depends on CONFIG_ARCH_HAS_PREEMPT_LAZY, so the
> none and voluntary models can no longer be selected at runtime; passing
> either to preempt= is rejected with "Dynamic Preempt: unsupported mode".
>
> Drop them from the table of runtime-selectable models, and describe the
> build-time situation instead of implying the choice simply depends on the
> architecture offering lazy preemption. Keep the per-model descriptions
> below, which still explain how a scheduling request is honoured under
> models used by other kernels.
>
> Signed-off-by: Jinjie Ruan <ruanjinjie@huawei.com>
> ---
> Documentation/scheduler/sched-preemption.rst | 13 ++++++-------
> 1 file changed, 6 insertions(+), 7 deletions(-)
Hi Jinjie,
Thanks for the patch. I validated it: checkpatch and the scheduler docs
build (SPHINXDIRS=scheduler) report no errors or new warnings, the table
renders as expected, and the changes match current mainline
(PREEMPT_DYNAMIC depends on ARCH_HAS_PREEMPT_LAZY, d3d16750693b).
Reviewed-by: Daniel Pereira <danielmaraboo@gmail.com>
Best regards,
Daniel
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 2/2] docs: sched-preemption: Fix the list of runtime-selectable models
2026-10-28 2:43 ` [PATCH 2/2] docs: sched-preemption: Fix the list of runtime-selectable models Jinjie Ruan
2026-10-28 15:43 ` Daniel Pereira
@ 2026-11-02 13:34 ` Sebastian Andrzej Siewior
1 sibling, 0 replies; 7+ messages in thread
From: Sebastian Andrzej Siewior @ 2026-11-02 13:34 UTC (permalink / raw)
To: Jinjie Ruan
Cc: corbet, skhan, rdunlap, clrkwllms, rostedt, rppt, arnd, bp,
kmehltretter, dapeng1.mi, elver, enelsonmoore, jlayton,
quchaosheng000406, linux-doc, linux-kernel, linux-rt-devel
On 2026-10-28 10:43:33 [+0800], Jinjie Ruan wrote:
> --- a/Documentation/scheduler/sched-preemption.rst
> +++ b/Documentation/scheduler/sched-preemption.rst
> @@ -20,9 +20,6 @@ change.
> The models selectable at runtime are:
>
> ========= ====================================================
> - none No preemption of kernel code other than at explicit
> - ``cond_resched()`` / blocking points.
> - voluntary As ``none``, plus ``might_sleep()`` sites.
> full Any section that is not explicitly preempt disabled
> may be preempted at any time.
> lazy As ``full``, except that the scheduling request is
This is fine.
> @@ -31,10 +28,12 @@ The models selectable at runtime are:
> apply to real-time tasks.
> ========= ====================================================
>
> -Not every model is available on every kernel. An architecture that provides
> -lazy-preempt support offers only ``full`` and ``lazy``, and ``none`` and
> -``voluntary`` are rejected there. A PREEMPT_RT kernel always offers ``full``,
> -and ``lazy`` as well if the architecture provides it.
> +CONFIG_PREEMPT_DYNAMIC depends on CONFIG_ARCH_HAS_PREEMPT_LAZY, so ``none``
> +and ``voluntary`` are never selectable at runtime; passing either is
> +rejected with "Dynamic Preempt: unsupported mode". The two models are only
> +left as build-time choices on architectures without lazy-preempt support.
> +A PREEMPT_RT kernel always offers ``full``, and ``lazy`` as well if the
> +architecture provides it.
What about:
Not every model is available on every kernel. An architecture that provides
preemption support supports ``full``. If additionally lazy-preempt is
supported then the choice ``lazy`` becomes available. An architecture
without preemption support can not enable CONFIG_PREEMPT_DYNAMIC. On
such an architecture the preemption model can only be selected at
compile time.
Sebastian
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2026-11-02 13:34 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-28 2:43 [PATCH 0/2] docs: Remove the unsupported preempt= modes Jinjie Ruan
2026-10-28 2:43 ` [PATCH 1/2] docs: kernel-parameters: Drop " Jinjie Ruan
2026-10-28 15:40 ` Daniel Pereira
2026-11-02 13:34 ` Sebastian Andrzej Siewior
2026-10-28 2:43 ` [PATCH 2/2] docs: sched-preemption: Fix the list of runtime-selectable models Jinjie Ruan
2026-10-28 15:43 ` Daniel Pereira
2026-11-02 13:34 ` Sebastian Andrzej Siewior
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®