[5.15.y] kfence: default to dynamic branch instead of static keys mode

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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@xxxxxxxxxxxxxx
[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



[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux