Avoid calling flashIsReady when flash chip is non-existent
Ideally, the flashfs driver should keep track of information regarding underlying flash chip device, but it is nearly stateless.
This commit is contained in:
parent
91c4a496a7
commit
715e54cf3c
|
@ -110,7 +110,9 @@ void flashfsEraseRange(uint32_t start, uint32_t end)
|
|||
*/
|
||||
bool flashfsIsReady(void)
|
||||
{
|
||||
return flashIsReady();
|
||||
// Check for flash chip existence first, then check if ready.
|
||||
|
||||
return (flashfsIsSupported() && flashIsReady());
|
||||
}
|
||||
|
||||
bool flashfsIsSupported(void)
|
||||
|
|
Loading…
Reference in New Issue