[PATCH v3 12/13] ARM: mach-bcm: disable ftrace in SMC invocation routines
Nick Desaulniers
ndesaulniers at google.com
Thu Feb 3 12:39:26 PST 2022
On Thu, Feb 3, 2022 at 12:22 AM Ard Biesheuvel <ardb at kernel.org> wrote:
>
> The SMC calling convention uses R7 as an argument register, which
> conflicts with its use as a frame pointer when building in Thumb2 mode.
> Given that Clang with ftrace does not permit frame pointers to be
> enabled, let's omit this compilation unit from ftrace instrumentation.
>
> Signed-off-by: Ard Biesheuvel <ardb at kernel.org>
Acked-by: Nick Desaulniers <ndesaulniers at google.com>
> ---
> arch/arm/mach-bcm/Makefile | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/arch/arm/mach-bcm/Makefile b/arch/arm/mach-bcm/Makefile
> index 7baa8c9427d5..b2394ddb0558 100644
> --- a/arch/arm/mach-bcm/Makefile
> +++ b/arch/arm/mach-bcm/Makefile
> @@ -40,6 +40,7 @@ obj-$(CONFIG_ARCH_BCM_MOBILE_L2_CACHE) += kona_l2_cache.o
>
> # Support for secure monitor traps
> obj-$(CONFIG_ARCH_BCM_MOBILE_SMC) += bcm_kona_smc.o
> +CFLAGS_REMOVE_bcm_kona_smc.o += $(CC_FLAGS_FTRACE)
>
> # BCM2835
> ifeq ($(CONFIG_ARCH_BCM2835),y)
> --
> 2.30.2
>
--
Thanks,
~Nick Desaulniers
More information about the linux-arm-kernel
mailing list