Flash read failures happen in some cases. They are as follows:
- A certain address range is used to map the flash
contents when the OSPI controller is in DAC state. The available address range
is shown in Figure 5-2. By default, 0x60000000 is selected. read failures happen when the MPU Region
0x60000000 is marked as cached. This is the region used for Direct Memory
Mapping of the Flash. In software, this is achieved by setting the
7th bit, DAC bit, in register 0xFC40000 to 1. As a result,
0x60000000 does not need to be marked as "Cached".
- Read command set in the SysConfig is incorrect for the configured protocol. Some flashes have different read command for 3 byte and 4 bytes addressing.
- Suppose the data on the flash is 00h 01h 02h
03h… and the read values in the buffer are 01h 02h 03h 04h….
This points to section 5.3.1 where the dummy clocks for reading is off by a
value of 1.
- DMA related issues include, data not being read correctly because the read buffer is not cache aligned.