drivers: flash: flash_mcux_flexspi_nor incorrectly handles border case #87021
Labels
bug
The issue is a bug, or the PR is fixing a bug
platform: NXP
NXP
priority: low
Low impact/importance bug
Describe the bug
#84899 introduced input parameter checking for flash read operations.
The introduced check incorrectly handles the corner case where a read is performed of size 0 into a NULL array. The read fails with error code
-EINVAL
.This introduces a difference between platforms when e.g.
nvs_read
is used to retrieve the size of an already stored element as reported in #86981.To Reproduce
See #86981.
Expected behavior
No difference between platforms.
Logs and console output
See #86981.
Environment (please complete the following information):
See #86981.
The text was updated successfully, but these errors were encountered: