SPI NOR w25q128 "flash operation timed out"

Klotz, Oliver Oliver.Klotz at knorr-bremse.com
Fri Feb 17 00:22:25 PST 2023


I am using an am335x based SOM with SPI NOR flash.
Recently the SOM vendor replaced Micron n25q128a13 with Winbond w25q128.

Winbond works fine with barebox-2016.07.0, but fails with barebox-2023.01.0, barebox-2022.09.0, barebox-2021.07.0.

Although the device is properly detected as “m25p80 m25p80 at 00: w25q128 (16384 Kbytes)” – INFO(0xef4018).
erase and mw commands end in "flash operation timed out".

I tried w/wo CONFIG_MTD_SPI_NOR_USE_4K_SECTORS and with 24/48MHz SPI clock.

I have added some trace messages for read_sr() and run “erase /dev/m25p0.bareboxenv” (partition size = 128 Kbytes, sector size = 64 Kbytes)

read_sr() returns 0x00 0x03 0x03 0x03 0x03 0x03 0x03 and then it is stuck to 0xff and this is causing the timeout.

When running the same binary on the Micron-SOM then I get 0x00, a bunch of 0x03, 0x00, a bunch of 0x03 and finally 0x00 as expected for erasing 2 sectors.

Is anyone facing similar issue with w25q128?

Any idea what might be the problem here?

Thanks and best Regards

Oliver Klotz

Kiepe Electric GmbH
Firmensitz:  Kiepe-Platz 1, D-40599 Düsseldorf
Geschäftsführer: Alexander Ketterl
Registergericht: Düsseldorf HRB 34306
Zertifiziert: DIN EN ISO 9001:2015

This transmission is intended solely for the addressee and contains confidential information.
If you are not the intended recipient, please immediately inform the sender and delete the message and any attachments from your system.
Furthermore, please do not copy the message or disclose the contents to anyone unless agreed otherwise. To the extent permitted by law we shall in no way be liable for any damages, whatever their nature, arising out of transmission failures, viruses, external influence, delays and the like.

More information about the barebox mailing list