[OpenBIOS] r693 - cpu/x86/pc/olpc dev/olpc/kb3700

svn at openbios.org svn at openbios.org
Tue Oct 23 02:59:11 CEST 2007


Author: wmb
Date: 2007-10-23 02:59:11 +0200 (Tue, 23 Oct 2007)
New Revision: 693

Modified:
   cpu/x86/pc/olpc/security.fth
   dev/olpc/kb3700/ecio.fth
Log:
OLPC trac #4397 - Reboot using the new EC command that reset the EC too,
thus re-enabling indexed I/O, thus making auto-firmware-update possible.


Modified: cpu/x86/pc/olpc/security.fth
===================================================================
--- cpu/x86/pc/olpc/security.fth	2007-10-20 09:10:33 UTC (rev 692)
+++ cpu/x86/pc/olpc/security.fth	2007-10-23 00:59:11 UTC (rev 693)
@@ -652,7 +652,7 @@
                visible
                ." Restarting to enable SPI FLASH writing."  cr
                d# 3000 ms
-               ec-reboot
+               ec-ixio-reboot
                security-failure
             then
 

Modified: dev/olpc/kb3700/ecio.fth
===================================================================
--- dev/olpc/kb3700/ecio.fth	2007-10-20 09:10:33 UTC (rev 692)
+++ dev/olpc/kb3700/ecio.fth	2007-10-23 00:59:11 UTC (rev 693)
@@ -210,8 +210,18 @@
 
 \ This restarts the EC and the CPU, resetting the EC state to its default.
 \ EC indexed I/O will come up in enabled state.
-: ec-reboot  ( -- )   h# db ec-cmd66  begin again   ;
+: ec-reboot  ( -- )   h# db ec-cmd66  ;
 
+: ec-ixio-reboot  ( -- )
+   ['] ec-reboot catch  if
+      ." Automatic restart failed.  Remove/reinstall the battery and AC." cr
+      d# 10,000 ms
+      power-off
+   else
+      begin again    \ Just wait for it to happen
+   then
+;
+
 : ec-indexed-io-off?  ( -- flag )  h# ff14 ec@  h# ff =  ;
 : ?ixio-restart  ( -- )
    ec-indexed-io-off?  if
@@ -219,7 +229,7 @@
       ." Restarting to enable SPI FLASH writing.  Try again after the system restarts."
       black-letters cr
       d# 5000 ms
-      ec-reboot
+      ec-ixio-reboot
    then
 ;
 




More information about the OpenBIOS mailing list