summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkettenis <kettenis@openbsd.org>2008-04-20 21:42:00 +0000
committerkettenis <kettenis@openbsd.org>2008-04-20 21:42:00 +0000
commit524be3a647bde590d3889fad881b3c94647f99d6 (patch)
treef65326f9c245724c065bad26f2d824452f72703e
parentbe quiet even when errors happen; ok kettenis (diff)
downloadwireguard-openbsd-524be3a647bde590d3889fad881b3c94647f99d6.tar.xz
wireguard-openbsd-524be3a647bde590d3889fad881b3c94647f99d6.zip
Try to reset the machine through the firmware to reboot.
-rw-r--r--sys/arch/hppa64/hppa64/machdep.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/sys/arch/hppa64/hppa64/machdep.c b/sys/arch/hppa64/hppa64/machdep.c
index d8256e5c944..4f9e53bb6c0 100644
--- a/sys/arch/hppa64/hppa64/machdep.c
+++ b/sys/arch/hppa64/hppa64/machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: machdep.c,v 1.9 2008/04/20 11:53:11 kettenis Exp $ */
+/* $OpenBSD: machdep.c,v 1.10 2008/04/20 21:42:00 kettenis Exp $ */
/*
* Copyright (c) 2005 Michael Shalayeff
@@ -673,6 +673,10 @@ boot(howto)
} else {
printf("rebooting...");
DELAY(2000000);
+
+ /* ask firmware to reset */
+ pdc_call((iodcio_t)pdc, 0, PDC_BROADCAST_RESET, PDC_DO_RESET);
+
__asm __volatile(".export hppa_reset, entry\n\t"
".label hppa_reset");
__asm __volatile("stwas %0, 0(%1)"