* [5.15.y] kfence: default to dynamic branch instead of static keys mode
@ 2021-11-09 17:19 Marco Elver
2021-11-10 8:31 ` Greg Kroah-Hartman
0 siblings, 1 reply; 2+ messages in thread
From: Marco Elver @ 2021-11-09 17:19 UTC (permalink / raw)
To: stable, Greg Kroah-Hartman, Sasha Levin; +Cc: Alexander Potapenko, kasan-dev
Dear stable maintainers,
We propose picking the following 2 patches to 5.15.y:
07e8481d3c38 kfence: always use static branches to guard kfence_alloc()
4f612ed3f748 kfence: default to dynamic branch instead of static keys mode
, which had not been marked for stable initially, but upon re-evaluation
conclude that it will also avoid various unexpected behaviours [1], [2]
as the use of frequently-switched static keys (at least on x86) is more
trouble than it's worth.
[1] https://lkml.kernel.org/r/CANpmjNOw--ZNyhmn-GjuqU+aH5T98HMmBoCM4z=JFvajC913Qg@mail.gmail.com
[2] https://patchwork.kernel.org/project/linux-acpi/patch/2618833.mvXUDI8C0e@kreacher/
While optional, we recommend 07e8481d3c38 as well, as it avoids the
dynamic branch, now the default, if kfence is disabled at boot.
The main thing is to make the default less troublesome and be more
conservative. Those choosing to enable CONFIG_KFENCE_STATIC_KEYS can
still do so, but requires a deliberate opt-in via a config change.
Many thanks,
-- Marco
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [5.15.y] kfence: default to dynamic branch instead of static keys mode
2021-11-09 17:19 [5.15.y] kfence: default to dynamic branch instead of static keys mode Marco Elver
@ 2021-11-10 8:31 ` Greg Kroah-Hartman
0 siblings, 0 replies; 2+ messages in thread
From: Greg Kroah-Hartman @ 2021-11-10 8:31 UTC (permalink / raw)
To: Marco Elver; +Cc: stable, Sasha Levin, Alexander Potapenko, kasan-dev
On Tue, Nov 09, 2021 at 06:19:54PM +0100, Marco Elver wrote:
> Dear stable maintainers,
>
> We propose picking the following 2 patches to 5.15.y:
>
> 07e8481d3c38 kfence: always use static branches to guard kfence_alloc()
> 4f612ed3f748 kfence: default to dynamic branch instead of static keys mode
>
> , which had not been marked for stable initially, but upon re-evaluation
> conclude that it will also avoid various unexpected behaviours [1], [2]
> as the use of frequently-switched static keys (at least on x86) is more
> trouble than it's worth.
>
> [1] https://lkml.kernel.org/r/CANpmjNOw--ZNyhmn-GjuqU+aH5T98HMmBoCM4z=JFvajC913Qg@mail.gmail.com
> [2] https://patchwork.kernel.org/project/linux-acpi/patch/2618833.mvXUDI8C0e@kreacher/
>
> While optional, we recommend 07e8481d3c38 as well, as it avoids the
> dynamic branch, now the default, if kfence is disabled at boot.
>
> The main thing is to make the default less troublesome and be more
> conservative. Those choosing to enable CONFIG_KFENCE_STATIC_KEYS can
> still do so, but requires a deliberate opt-in via a config change.
Both now queued up, thanks.
greg k-h
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-11-10 8:31 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-11-09 17:19 [5.15.y] kfence: default to dynamic branch instead of static keys mode Marco Elver
2021-11-10 8:31 ` Greg Kroah-Hartman
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox