Re: [PATCH] jump_label: move 'asm goto' support test to Kconfig

From: Michael Ellerman
Date: Wed Jan 02 2019 - 06:22:43 EST


Masahiro Yamada <yamada.masahiro@xxxxxxxxxxxxx> writes:

> Currently, CONFIG_JUMP_LABEL just means "I _want_ to use jump label".
>
> The jump label is controlled by HAVE_JUMP_LABEL, which is defined
> like this:
>
> #if defined(CC_HAVE_ASM_GOTO) && defined(CONFIG_JUMP_LABEL)
> # define HAVE_JUMP_LABEL
> #endif
>
> We can improve this by testing 'asm goto' support in Kconfig, then
> make JUMP_LABEL depend on CC_HAS_ASM_GOTO.
>
> Ugly #ifdef HAVE_JUMP_LABEL will go away, and CONFIG_JUMP_LABEL will
> match to the real kernel capability.
>
> Signed-off-by: Masahiro Yamada <yamada.masahiro@xxxxxxxxxxxxx>
> ---
>
> This is a trivial conversion from the build system PoV.
> I want to queue this up to kbuild tree.
>
>
> Makefile | 7 -------
> arch/Kconfig | 1 +
> arch/arm/kernel/jump_label.c | 4 ----
> arch/arm64/kernel/jump_label.c | 4 ----
> arch/mips/kernel/jump_label.c | 4 ----
> arch/powerpc/include/asm/asm-prototypes.h | 2 +-
> arch/powerpc/kernel/jump_label.c | 2 --
> arch/powerpc/platforms/powernv/opal-tracepoints.c | 2 +-
> arch/powerpc/platforms/powernv/opal-wrappers.S | 2 +-
> arch/powerpc/platforms/pseries/hvCall.S | 4 ++--
> arch/powerpc/platforms/pseries/lpar.c | 2 +-

Looks OK to me.

If there's any odd build errors they should get caught in linux-next.

Acked-by: Michael Ellerman <mpe@xxxxxxxxxxxxxx> (powerpc)

cheers