[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAK7LNAS1=+OccAd3asj9P9JMWnhimRWR+dPQREOyK3y=Dx2odg@mail.gmail.com>
Date: Sun, 28 Jul 2019 13:12:02 +0900
From: Masahiro Yamada <yamada.masahiro@...ionext.com>
To: Thomas Gleixner <tglx@...utronix.de>
Cc: LKML <linux-kernel@...r.kernel.org>,
Michal Marek <michal.lkml@...kovi.net>,
Linux Kbuild mailing list <linux-kbuild@...r.kernel.org>,
Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...nel.org>,
Steven Rostedt <rostedt@...dmis.org>,
Sebastian Sewior <bigeasy@...utronix.de>
Subject: Re: [PATCH] Kbuild: Handle PREEMPT_RT for version string and magic
Hi Thomas,
On Sat, Jul 27, 2019 at 5:49 AM Thomas Gleixner <tglx@...utronix.de> wrote:
>
> Update the build scripts and the version magic to reflect when
> CONFIG_PREEMPT_RT is enabled in the same way as CONFIG_PREEMPT is treated.
>
> The resulting version strings:
>
> Linux m 5.3.0-rc1+ #100 SMP Fri Jul 26 ...
> Linux m 5.3.0-rc1+ #101 SMP PREEMPT Fri Jul 26 ...
> Linux m 5.3.0-rc1+ #102 SMP PREEMPT_RT Fri Jul 26 ...
>
> The module vermagic:
>
> 5.3.0-rc1+ SMP mod_unload modversions
> 5.3.0-rc1+ SMP preempt mod_unload modversions
> 5.3.0-rc1+ SMP preempt_rt mod_unload modversions
>
> Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
> Cc: Masahiro Yamada <yamada.masahiro@...ionext.com>
> Cc: Michal Marek <michal.lkml@...kovi.net>
> Cc: linux-kbuild@...r.kernel.org
Since CONFIG_PREEMPTION was introduced after -rc1,
I think this should be queued on top of -rc2.
Just a nit below.
> ---
> include/linux/vermagic.h | 10 +++++++---
> init/Makefile | 5 +++--
> scripts/Makefile.modpost | 2 +-
> scripts/mkcompile_h | 4 +++-
> 4 files changed, 14 insertions(+), 7 deletions(-)
>
> --- a/include/linux/vermagic.h
> +++ b/include/linux/vermagic.h
> @@ -7,10 +7,14 @@
> #else
> #define MODULE_VERMAGIC_SMP ""
> #endif
> -#ifdef CONFIG_PREEMPT
> -#define MODULE_VERMAGIC_PREEMPT "preempt "
> +#ifdef CONFIG_PREEMPTION
> +# ifdef CONFIG_PREEMPT
> +# define MODULE_VERMAGIC_PREEMPT "preempt "
> +# else
> +# define MODULE_VERMAGIC_PREEMPT "preempt_rt "
> +# endif
> #else
> -#define MODULE_VERMAGIC_PREEMPT ""
> +# define MODULE_VERMAGIC_PREEMPT ""
Maybe, is the following more readable?
#if defined(CONFIG_PREEMPT_RT)
#define MODULE_VERMAGIC_PREEMPT "preempt_rt "
#elif defined(CONFIG_PREEMPT)
#define MODULE_VERMAGIC_PREEMPT "preempt "
#else
#define MODULE_VERMAGIC_PREEMPT ""
#endif
Thanks.
--
Best Regards
Masahiro Yamada
Powered by blists - more mailing lists