]> git.baikalelectronics.ru Git - kernel.git/commit
mtd: rawnand: stm32_fmc2: avoid to lock the CPU bus
authorChristophe Kerello <christophe.kerello@st.com>
Mon, 16 Dec 2019 09:01:55 +0000 (10:01 +0100)
committerMiquel Raynal <miquel.raynal@bootlin.com>
Thu, 9 Jan 2020 19:03:41 +0000 (20:03 +0100)
commit7257320b0b9753523025bcb3d58d5f7f34a923af
tree5c4e41379e26f3ec11043b65342bcf06f775840d
parentd4f46b330cc523efd6fb99dfb35e4def34bd935c
mtd: rawnand: stm32_fmc2: avoid to lock the CPU bus

We are currently using nand_soft_waitrdy to poll the status of the NAND
flash. FMC2 enables the wait feature bit (this feature is mandatory for
the sequencer mode). By enabling this feature, we can't poll the status
of the NAND flash, the read status command is stucked in FMC2 pipeline
until R/B# signal is high, and locks the CPU bus.
To avoid to lock the CPU bus, we poll FMC2 ISR register. This register
reports the status of the R/B# signal.

Fixes: 2921c9e99cbe ("mtd: rawnand: stm32_fmc2: add STM32 FMC2 NAND flash controller driver")
Signed-off-by: Christophe Kerello <christophe.kerello@st.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
drivers/mtd/nand/raw/stm32_fmc2_nand.c