Author: wmb Date: 2009-08-28 23:54:40 +0200 (Fri, 28 Aug 2009) New Revision: 1338
Modified: cpu/x86/pc/olpc/devices.fth cpu/x86/pc/olpc/fw.bth Log: OLPC XO-1 - Updated XO-1 build to match changes to XO-1.5 build, particularly relating to the use of full console multiplexing instead of dualconsole.
Modified: cpu/x86/pc/olpc/devices.fth =================================================================== --- cpu/x86/pc/olpc/devices.fth 2009-08-28 21:40:06 UTC (rev 1337) +++ cpu/x86/pc/olpc/devices.fth 2009-08-28 21:54:40 UTC (rev 1338) @@ -82,6 +82,8 @@ ; warning !
+fload ${BP}/dev/olpc/spiflash/flashif.fth \ Generic FLASH interface + \ Create the top-level device node to access the entire boot FLASH device 0 0 " fff00000" " /" begin-package " flash" device-name @@ -248,7 +250,6 @@
fload ${BP}/dev/geode/acpi.fth \ Power management
-fload ${BP}/dev/olpc/spiflash/flashif.fth \ Generic FLASH interface fload ${BP}/dev/olpc/spiflash/memflash.fth \ Memory-mapped FLASH access
warning @ warning off
Modified: cpu/x86/pc/olpc/fw.bth =================================================================== --- cpu/x86/pc/olpc/fw.bth 2009-08-28 21:40:06 UTC (rev 1337) +++ cpu/x86/pc/olpc/fw.bth 2009-08-28 21:54:40 UTC (rev 1338) @@ -222,6 +222,11 @@ fload ${BP}/cpu/x86/pc/boot.fth fload ${BP}/cpu/x86/pc/linux.fth
+0 value keyboard-ih +0 value screen-ih + +fload ${BP}/ofw/core/muxdev.fth \ I/O collection/distribution device + : usb-port-power-map ( -- n ) board-revision h# b10 h# b2f between if \ B1 and B2 h# 3ab \ USB4:PWR1 USB3:PWR1 USB2:PWR1 USB1:PWR2 @@ -238,10 +243,10 @@
hex : i-key-wait ( ms -- pressed? ) - cr ." Type 'i' to interrupt stand-init sequence" cr + cr ." Type 'i' to interrupt stand-init sequence" cr ( ms ) 0 do - key? if - key upc ascii I = if true unloop exit then + ukey? if + ukey upc ascii I = if true unloop exit then then 1 ms loop @@ -252,7 +257,6 @@
: protect-fw ( -- ) secure? if ec-indexed-io-off then ;
-\ stand-init-debug? [if] warning @ warning off : init \ initial-heap add-memory @@ -274,7 +278,7 @@ [then] then ; -\ warning ! +warning ! [then]
: (.firmware) ( -- ) @@ -292,7 +296,6 @@ fload ${BP}/dev/null.fth fload ${BP}/ofw/core/bailout.fth
-[ifdef] olpc \ GUI false value gui-safeboot?
@@ -303,13 +306,11 @@ true value user-mode?
fload ${BP}/cpu/x86/pc/olpc/banner.fth -[then]
fload ${BP}/ofw/gui/loadmenu.fth fload ${BP}/cpu/x86/pc/olpc/disptest.fth \ fload ${BP}/ofw/gui/insticon.fth
-[ifdef] olpc : setup-for-linux ( -- ) [ ' linux-hook behavior compile, ] \ Chain to old behavior vpci-devices-on \ Do this after quieting USB @@ -321,6 +322,21 @@ ; ' screen-#lines to lines/page
+true value text-on? +: text-off ( -- ) + text-on? if + screen-ih remove-mux + false to text-on? + then +; +: text-on ( -- ) + text-on? 0= if + screen-ih add-mux + cursor-on + true to text-on? + then +; + fload ${BP}/cpu/x86/pc/olpc/help.fth fload ${BP}/cpu/x86/pc/olpc/gui.fth fload ${BP}/cpu/x86/pc/olpc/suspend.fth \ Suspend/resume setup @@ -332,7 +348,6 @@ fload ${BP}/cpu/x86/pc/olpc/crypto.fth \ Cryptographic image validation fload ${BP}/cpu/x86/pc/olpc/lzip.fth \ Access zip images from memory fload ${BP}/cpu/x86/pc/olpc/gamekeys.fth -fload ${BP}/cpu/x86/pc/olpc/memtest.fth
: emacs ( -- ) false to already-go? @@ -357,7 +372,6 @@ [then] fload ${BP}/cpu/x86/pc/olpc/rtcwake.fth ' gx-power-off to power-off -[then]
[ifdef] use-ega : ega-output ( -- ) @@ -419,7 +433,7 @@ then
ec-reboot \ Tell the EC to reboot us, so the EC can reset too - begin again + begin halt again ; ' dcon-reset-all to reset-all
@@ -440,6 +454,7 @@ fload ${BP}/ofw/inet/http.fth \ HTTP client end-support-package
+fload ${BP}/cpu/x86/pc/olpc/memtest.fth
fload ${BP}/ofw/wifi/wifi-cfg.fth support-package: supplicant @@ -486,8 +501,8 @@
" dhcp" ' ip-address set-config-string-default
-\ fload ${BP}/cpu/x86/pc/report.fth -fload ${BP}/ofw/core/dualconsole.fth +: c1-idle ( -- ) interrupts-enabled? if halt then ; +' c1-idle to stdin-idle
: fast-boot? ( -- flag ) [ifdef] rom-loaded @@ -503,6 +518,21 @@ 1 h# 61 cmos! 1 h# 60 cmos! ;
+: console-start ( -- ) + video-map cr + + install-mux-io + cursor-off + true to text-on? + + + " //null" open-dev to null-ih \ For text-off state + + ?gui-banner +\ ." nvramrc" cr +\ use-nvramrc? if nvramrc safe-evaluate then +; + : interpreter-init ( -- ) hex warning on @@ -531,24 +561,6 @@ then ( ) ;
- -: console-start ( -- ) -[ifdef] rom-loaded - video-map cr -[then] - " screen" open-dev ?dup if - set-stdout -\ logo-banner drop -\ close-dev -\ 0 stdout ! - then - - install-dual-console - - ?gui-banner -\ ." nvramrc" cr -\ use-nvramrc? if nvramrc safe-evaluate then -; : debug-interact ( -- ) early-interact? if " Interrupting startup sequence prior to probing" .because @@ -586,9 +598,6 @@ button-check button-x or button-o or button-square or ( mask ) game-key-mask = if protect-fw try-fs-update then ; -: open-keyboard ( -- ) - " keyboard" open-dev ?dup if set-stdin then -;
: ?resume-botch h# 1454 pl@ 2 and if @@ -619,17 +628,22 @@ then
read-game-keys - stdout off \
+ text-off + " probe-" do-drop-in
probe-pci + show-child + install-alarm sound - open-keyboard ?games + ['] false to interrupt-auto-boot? probe-usb " probe+" do-drop-in + report-disk + report-keyboard
setup-smbios \ Must be done after build-date is defined via do-drop-in
@@ -641,10 +655,12 @@ unblock-exceptions ['] (interrupt-auto-boot?) to interrupt-auto-boot? ?usb-keyboard + auto-banner? if banner then + auto-boot
- frozen? ( frozen? ) - unfreeze visible ( frozen? ) + frozen? text-on? 0= and ( no-banner? ) + unfreeze visible ( no-banner? ) if banner then \ Reissue banner if it was suppressed
blue-letters ." Type 'help' for more information." black-letters