linux/arch/powerpc/platforms
Nicholas Piggin f2748bdfe1 powerpc/powernv: Always stop secondaries before reboot/shutdown
Currently powernv reboot and shutdown requests just leave secondaries
to do their own things. This is undesirable because they can trigger
any number of watchdogs while waiting for reboot, but also we don't
know what else they might be doing -- they might be causing trouble,
trampling memory, etc.

The opal scheduled flash update code already ran into watchdog problems
due to flashing taking a long time, and it was fixed with 2196c6f1ed
("powerpc/powernv: Return secondary CPUs to firmware before FW update"),
which returns secondaries to opal. It's been found that regular reboots
can take over 10 seconds, which can result in the hard lockup watchdog
firing,

  reboot: Restarting system
  [  360.038896709,5] OPAL: Reboot request...
  Watchdog CPU:0 Hard LOCKUP
  Watchdog CPU:44 detected Hard LOCKUP other CPUS:16
  Watchdog CPU:16 Hard LOCKUP
  watchdog: BUG: soft lockup - CPU#16 stuck for 3s! [swapper/16:0]

This patch removes the special case for flash update, and calls
smp_send_stop in all cases before calling reboot/shutdown.

smp_send_stop could return CPUs to OPAL, the main reason not to is
that the request could come from a NMI that interrupts OPAL code,
so re-entry to OPAL can cause a number of problems. Putting
secondaries into simple spin loops improves the chances of a
successful reboot.

Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Reviewed-by:  Vasant Hegde <hegdevasant@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
2018-04-03 22:59:57 +10:00
..
4xx powerpc/4xx: Fix error return code in ppc4xx_msi_probe() 2018-03-31 00:10:34 +11:00
8xx powerpc/8xx: fix cpm_cascade() dual end of interrupt 2018-03-13 15:50:28 +11:00
40x License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
44x powerpc/44x/fsp2: Add irq error handlers 2017-12-11 13:03:34 +11:00
52xx powerpc/mpc52xx_gpt: make use of raw_spinlock variants 2018-01-27 21:12:04 +11:00
82xx License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
83xx powerpc: Use octal numbers for file permissions 2018-01-22 05:48:33 +11:00
85xx powerpc/64: Use array of paca pointers and allocate pacas individually 2018-03-30 23:34:23 +11:00
86xx powerpc: Use pr_warn instead of pr_warning 2017-12-04 11:54:34 +11:00
512x powerpc: Use pr_warn instead of pr_warning 2017-12-04 11:54:34 +11:00
amigaone License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
cell Merge branch 'topic/paca' into next 2018-03-31 09:09:36 +11:00
chrp License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
embedded6xx powerpc/wii: Don't rely on the reserved memory hack 2018-04-01 00:47:43 +11:00
maple powerpc: Set I/O port resource types correctly 2017-12-18 23:07:45 -06:00
pasemi powerpc updates for 4.16 2018-02-02 10:01:04 -08:00
powermac powerpc: Use sizeof(*foo) rather than sizeof(struct foo) 2018-03-20 16:47:53 +11:00
powernv powerpc/powernv: Always stop secondaries before reboot/shutdown 2018-04-03 22:59:57 +10:00
ps3 powerpc: Use sizeof(*foo) rather than sizeof(struct foo) 2018-03-20 16:47:53 +11:00
pseries powerpc/pseries: Restore default security feature flags on setup 2018-04-03 21:50:09 +10:00
fsl_uli1575.c
Kconfig powerpc/cell: Remove axonram driver 2018-01-28 17:00:36 +11:00
Kconfig.cputype powerpc/64s: Add POWER9 CPU type selection 2018-04-01 22:15:32 +10:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00