EC, CForth exploratory commands?

James Cameron quozl at laptop.org
Sun Apr 13 17:00:25 EDT 2014


On Sun, Apr 13, 2014 at 01:48:35PM -0400, Martin Langhoff wrote:
> As part of it I tried -- and mostly failed -- to give folks a tour
> of early boot, using some old boards I have stashed. Here I got
> truly lost. I could not find current useful notes on what you can do
> in the early CForth env.

http://wiki.laptop.org/go/Forth_Lesson_20 covers the early boot from
the point the SoC is powered and begins to run the built-in Marvell
bootloader.  Mitch gave the bootloader an SPI FLASH chip with a
structure containing CForth, which is loaded and run.

We have generally used Open Firmware for most discovery after that, as
it is more feature rich.

http://dev.laptop.org/git/users/wmb/cforth/ for CForth source.  You
can work backward from the ofw word.

http://wiki.laptop.org/go/SPI_FLASH_Recovery_for_XO-4_Using_CForth
describes another use for CForth; when we have a corrupted payload in
the SPI FLASH that prevents Open Firmware from starting.

CForth was also very handy for the XO-1.75 watchdog implementation
when we were looking for a cause of kernel hang correlated with
increased use of serial port.  CForth would detect that the processor
had been reset by its watchdog, then power up RAM and dump the kernel
message buffer.

-- 
James Cameron
http://quozl.linux.org.au/



More information about the Devel mailing list