]> git.baikalelectronics.ru Git - kernel.git/commit
spi: fsi: Implement a timeout for polling status
authorEddie James <eajames@linux.ibm.com>
Thu, 17 Mar 2022 21:14:26 +0000 (16:14 -0500)
committerMark Brown <broonie@kernel.org>
Fri, 18 Mar 2022 16:05:08 +0000 (16:05 +0000)
commit41f474fd7232d963e4abbfe3c8c584f0e259f386
tree40c27e02be84cfe185165eaa707f2339f5771325
parentc421fbd13a17fcb37533b5d4f7146a76ef013024
spi: fsi: Implement a timeout for polling status

The data transfer routines must poll the status register to
determine when more data can be shifted in or out. If the hardware
gets into a bad state, these polling loops may never exit. Prevent
this by returning an error if a timeout is exceeded.

Signed-off-by: Eddie James <eajames@linux.ibm.com>
Link: https://lore.kernel.org/r/20220317211426.38940-1-eajames@linux.ibm.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-fsi.c