Bin Meng 4dc8279758 spi: ich: Limit slave->max_read_size
Since commit 43c145b8b3ee ("spi: ich: Correct max-size bug in ich_spi_adjust_size()")
(in v2020.04-rc1), SPI flash read no longer works with ICH SPI controller
in software sequencer mode.

ICH controller can only transfer a small number of bytes at once.
Before commit 43c145b8b3ee, the logic happens to make sure data.nbytes
is limited to slave->max_write_size but after commit 43c145b8b3ee
data.nbytes is no longer limited because slave->max_read_size is not
initialized with a valid number.

Fixes: 43c145b8b3ee ("spi: ich: Correct max-size bug in ich_spi_adjust_size()")
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2021-08-02 15:11:40 +08:00
..
2020-12-18 20:32:21 -07:00
2020-06-11 15:14:04 +05:30
2021-08-02 15:11:40 +08:00
2021-02-26 15:09:38 +05:30
2020-12-18 20:32:21 -07:00
2021-06-25 20:59:45 +05:30
2021-06-30 08:06:30 -04:00
2021-02-23 10:45:55 -05:00
2021-02-23 10:45:55 -05:00