[U-Boot] CFI status register polling

jon.bird at gd-ms.uk jon.bird at gd-ms.uk
Tue Oct 31 08:33:41 UTC 2017


Hi,

We are currently integrating a new board fitted with Micron NOR Flash (MT28EW01GABA) and the current u-boot baseline is having issues in protecting the flash (hangs indefinitely during startup when CONFIG_SYS_FLASH_PROTECTION is enabled) and timeouts during erase. By contrast, a somewhat older build appears to work fine.

I believe the problem is related to commit 72443c7f7d2174903e73ee88dcb4364e0387bbb2 made on 12/09 which added support for status register polling on devices which utilise the AMD command set (which the Micron device does). I'm not an expert of the Flash/CFI interfaces but the original patch reads:

> The status register is optional in the AMD command sets, but it's presence can be checked by reading out CFI table entry 0xc bit 0.

Initially this confused me because there is no offset 0xc in the CFI table, the polling information is (and only on latter devices) available at offset 0x52 in CFI. The mode we're in at the point this request is made is referred to in the Micron datasheet as Auto Select mode (elsewhere I've seen it referred to as ID Mode). I've not been able to find a definitive reference on what should be returned whilst in this mode, I imagine it'll always have the manufacturer and device code information however that is all that is available in the Micron device. Offset 0xc is not documented and hence isn't going to provide the expected status information. 

Rgs,


Jon.

--
Jon Bird, CEng MBCS
Software Engineer
Electronic Systems
General Dynamics United Kingdom Ltd.
Castleham Road, St Leonards on Sea, East Sussex, TN38 9NJ

Telephone: +441424798278
Email: jon.bird at gd-ms.uk
Website: www.generaldynamics.uk.com      


------------------------------------------------------------------------------

This email and any files attached are intended for the addressee and may contain information of a confidential nature. If you are not the intended recipient, be aware that this email was sent to you in error and you should not disclose, distribute, print, copy or make other use of this email or its attachments. Such actions, in fact, may be unlawful. In compliance with the various Regulations and Acts, General Dynamics United Kingdom Limited reserves the right to monitor (and examine for viruses) all emails and email attachments, both inbound and outbound. Email communications and their attachments may not be secure or error- or virus-free and the company does not accept liability or responsibility for such matters or the consequences thereof. General Dynamics United Kingdom Limited, Registered Office: 21 Holborn Viaduct, London EC1A 2DY. Registered in England and Wales No: 1911653.



More information about the U-Boot mailing list