OpenCloudOS-Kernel/Documentation
Josh Poimboeuf fb799447ae x86,objtool: Split UNWIND_HINT_EMPTY in two
Mark reported that the ORC unwinder incorrectly marks an unwind as
reliable when the unwind terminates prematurely in the dark corners of
return_to_handler() due to lack of information about the next frame.

The problem is UNWIND_HINT_EMPTY is used in two different situations:

  1) The end of the kernel stack unwind before hitting user entry, boot
     code, or fork entry

  2) A blind spot in ORC coverage where the unwinder has to bail due to
     lack of information about the next frame

The ORC unwinder has no way to tell the difference between the two.
When it encounters an undefined stack state with 'end=1', it blindly
marks the stack reliable, which can break the livepatch consistency
model.

Fix it by splitting UNWIND_HINT_EMPTY into UNWIND_HINT_UNDEFINED and
UNWIND_HINT_END_OF_STACK.

Reported-by: Mark Rutland <mark.rutland@arm.com>
Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Acked-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/r/fd6212c8b450d3564b855e1cb48404d6277b4d9f.1677683419.git.jpoimboe@kernel.org
2023-03-23 23:18:58 +01:00
..
ABI power supply changes for the v6.3 series (part 2) 2023-03-03 16:33:28 -08:00
PCI
RCU
accel
accounting
admin-guide A small set of updates for x86: 2023-03-05 11:27:48 -08:00
arc
arm
arm64
block
bpf
cdrom
core-api
cpu-freq
crypto
dev-tools
devicetree sound fixes for 6.3-rc1 2023-03-04 10:53:59 -08:00
doc-guide
driver-api
fault-injection
fb
features
filesystems
firmware-guide
firmware_class
fpga
gpu
hid
hwmon
i2c
ia64
iio
images
infiniband
input
isdn
kbuild
kernel-hacking
leds
litmus-tests
livepatch x86,objtool: Split UNWIND_HINT_EMPTY in two 2023-03-23 23:18:58 +01:00
locking
loongarch
m68k
maintainer
mhi
mips
misc-devices
mm
netlabel
netlink
networking
nios2
nvdimm
nvme
openrisc
parisc
pcmcia
peci
power
powerpc
process A handful of documentation patches that were ready before the merge window, 2023-02-28 16:01:08 -08:00
riscv
rust
s390
scheduler
scsi
security
sh
sound
sparc
sphinx
sphinx-static
spi
staging
target
timers
tools
trace
translations A handful of documentation patches that were ready before the merge window, 2023-02-28 16:01:08 -08:00
usb
userspace-api
virt
w1
watchdog
x86
xtensa
.gitignore
Changes
CodingStyle
Kconfig
Makefile
SubmittingPatches
arch.rst
atomic_bitops.txt
atomic_t.txt
conf.py
docutils.conf
dontdiff
index.rst
memory-barriers.txt
subsystem-apis.rst