Re: [PATCH v5] kallsyms: new /proc/kallmodsyms with builtin modules

From: Kees Cook
Date: Wed Sep 29 2021 - 19:34:43 EST


On Wed, Sep 29, 2021 at 10:51:47PM +0100, Nick Alcock wrote:
> It would be useful if there were a mapping between kernel symbol and module
> name that only changed when the kernel source code is changed. This mapping
> should not change simply because a module becomes built into the kernel.
>
> It might also be useful if there were reliable symbol size information to
> determine whether an address is within a symbol or outside it, especially
> given that there could be huge gaps between symbols.

This is a pretty cool series, but I'm left wondering "for what reason?" :)
Perhaps I missed the specific rationale; there was a lot to run. ;)

It would be useful, sure, but is there something that does, in fact,
need this, or would like this if it were available? Since this provides
a userspace API, what would be consuming that API? For example, when
Syscall User Dispatch was added, it was clear it was for Wine[1].

-Kees

[1] https://lore.kernel.org/lkml/160690190770.3364.5119373826178425644.tip-bot2@tip-bot2/

--
Kees Cook