WSL2-Linux-Kernel/tools
Borislav Petkov (AMD) 5d1dd961e7 x86/alternatives: Add alt_instr.flags
Add a struct alt_instr.flags field which will contain different flags
controlling alternatives patching behavior.

The initial idea was to be able to specify it as a separate macro
parameter but that would mean touching all possible invocations of the
alternatives macros and thus a lot of churn.

What is more, as PeterZ suggested, being able to say ALT_NOT(feature) is
very readable and explains exactly what is meant.

So make the feature field a u32 where the patching flags are the upper
u16 part of the dword quantity while the lower u16 word is the feature.

The highest feature number currently is 0x26a (i.e., word 19) so there
is plenty of space. If that becomes insufficient, the field can be
extended to u64 which will then make struct alt_instr of the nice size
of 16 bytes (14 bytes currently).

There should be no functional changes resulting from this.

Suggested-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Reviewed-by: Ingo Molnar <mingo@kernel.org>
Link: https://lore.kernel.org/r/Y6RCoJEtxxZWwotd@zn.tnic
2023-01-05 12:46:47 +01:00
..
accounting
arch perf tools fixes and improvements for v6.2: 2nd batch 2022-12-22 11:07:29 -08:00
bootconfig
bpf
build
certs
cgroup
counter
debugging
edid
firewire
firmware
gpio
hv
iio
include tools headers UAPI: Sync linux/kvm.h with the kernel sources 2022-12-20 15:15:57 -03:00
io_uring
kvm/kvm_stat
laptop
leds
lib libperf: Fix install_pkgconfig target 2022-12-16 10:04:06 -03:00
memory-model
objtool x86/alternatives: Add alt_instr.flags 2023-01-05 12:46:47 +01:00
pci
pcmcia
perf perf tools fixes and improvements for v6.2: 2nd batch 2022-12-22 11:07:29 -08:00
power
rcu
scripts
spi
testing Trace probes updates for 6.2: 2022-12-21 18:57:24 -08:00
thermal
time
tracing
usb
verification Tracing fix for 6.2: 2022-12-21 19:03:42 -08:00
virtio
vm
wmi
Makefile