From: Frederic Weisbecker <frederic@kernel.org>
To: linux-kernel@vger.kernel.org
Cc: linux-tip-commits@vger.kernel.org, Mike Galbraith <efault@gmx.de>,
"Peter Zijlstra (Intel)" <peterz@infradead.org>,
x86@kernel.org
Subject: Re: [tip: sched/core] sched,x86: Allow !PREEMPT_DYNAMIC
Date: Wed, 10 Feb 2021 15:18:38 +0100 [thread overview]
Message-ID: <20210210141838.GA53130@lothringen> (raw)
In-Reply-To: <161296521143.23325.3662179234825253723.tip-bot2@tip-bot2>
On Wed, Feb 10, 2021 at 01:53:31PM -0000, tip-bot2 for Peter Zijlstra wrote:
> The following commit has been merged into the sched/core branch of tip:
>
> Commit-ID: 82891be90f3c42dc964fd61b8b2a89de12940c9f
> Gitweb: https://git.kernel.org/tip/82891be90f3c42dc964fd61b8b2a89de12940c9f
> Author: Peter Zijlstra <peterz@infradead.org>
> AuthorDate: Tue, 09 Feb 2021 22:02:33 +01:00
> Committer: Peter Zijlstra <peterz@infradead.org>
> CommitterDate: Wed, 10 Feb 2021 14:44:51 +01:00
>
> sched,x86: Allow !PREEMPT_DYNAMIC
>
> Allow building x86 with PREEMPT_DYNAMIC=n, this is needed for
> PREEMPT_RT as it makes no sense to not have full preemption on
> PREEMPT_RT.
>
> Fixes: 8c98e8cf723c ("preempt/dynamic: Provide preempt_schedule[_notrace]() static calls")
> Reported-by: Mike Galbraith <efault@gmx.de>
> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
> Tested-by: Mike Galbraith <efault@gmx.de>
> Link: https://lkml.kernel.org/r/YCK1+JyFNxQnWeXK@hirez.programming.kicks-ass.net
Also should we add something like this?
From 4e1de6d9d8804ea7edc6f8767abea37f5103799a Mon Sep 17 00:00:00 2001
From: Frederic Weisbecker <frederic@kernel.org>
Date: Wed, 10 Feb 2021 15:11:39 +0100
Subject: [PATCH] preempt/dynamic: Make PREEMPT_DYNAMIC optional
In order not to make the small trampoline overhead mandatory for archs
that support HAVE_STATIC_CALL but not HAVE_STATIC_CALL_INLINE, make
PREEMPT_DYNAMIC optional.
Signed-off-by: Frederic Weisbecker <frederic@kernel.org>
---
kernel/Kconfig.preempt | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/kernel/Kconfig.preempt b/kernel/Kconfig.preempt
index 416017301660..1fe759677907 100644
--- a/kernel/Kconfig.preempt
+++ b/kernel/Kconfig.preempt
@@ -40,7 +40,6 @@ config PREEMPT
depends on !ARCH_NO_PREEMPT
select PREEMPTION
select UNINLINE_SPIN_UNLOCK if !ARCH_INLINE_SPIN_UNLOCK
- select PREEMPT_DYNAMIC if HAVE_PREEMPT_DYNAMIC
help
This option reduces the latency of the kernel by making
all kernel code (that is not executing in a critical section)
@@ -83,11 +82,13 @@ config PREEMPTION
select PREEMPT_COUNT
config PREEMPT_DYNAMIC
- bool
+ bool "Override preemption flavour at boot time"
+ depends on HAVE_PREEMPT_DYNAMIC && PREEMPT
+ default HAVE_STATIC_CALL_INLINE
help
This option allows to define the preemption model on the kernel
- command line parameter and thus override the default preemption
- model defined during compile time.
+ command line parameter "preempt=" and thus override the default
+ preemption model defined during compile time.
The feature is primarily interesting for Linux distributions which
provide a pre-built kernel binary to reduce the number of kernel
@@ -99,3 +100,5 @@ config PREEMPT_DYNAMIC
Interesting if you want the same pre-built kernel should be used for
both Server and Desktop workloads.
+
+ Say Y if you have CONFIG_HAVE_STATIC_CALL_INLINE.
--
2.25.1
next prev parent reply other threads:[~2021-02-10 14:19 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-09 13:45 [patch] preempt: select PREEMPT_DYNAMIC under PREEMPTION instead of PREEMPT Mike Galbraith
2021-02-09 15:13 ` Peter Zijlstra
2021-02-09 16:05 ` Mike Galbraith
2021-02-09 16:13 ` Peter Zijlstra
2021-02-09 16:19 ` Peter Zijlstra
2021-02-09 16:46 ` Mike Galbraith
2021-02-10 13:53 ` [tip: sched/core] sched,x86: Allow !PREEMPT_DYNAMIC tip-bot2 for Peter Zijlstra
2021-02-10 14:18 ` Frederic Weisbecker [this message]
2021-02-16 10:38 ` Peter Zijlstra
2021-02-17 13:17 ` tip-bot2 for Peter Zijlstra
2021-02-09 16:27 ` [patch] preempt: select PREEMPT_DYNAMIC under PREEMPTION instead of PREEMPT Mike Galbraith
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210210141838.GA53130@lothringen \
--to=frederic@kernel.org \
--cc=efault@gmx.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=peterz@infradead.org \
--cc=x86@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox