[RFC PATCH 0/6] ARM: enable IRQ stacks and vmap'ed stacks for UP

Linus Walleij linus.walleij at linaro.org
Fri Nov 26 16:20:53 PST 2021


On Fri, Nov 26, 2021 at 11:10 AM Ard Biesheuvel <ardb at kernel.org> wrote:

> Enable the use of the TLS register to hold the 'current' pointer for all
> configurations that can support it, including non-SMP ones that target
> v6k or later CPUs, and multi-platform SMP ones that also support v6
> based UP systems.
>
> The remaining configurations are all strictly UP, which means we can
> switch to a global variable to hold the current pointer. By doing this,
> we can enable THREAD_INFO_IN_TASK, which moves thread info off the
> stack, protecting it from overflows. It also permits us to enable IRQ
> stacks and vmap'ed stacks for UP configurations as well.

I really like what I see here!

I glanced over it but sadly do not have sufficient time to read every
detail of it, but I certainly trust to to get things right and iron out any
rough corners so FWIW:
Acked-by: Linus Walleij <linus.walleij at linaro.org>
on this patch set.

> Supporting v6 cores without SMP extensions in SMP configurations (e.g.,
> omap2plus_defconfig or imx_v6_v7_defconfig) makes this a bit tricky, and
> this is a feature we may consider dropping entirely in the future. But
> for the time being, we can support this mode as well.

Hmmm yes these will look odd and I can see it really makes the
patch hairy too. I think people might be using them though :/

Yours,
Linus Walleij



More information about the linux-arm-kernel mailing list