Re: [PATCH v6 10/20] kbuild: generate KSYMTAB entries by modpost

From: Nick Desaulniers
Date: Thu May 25 2023 - 13:51:04 EST


On Sun, May 21, 2023 at 9:05 AM Masahiro Yamada <masahiroy@xxxxxxxxxx> wrote:
>
> Commit 7b4537199a4a ("kbuild: link symbol CRCs at final link, removing
> CONFIG_MODULE_REL_CRCS") made modpost output CRCs in the same way
> whether the EXPORT_SYMBOL() is placed in *.c or *.S.
>
> Signed-off-by: Masahiro Yamada <masahiroy@xxxxxxxxxx>

Patch LGTM, but two questions, below.

> diff --git a/arch/um/os-Linux/user_syms.c b/arch/um/os-Linux/user_syms.c
> index 9b62a9d352b3..0b3a82aedbfa 100644
> --- a/arch/um/os-Linux/user_syms.c
> +++ b/arch/um/os-Linux/user_syms.c
> @@ -38,10 +38,15 @@ EXPORT_SYMBOL(vsyscall_end);
> #endif
>
> /* Export symbols used by GCC for the stack protector. */
> -extern void __stack_smash_handler(void *) __attribute__((weak));
> +/*
> + * REVISIT:
> + * ARCH=um cannot enable CONFIG_STACKPROTECTOR because
> + * 'select HAVE_STACKPROTECTOR' is missing. Is this already broken?

^ Is there something better we can do here?

Maybe this code should be deleted first?

> diff --git a/include/asm-generic/export.h b/include/asm-generic/export.h
> index 5e4b1f2369d2..0ae9f38a904c 100644
> --- a/include/asm-generic/export.h
> +++ b/include/asm-generic/export.h
> @@ -3,86 +3,12 @@
> #define __ASM_GENERIC_EXPORT_H
>
> /*
> - * This comment block is used by fixdep. Please do not remove.

^ Sounds ominous. What are the implications of removing this comment block?


--
Thanks,
~Nick Desaulniers