mirror of
https://github.com/torvalds/linux.git
synced 2026-12-04 12:24:18 +00:00
spi: a3700: Return correct value on timeout detection
When waiting for transfer completion, a3700_spi_wait_completion returns a boolean indicating if a timeout occurred. The function was returning 'true' everytime, failing to detect any timeout. This patch makes it return 'false' when a timeout is reached. Signed-off-by: Maxime Chevallier <[email protected]> Signed-off-by: Mark Brown <[email protected]> Cc: [email protected]
This commit is contained in:
committed by
Mark Brown
parent
6fd6fd68c9
commit
5a866ec001
@@ -387,7 +387,8 @@ static bool a3700_spi_wait_completion(struct spi_device *spi)
|
||||
|
||||
spireg_write(a3700_spi, A3700_SPI_INT_MASK_REG, 0);
|
||||
|
||||
return true;
|
||||
/* Timeout was reached */
|
||||
return false;
|
||||
}
|
||||
|
||||
static bool a3700_spi_transfer_wait(struct spi_device *spi,
|
||||
|
||||
Reference in New Issue
Block a user