spiFlash: 0x0000 is not a valid jedec id

This commit is contained in:
Gwenhael Goavec-Merou 2024-07-27 10:27:34 +02:00
parent a39524636b
commit a7a1a788ff
1 changed files with 1 additions and 1 deletions

View File

@ -525,7 +525,7 @@ void SPIFlash::read_id()
}
/* something wrong with read */
if ((_jedec_id >> 8) == 0xffff)
if ((_jedec_id >> 8) == 0xffff || (_jedec_id >> 8) == 0x0000)
throw std::runtime_error("Read ID failed");
if (_verbose > 0)