linux-yocto/arch/xtensa/kernel
Max Filippov b6621895b4 xtensa: fix MAKE_PC_FROM_RA second argument
[ Upstream commit 0e60f0b758 ]

Xtensa has two-argument MAKE_PC_FROM_RA macro to convert a0 to an actual
return address because when windowed ABI is used call{,x}{4,8,12}
opcodes stuff encoded window size into the top 2 bits of the register
that becomes a return address in the called function. Second argument of
that macro is supposed to be an address having these 2 topmost bits set
correctly, but the comment suggested that that could be the stack
address. However the stack doesn't have to be in the same 1GByte region
as the code, especially in noMMU XIP configurations.

Fix the comment and use either _text or regs->pc as the second argument
for the MAKE_PC_FROM_RA macro.

Cc: stable@vger.kernel.org
Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-06-21 14:35:39 +02:00
..
syscalls arch: syscalls: simplify uapi/kapi directory creation 2022-03-31 12:03:46 +09:00
.gitignore
align.S xtensa: use register window specific opcodes only when present 2021-10-18 22:19:35 -07:00
asm-offsets.c xtensa: improve call0 ABI probing 2022-05-17 03:35:43 -07:00
coprocessor.S xtensa: support coprocessors on SMP 2022-05-01 19:51:23 -07:00
entry.S RCU pull request for v5.20 (or whatever) 2022-08-02 19:12:45 -07:00
head.S xtensa: use register window specific opcodes only when present 2021-10-18 22:19:35 -07:00
hibernate.c xtensa: add hibernation support 2022-05-01 19:51:24 -07:00
hw_breakpoint.c
irq.c genirq: Return a const cpumask from irq_data_get_affinity_mask 2022-07-07 09:38:04 +01:00
jump_label.c xtensa: patch_text: Fixup last cpu should be master 2022-04-13 03:36:34 -07:00
Makefile kbuild: use obj-y instead extra-y for objects placed at the head 2022-10-02 18:04:05 +09:00
mcount.S xtensa: implement call0 ABI support in assembly 2021-10-18 22:19:35 -07:00
module.c
mxhead.S xtensa: add missing XCHAL_HAVE_WINDOWED check 2022-03-09 13:59:15 -08:00
pci-dma.c
pci.c
perf_event.c xtensa: PMU: fix base address for the newer hardware 2023-09-13 09:43:01 +02:00
platform.c
process.c xtensa: fix MAKE_PC_FROM_RA second argument 2024-06-21 14:35:39 +02:00
ptrace.c While looking at the ptrace problems with PREEMPT_RT and the problems 2022-06-03 16:13:25 -07:00
s32c1i_selftest.c xtensa: clean up exception handler prototypes 2022-05-01 19:51:22 -07:00
setup.c xtensa: make secondary reset vector support conditional 2022-03-09 16:59:18 -08:00
signal.c xtensa: fix signal delivery to FDPIC process 2023-05-30 14:03:18 +01:00
smp.c xtensa: support coprocessors on SMP 2022-05-01 19:51:23 -07:00
stacktrace.c xtensa: fix MAKE_PC_FROM_RA second argument 2024-06-21 14:35:39 +02:00
syscall.c xtensa: remove vma linked list walks 2022-09-26 19:46:20 -07:00
time.c xtensa: Fix refcount leak bug in time.c 2022-06-18 14:46:59 -07:00
traps.c xtensa: fix KASAN report for show_stack 2023-04-06 12:10:54 +02:00
vectors.S xtensa: rename PT_SIZE to PT_KERNEL_SIZE 2022-03-07 12:02:48 -08:00
vmlinux.lds.S xtensa: make secondary reset vector support conditional 2022-03-09 16:59:18 -08:00
xtensa_ksyms.c xtensa: add __bswap{si,di}2 helpers 2023-05-30 14:03:18 +01:00