spi: stm32: add a delay before SPI disable
authorValentin Caron <valentin.caron@foss.st.com>
Wed, 6 Sep 2023 13:27:35 +0000 (15:27 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 6 Oct 2023 12:56:55 +0000 (14:56 +0200)
commit85ca138f922cd99370c56f884631f91cab661ac8
tree4b94669f93e7afac38063a47fcd88bf64b1299d0
parent84592ec591be7d6b03180c389d5a81dea09fabb5
spi: stm32: add a delay before SPI disable

[ Upstream commit 6de8a70c84ee0586fdde4e671626b9caca6aed74 ]

As explained in errata sheet, in section "2.14.5 Truncation of SPI output
signals after EOT event":
On STM32MP1x, EOT interrupt can be thrown before the true end of
communication.

So we add a delay of a half period to wait the real end of the
transmission.

Link: https://www.st.com/resource/en/errata_sheet/es0539-stm32mp131x3x5x-device-errata-stmicroelectronics.pdf
Signed-off-by: Valentin Caron <valentin.caron@foss.st.com>
Link: https://lore.kernel.org/r/20230906132735.748174-1-valentin.caron@foss.st.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/spi/spi-stm32.c