[U-Boot] Flash not Erased

Jan Schunke schunke at shf.de
Wed Jun 19 17:35:12 CEST 2013


Hello,

I am trying to compile my own U-Boot for microblaze.
Version:
U-Boot 2013.01-dirty (Jun 19 2013 - 16:26:51)
microblazeel-xilinx-linux-gnu-gcc (crosstool-NG 1.15.3) 4.6.4 20120924
(prerelease)
GNU ld (crosstool-NG 1.15.3) 2.22.90.20121010

I have demo where Flash access works fine.
Verion:
U-Boot 2012.10 (Feb 13 2013 - 20:16:43)
microblazeel-xilinx-linux-gnu-gcc (crosstool-NG 1.15.3) 4.6.2 20111018
(prerelease)
GNU ld (crosstool-NG 1.15.3) 2.21.53.20110813


When I use my own u-boot and try to write to flash I always get

"Flash not erased"

it seems to be a problem that my flash is x16 but recognized as x8.

Are there any Config variables to set the mode to x16?


Below are some snippets to show the behavior

..........................................................................................
SHF-U-Boot> saveenv
Saving Environment to Flash...
Protect off 44B40000 ... 44B5FFFF
Un-Protecting sectors 90..90 in bank 1
fwc addr 44b40000 cmd 50 50 8bit x 8 bit
fwc addr 44b40000 cmd 60 60 8bit x 8 bit
fwc addr 44b40000 cmd d0 d0 8bit x 8 bit
fwc addr 44b40000 cmd 70 70 8bit x 8 bit
flash_is_busy: 0
fwc addr 44b40000 cmd ff ff 8bit x 8 bit
. done
Un-Protected 1 sectors
EXPORT  table = bfc3b2cc, htab.size = 79, htab.filled = 13, size = 131068
Unsorted: n=13
          0: bff80070 ==> ipaddr     => 192.168.2.246
          1: bff80084 ==> hostname   => U-BOOT_BSP
          2: bff800c0 ==> baudrate   => 115200
          3: bff80200 ==> bootdelay  => 4
          4: bff80228 ==> serverip   => 192.168.0.1
          5: bff80264 ==> ethaddr    => 00:50:C2:2E:E1:0A
          6: bff802f0 ==> fileaddr   => BA000000
          7: bff80390 ==> bootfile   => k7mmp/u-boot-s.bin
          8: bff803e0 ==> ethact     => Xelite.40e00000
          9: bff804d0 ==> gatewayip  => 192.168.0.1
         10: bff80584 ==> filesize   => 353D0
         11: bff80638 ==> mtdids     => nor0=physmap-flash-0
         12: bff8064c ==> mtdparts   =>
mtdparts=physmap-flash-0:11M(fpga),256K(boot),128K(bootenv),128K(config),12M(image),0M(spare)
Erasing Flash...Erase Flash from 0x44b40000 to 0x44b5ffff in Bank # 1
flash_erase: erasing sectors 90 to 90

fwc addr 44b40000 cmd 50 50 8bit x 8 bit
fwc addr 44b40000 cmd 20 20 8bit x 8 bit
fwc addr 44b40000 cmd d0 d0 8bit x 8 bit
flash_is_busy: 1
...
flash_is_busy: 1
flash_is_busy: 0
fwc addr 44b40000 cmd ff ff 8bit x 8 bit
. done
Erased 1 sectors
Writing to Flash... flash_write_cfiword: 8-bit 0x92
fwc addr 44000000 cmd 50 50 8bit x 8 bit
fwc addr 44000000 cmd 40 40 8bit x 8 bit
flash_is_busy: 1
flash_is_busy: 0
fwc addr 44b40000 cmd ff ff 8bit x 8 bit
flash_write_cfiword: 8-bit 0xe8
Flash not Erased
Protecting sectors 90..90 in bank 1
fwc addr 44b40000 cmd 50 50 8bit x 8 bit
fwc addr 44b40000 cmd 60 60 8bit x 8 bit
fwc addr 44b40000 cmd 1 1 8bit x 8 bit
fwc addr 44b40000 cmd 70 70 8bit x 8 bit
flash_is_busy: 0
fwc addr 44b40000 cmd ff ff 8bit x 8 bit
. done
Protected 1 sectors
Command failed, result=1SHF-U-Boot>
..........................................................................................


Now I try th co command to get more info

..........................................................................................
SHF-U-Boot> md 0xba000000
ba000000: b8b40008 80000000 20a50100 e8c50000    ........... ....
ba000010: e8e50004 e9250008 20a5000c 00860000    ......%.... ....
ba000020: 20e70003 90e70041 90e70041 81400000    ... A...A..... at .
ba000030: bc070018 c9055000 d9065000 214a0004    .....P...P....J!
ba000040: b810fff0 20e7ffff 00844800 98082000    ....... .H... ..
ba000050: 00000000 00000000 00000000 00000000    ................

