Issue
I am curious if there is any difference functional wise of the pre-empting system between the the modes described in the title. I was looking at this page href="https://github.com/torvalds/linux/blob/master/kernel/Kconfig.preempt" rel="nofollow noreferrer">https://github.com/torvalds/linux/blob/master/kernel/Kconfig.preempt and ca't say for sure if there is a difference or not.
This article https://lwn.net/Articles/944686/ seems to suggest there is no difference...
How to tell ?
Solution
It seems pretty clear to me if you take a closer look at the article and kernel config options you link:
- There are 4 "levels" of kernel preemptiveness possible:
PREEMPT_NONE
,PREEMPT_VOLUNTARY
,PREEMPT
(full) andPREEMPT_RT
(real-time). - The last one (
PREEMPT_RT
) is the most aggressive and requires changes to kernel code that are only possible at build time. - The
PREEMPT_DYNAMIC
configuration option makes it possible to select among the first 3 levels (none, voluntary and full) at boot time through the kernel command line. PREEMPT_DYNAMIC
is not compatible withPREEMPT_RT
, because the latter requires substantial build time changes to kernel code.
Therefore, running a kernel with PREEMPT_DYNAMIC
set to full is roughly the same as running a kernel built with PREEMPT=y
. PREEMPT_RT
is more preemptive than "full" PREEMPT
, but not available with PREEMPT_DYNAMIC
.
Answered By - Marco Bonelli Answer Checked By - Clifford M. (WPSolving Volunteer)