Numonyx NOR support in u-boot
Hi,
We are seeing NOR write failures on 6 of the 10 boards (DM6446 ARM SoC with Numonyx JS28F256M29EWL NOR flash chip). Four of the boards seem to work without error. All 10 boards were made on the same manufacturing line at the same time.
Initially, we couldn't properly read the QRY response from the chip. We had to use this patch
http://www.mail-archive.com/u-boot at lists.denx.de/msg26614.html
We are getting 'flash not erased' error or timeout error. We have tried monitoring D7 (busy) and monitoring D6 (activity toggle) to detect erase / program command completion / timeout. We have tried changing the timing of the control signals to the NOR chip, but need to use a logic state analyzer to verify the timing is changed as expected.
Example error output:
Quoted 1 line
cp
0x817000000x020000000x400000
Copy to Flash... Flash not Erased
Timeout writing to Flash
Quoted 1 line
cp
0x817000000x02000000
0x400000
Copy to Flash... Flash write timeout at address 2000000 data 129f34
We have tried cp, cp.b, cp.w and get the same results.
With 4 boards working correctly, the code must be close.
Any suggestions (beyond looking at the signals with a Logic State Analyzer)?
Todd
Quoted 29 lines · Todd Fischer
Hi,
We are seeing NOR write failures on 6 of the 10 boards (DM6446 ARM SoC with Numonyx JS28F256M29EWL NOR flash chip). ?Four of the boards seem to work without error. ?All 10 boards were made on the same manufacturing line at the same time.
Initially, we couldn't properly read the ?QRY response from the chip. We had to use this patch
http://www.mail-archive.com/u-boot at lists.denx.de/msg26614.html
We are getting 'flash not erased' error or timeout error. ?We have tried monitoring D7 (busy) and monitoring D6 (activity toggle) to detect erase / program command completion / timeout. ?We have tried changing the timing of the control signals to the NOR chip, but need to use a logic state analyzer to verify the timing is changed as expected.
Example error output:
Quoted 1 line
cp
0x817000000x020000000x400000Copy to Flash... Flash not Erased
Timeout writing to FlashQuoted 1 line
cp
0x817000000x02000000
0x400000
Copy to Flash... Flash write timeout at address 2000000 data 129f34
Quoted 7 lines
We have tried cp, cp.b, cp.w and get the same results.
With 4 boards working correctly, the code must be close.
Any suggestions (beyond looking at the signals with a Logic State Analyzer)?
You didn't say what version of u-boot. A few years ago when doing a DM6446 design, we used a modified 1.2.x that TI was distributing with the DM6446 eval boards (customer insisted that we start from the TI distribution), and as I recall it had a bad implementation of the timer routines. If I remember right they were running the timer at something like 3.84 MHz. For a while now, the u-boot standard has been that CONFIG_HZ should be 1000. In the case where it's not, some of the timeouts in the common CFI flash code will be way too short and will occasionally fail. IIRC, TI had their own individual flash.c where the timeouts were done differently, and we only found it when we tried to use the CFI flash code. Another timer problem that will cause similar issues is if the timer ignores the base argument to get_timer().