SHF-U-Boot> cp BA000000 44B00000 D4F5
Copy to Flash... flash_write_cfiword: 8-bit 0x08
fwc addr 44000000 cmd 50 50 8bit x 8 bit
fwc addr 44000000 cmd 40 40 8bit x 8 bit
flash_is_busy: 1
flash_is_busy: 0
fwc addr 44b00000 cmd ff ff 8bit x 8 bit
flash_write_cfiword: 8-bit 0x00
fwc addr 44000000 cmd 50 50 8bit x 8 bit
fwc addr 44000000 cmd 40 40 8bit x 8 bit
flash_is_busy: 1
flash_is_busy: 0
fwc addr 44b00000 cmd ff ff 8bit x 8 bit
flash_write_cfiword: 8-bit 0xb4
fwc addr 44000000 cmd 50 50 8bit x 8 bit
fwc addr 44000000 cmd 40 40 8bit x 8 bit
flash_is_busy: 1
flash_is_busy: 0
fwc addr 44b00000 cmd ff ff 8bit x 8 bit
flash_write_cfiword: 8-bit 0xb8
Flash not Erased
Command failed, result=1SHF-U-Boot> md 44B00000
44b00000: b4b40000 ffffffff ffffffff ffffffff    ................
44b00010: ffffffff ffffffff ffffffff ffffffff    ................
44b00020: ffffffff ffffffff ffffffff ffffffff    .....Verion of working
demo:

U-Boot 2012.10 (Feb 13 2013 - 20:16:43)
microblazeel-xilinx-linux-gnu-gcc (crosstool-NG 1.15.3) 4.6.2 20111018
(prerelease)
GNU ld (crosstool-NG 1.15.3) 2.21.53.20110813


Version of non working:
U-Boot 2013.01-dirty (Jun 19 2013 - 16:26:51)
microblazeel-xilinx-linux-gnu-gcc (crosstool-NG 1.15.3) 4.6.4 20120924
(prerelease)
GNU ld (crosstool-NG 1.15.3) 2.22.90.20121010...........--

..........................................................................................

As you can see the first byte (b4) seems to have been tranfered twice.

fli tells me that I have an 8 x 8 Flash but the working demo reports a
16 x 16 which is what I would expect.


Non working fli
..........................................................................................
SHF-U-Boot> fli

Bank # 1: CFI conformant flash (8 x 8)  Size: 64 MB in 515 Sectors
  Intel Extended command set, Manufacturer ID: 0x89, Device ID: 0x60
  Erase timeout: 4096 ms, write timeout: 2 ms
  Buffer write timeout: 5 ms, buffer size: 1024 bytes

  Sector Start Addresses:
  44000000   RO   44020000   RO   44040000   RO   44060000   RO
44080000   RO
  440A0000   RO   440C0000   RO   440E0000   RO   44100000   RO
44120000   RO
  44140000   RO   44160000   RO   44180000   RO   441A0000   RO
441C0000   RO
.........................................................................................

Working fli
..........................................................................................
Bank # 1: CFI conformant flash (16 x 16)  Size: 64 MB in 515 Sectors
  Intel Extended command set, Manufacturer ID: 0x89, Device ID: 0x8960
  Erase timeout: 4096 ms, write timeout: 2 ms
  Buffer write timeout: 5 ms, buffer size: 1024 bytes
..........................................................................................


Any ideas?

Thanks in advance
Jan




*******************************************************
Jan-Hendrik Schunke
Entwickler / Developer
SHF Communication Technologies AG
Wilhelm-v.-Siemens-Str. 23 D; 12277 Berlin, Germany
E-Mail: schunke at shf.de
Phone:  +49-(0)30- 77 20 51-0 direct: -45
Fax:    +49-(0)30- 75 31 07 8
Web:    www.shf.de
*******************************************************
Sitz der Gesellschaft/Registered Office: Berlin;
Registergericht/Register Court: AG Berlin-Charlottenburg HRB 72633;
Vorstand/Executive Board: Dr. Frank Hieronymi, Dr. Lars Klapproth;
Aufsichtsratsvorsitzender/Chairman of the Supervisory Board: Dr. Walter
L. Rust.

Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte
Informationen und ist ausschließlich für den bezeichneten Adressaten
oder dessen Vertreter bestimmt. Wenn Sie nicht der richtige Adressat
sind oder diese E-Mail irrtümlich erhalten haben, informieren Sie bitte
sofort den Absender und vernichten Sie diese Mail. Jede Form der
Kenntnisnahme, Veröffentlichung, Vervielfältigung oder Weitergabe durch
andere Empfänger ist unzulässig.

This e-mail may contain confidential and/or privileged information and
is intended solely for the addressee or a representative there of. If
you are not the intended recipient (or have received this e-mail in
error) please notify the sender immediately and destroy this e-mail.
Access to, publishing and copying of the information by a third party is
unauthorised.




More information about the U-Boot mailing list