Re: [PATCH] kallsyms: copy constants from __KERNEL__ to user, drop the inclusion
From: Andrew Morton
Date: Sat Oct 10 2026 - 19:34:33 EST
On Fri, 09 Oct 2026 20:54:42 +0200 Nicolas Schier <nsc@xxxxxxxxxx> wrote:
> > commit 4fafd1165b33 replaced hardcoded values which determine marker
> > array size, with new values that accelerate symbol-name lookups.
> > These symbols are needed in user-space to generate the lookup tables,
> > and in kernel to read the generated table.
> >
> > To avoid 2-defns problem, they were added to a kernel header (with
> > ifdef guards) and included by scripts/kallsyms.c. But that creates
> > packaging problems elsewhere, so just add the 2nd defns, with an
> > explicit comment about the user-kernel coupling.
> >
> > Fixes: 4fafd1165b33 ("kallsyms: increase marker density to 16:1 to accelerate lookups")
> >
> > Signed-off-by: Jim Cromie <jim.cromie@xxxxxxxxx>
> > ---
Thanks, I added this as a to-be-squashed-later fix against "kallsyms:
increase marker density to 16:1 to accelerate lookups".
btw, I have recorded some question marks about this series:
https://lore.kernel.org/20260929221330.72cd1de4@pumpkin
https://lore.kernel.org/20260930132109.260597-1-david.laight.linux@xxxxxxxxx
https://lore.kernel.org/20260930101307.4477e264@pumpkin
and I'd like to get those crossed off before proceeding.
> FTR: Please keep trailers in a single trailer block, otherwise that will
> probably break some common tooling (cp. e.g. git-interpret-trailers).
>
> Is the commit ID correct? In mm-nonmm-unstable I find
> e2c2904abf71d0144f37844fde7dffe8b814a44f instead.
mm-unstable is "unstable". It rebases more than once per day so lookup
by hash doesn't work.
git log --oneline | grep "kallsyms increase marker density to 16:1 to accelerate lookups"
works for me.