From 02cff81c14829d2a6f6f89d2f999a32ef542d199 Mon Sep 17 00:00:00 2001 From: andrew Date: Tue, 30 May 2017 13:26:37 +0000 Subject: MFC r317361: Call the PSCI reset from cpu_reset on arm64. When rebooting from DDB the kernel calls this directly so the event handler is not called, meaning the computer fails to reboot. --- sys/arm64/arm64/vm_machdep.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'sys/arm64') diff --git a/sys/arm64/arm64/vm_machdep.c b/sys/arm64/arm64/vm_machdep.c index 1f8466d..acce93c 100644 --- a/sys/arm64/arm64/vm_machdep.c +++ b/sys/arm64/arm64/vm_machdep.c @@ -25,6 +25,8 @@ * */ +#include "opt_platform.h" + #include __FBSDID("$FreeBSD$"); @@ -52,6 +54,10 @@ __FBSDID("$FreeBSD$"); #include #endif +#ifdef DEV_PSCI +#include +#endif + /* * Finish a fork operation, with process p2 nearly set up. * Copy and update the pcb, set up the stack so that the child @@ -112,7 +118,11 @@ void cpu_reset(void) { - printf("cpu_reset"); +#ifdef DEV_PSCI + psci_reset(); +#endif + + printf("cpu_reset failed"); while(1) __asm volatile("wfi" ::: "memory"); } -- cgit v1.1