Skip to content
Commit 6182d15b authored by Pratyush Yadav's avatar Pratyush Yadav Committed by Jagan Teki
Browse files

mtd: spi-nor-core: Do not set data direction when there is no data



Even when spi_nor_write_reg() has no data to write, like when executing
a write enable operation, it sets the data direction to
SPI_MEM_DATA_OUT. This trips up spi_mem_check_buswidth() because it
expects a data phase when there is none. Make sure the data direction is
set to SPI_MEM_NO_DATA when there is no data to write.

Signed-off-by: default avatarPratyush Yadav <p.yadav@ti.com>
Reviewed-by: default avatarJagan Teki <jagan@amarulasolutions.com>
parent 71025f01
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment