Re: [PATCH -tip] x86/stackprotector: Move stack canary to struct pcpu_hot

From: Uros Bizjak
Date: Fri Feb 21 2025 - 09:33:41 EST


On Fri, Feb 21, 2025 at 3:13 PM Ard Biesheuvel <ardb@xxxxxxxxxx> wrote:

> > > I got a warning from the relocs tool, but not a hard error. What
> > > compiler/linker are you using?
> > >
> > > Does the attached patch build in your configuration?
> >
> > Ah, the attached patch is similar to my previous approach, where the
> > build system *warned* on an offset (the patch was abandoned due to
> > Ard's request to put stack_canary to the *beginning* of struct
> > pcpu_hot, and this allowed for a simplified patch).
> >
> > The attached patch builds for me without warning/error for both, SMP
> > and !SMP build.
> >
>
> Did you try building modules too?

make -j 24 olddefconfig prepare modules_prepare bzImage modules

for defconfig, SMP and !SMP.

Uros.