linux-stable/arch
Breno Leitao 8117508a9c powerpc/xmon: Fix invocation inside lock region
[ Upstream commit 8d4a862276 ]

Currently xmon needs to get devtree_lock (through rtas_token()) during its
invocation (at crash time). If there is a crash while devtree_lock is being
held, then xmon tries to get the lock but spins forever and never get into
the interactive debugger, as in the following case:

	int *ptr = NULL;
	raw_spin_lock_irqsave(&devtree_lock, flags);
	*ptr = 0xdeadbeef;

This patch avoids calling rtas_token(), thus trying to get the same lock,
at crash time. This new mechanism proposes getting the token at
initialization time (xmon_init()) and just consuming it at crash time.

This would allow xmon to be possible invoked independent of devtree_lock
being held or not.

Signed-off-by: Breno Leitao <leitao@debian.org>
Reviewed-by: Thiago Jung Bauermann <bauerman@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-01-26 09:38:33 +01:00
..
alpha arch/alpha, termios: implement BOTHER, IBSHIFT and termios2 2018-11-21 09:26:00 +01:00
arc ARC: io.h: Implement reads{x}()/writes{x}() 2018-12-21 14:11:35 +01:00
arm ARM: dts: imx7d-nitrogen7: Fix the description of the Wifi clock 2019-01-13 10:03:47 +01:00
arm64 arm64: perf: set suppress_bind_attrs flag to true 2019-01-26 09:38:33 +01:00
avr32
blackfin
c6x
cris
frv futex: Remove duplicated code and fix undefined behaviour 2018-05-19 10:27:00 +02:00
h8300
hexagon hexagon: modify ffs() and fls() to return int 2018-10-10 08:53:21 +02:00
ia64 kbuild: Consolidate header generation from ASM offset information 2018-11-23 08:20:34 +01:00
m32r
m68k m68k: fix "bad page state" oops on ColdFire boot 2018-08-24 13:12:34 +02:00
metag
microblaze microblaze: Fix simpleImage format generation 2018-08-03 07:55:25 +02:00
mips MIPS: SiByte: Enable swiotlb for SWARM, LittleSur and BigSur 2019-01-26 09:38:33 +01:00
mn10300
nios2
openrisc kthread: fix boot hang (regression) on MIPS/OpenRISC 2018-09-19 22:47:11 +02:00
parisc parisc: Fix exported address of os_hpmc handler 2018-11-21 09:25:58 +01:00
powerpc powerpc/xmon: Fix invocation inside lock region 2019-01-26 09:38:33 +01:00
s390 s390/cpum_cf: Reject request for sampling in event initialization 2018-12-17 09:38:32 +01:00
score
sh sh: fix debug trap failure to process signals before return to user 2018-05-30 07:50:39 +02:00
sparc sparc64: Make proc_id signed. 2018-11-13 11:16:47 -08:00
tile futex: Remove duplicated code and fix undefined behaviour 2018-05-19 10:27:00 +02:00
um um: Give start_idle_thread() a return code 2018-11-27 16:09:38 +01:00
unicore32
x86 crypto: x86/chacha20 - avoid sleeping with preemption disabled 2019-01-13 10:03:51 +01:00
xtensa xtensa: fix coprocessor context offset definitions 2018-12-05 19:42:39 +01:00
.gitignore
Kconfig cpu/hotplug: Provide knobs to control SMT 2018-08-15 18:14:46 +02:00