Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-7]: src/sys/arch/x68k/x68k Pull up following revision(s) (request...



details:   https://anonhg.NetBSD.org/src/rev/fcd3c1671c30
branches:  netbsd-7
changeset: 799646:fcd3c1671c30
user:      riz <riz%NetBSD.org@localhost>
date:      Thu Nov 05 20:40:22 2015 +0000

description:
Pull up following revision(s) (requested by isaki in ticket #983):
        sys/arch/x68k/x68k/machdep.c: revision 1.192
To turn off the power, it's necessary to turn off the alarm signal
of RTC before writing the system port.  This is a fix for rev 1.191.
Thanks to Y.Sugahara.
Should be pulled up to netbsd-7.

diffstat:

 sys/arch/x68k/x68k/machdep.c |  9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)

diffs (37 lines):

diff -r dddde7f18822 -r fcd3c1671c30 sys/arch/x68k/x68k/machdep.c
--- a/sys/arch/x68k/x68k/machdep.c      Thu Nov 05 20:36:03 2015 +0000
+++ b/sys/arch/x68k/x68k/machdep.c      Thu Nov 05 20:40:22 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: machdep.c,v 1.191 2014/03/26 16:21:39 isaki Exp $      */
+/*     $NetBSD: machdep.c,v 1.191.4.1 2015/11/05 20:40:22 riz Exp $    */
 
 /*
  * Copyright (c) 1988 University of Utah.
@@ -39,7 +39,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.191 2014/03/26 16:21:39 isaki Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.191.4.1 2015/11/05 20:40:22 riz Exp $");
 
 #include "opt_ddb.h"
 #include "opt_kgdb.h"
@@ -106,6 +106,7 @@
 #include <machine/bus.h>
 #include <machine/autoconf.h>
 #include <arch/x68k/dev/intiovar.h>
+#include <arch/x68k/x68k/iodevice.h>
 
 extern void doboot(void) __attribute__((__noreturn__));
 
@@ -522,6 +523,10 @@
        if (((howto & RB_POWERDOWN) == RB_POWERDOWN) && power_switch_is_off) {
                printf("powering off...\n");
                delay(1000000);
+
+               /* Turn off the alarm signal of RTC */
+               IODEVbase->io_rtc.bank0.reset = 0x0c;
+
                intio_set_sysport_powoff(0x00);
                intio_set_sysport_powoff(0x0f);
                intio_set_sysport_powoff(0x0f);



Home | Main Index | Thread Index | Old Index