mtd: spi-nor: intel-spi: Simulate WRDI command
authorAlexander Sverdlin <alexander.sverdlin@nokia.com>
Wed, 22 Jul 2020 14:01:36 +0000 (16:01 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 19 Aug 2020 06:24:16 +0000 (08:24 +0200)
commitbb4be8753b8018ea4ff05226f826ae948db960b3
tree294a5d60d49a5ed8af100a28eb8f44497d36fc9e
parent3bba00dd6b10411bdff3e06e7e836581ea31d55b
mtd: spi-nor: intel-spi: Simulate WRDI command

commit 44a80df4bfce02f5d51fe5040bdbdf10d0d78f4e upstream.

After spi_nor_write_disable() return code checks were introduced in the
spi-nor front end intel-spi backend stopped to work because WRDI was never
supported and always failed.

Just pretend it was sucessful and ignore the command itself. HW sequencer
shall do the right thing automatically, while with SW sequencer we cannot
do it anyway, because the only tool we had was preopcode and it makes no
sense for WRDI.

Fixes: bce679e5ae3a ("mtd: spi-nor: Check for errors after each Register Operation")
Signed-off-by: Alexander Sverdlin <alexander.sverdlin@nokia.com>
Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/282e1305-fd08-e446-1a22-eb4dff78cfb4@nokia.com
Signed-off-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/mtd/spi-nor/controllers/intel-spi.c