Author: pgf
Date: Mon Jul 30 09:13:00 2012
New Revision: 3094
URL: http://tracker.coreboot.org/trac/openfirmware/changeset/3094
Log:
bbedi: clock faster on cl4
Modified:
cpu/arm/olpc/bbedi.fth
Modified: cpu/arm/olpc/bbedi.fth
==============================================================================
--- cpu/arm/olpc/bbedi.fth Mon Jul 30 09:12:55 2012 (r3093)
+++ cpu/arm/olpc/bbedi.fth Mon Jul 30 09:13:00 2012 (r3094)
@@ -106,10 +106,15 @@
begin
ands r3,tos,#0x80 \ Test bit
+[ifdef] olpc-cl4
+ strne r0,[r1,#0x18] \ Set MOSI if bit is non0
+ streq r0,[r1,#0x24] \ Clr MOSI if bit is 0
+[else]
strne r0,[r1,#0x18] \ Set MOSI if bit is non0
strne r0,[r1,#0x18] \ Set MOSI if bit is non0 \ Twice for delay - setup time to CLK
streq r0,[r1,#0x24] \ Clr MOSI if bit is 0
streq r0,[r1,#0x24] \ Clr MOSI if bit is 0 \ Twice for delay - setup time to CLK
+[then]
str r4,[r1,#0x18] \ Set CLK
str r4,[r1,#0x24] \ Clr CLK
Author: wmb
Date: Fri Jul 27 04:55:18 2012
New Revision: 3086
URL: http://tracker.coreboot.org/trac/openfirmware/changeset/3086
Log:
OLPC SPIFLASH driver - handle 2 MB parts.
Modified:
dev/olpc/spiflash/spiflash.fth
Modified: dev/olpc/spiflash/spiflash.fth
==============================================================================
--- dev/olpc/spiflash/spiflash.fth Fri Jul 27 04:54:42 2012 (r3085)
+++ dev/olpc/spiflash/spiflash.fth Fri Jul 27 04:55:18 2012 (r3086)
@@ -199,6 +199,8 @@
3drop
;
+: null-write ( adr len offset -- ) 3drop ;
+
\ This version is for SST parts, which use an auto-increment
\ address command for fast writing. The SST part does not
\ require you to stop at 256-byte page boundaries. The
@@ -306,12 +308,16 @@
h# 13 of ['] common-write endof
h# 34 of ['] common-write endof
h# bf of ['] sst-write endof
- h# 14 of
- ." The SPI FLASH ID reads as 14. This is due to an infrequent hardware problem." cr
- ." If you power cycle and try again, it will probably work the next time." cr
- abort
- endof
- ( default ) true abort" Unsupported SPI FLASH ID"
+ h# 14 of ['] common-write endof
+\ On some old board the ID would read as 14 when it should have been something else.
+\ On CL4, 14 is the expected ID.
+\ ." The SPI FLASH ID reads as 14. This is due to an infrequent hardware problem." cr
+\ ." If you power cycle and try again, it will probably work the next time." cr
+\ abort
+\ endof
+
+\ ( default ) true abort" Unsupported SPI FLASH ID"
+ ( default ) ." Bad SPI FLASH ID " dup . cr ['] null-write swap
endcase
to write-spi-flash
spi-unprotect
@@ -326,6 +332,7 @@
else
spi-id# case
h# 13 of ." type 13 - Spansion, Winbond, or ST" endof
+ h# 14 of ." type 14 - 2 MB" endof
h# 34 of ." type 34 - Macronyx" endof
endcase
then