diff options
author | David Lechner <dlechner@baylibre.com> | 2024-06-20 11:43:58 -0500 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2024-06-24 13:38:17 +0100 |
commit | 40b3d0838a1ff242e61f341e49226074bbdd319f (patch) | |
tree | 69b313c8de485ce3169ddd3905e30513919dc5dd /drivers/spi/spi-davinci.c | |
parent | ce1dac560a74220f2e53845ec0723b562288aed4 (diff) |
spi: axi-spi-engine: fix sleep calculation
The sleep calculation was not taking into account increased delay when
the SPI device is not running at the maximum SCLK frequency.
Rounding down when one SCLK tick was the same as the instruction
execution time was fine, but it rounds down too much when SCLK is
slower. This changes the rounding to round up instead while still
taking into account the instruction execution time so that small
delays remain accurate.
Fixes: be9070bcf670 ("spi: axi-spi-engine: fix sleep ticks calculation")
Signed-off-by: David Lechner <dlechner@baylibre.com>
Link: https://patch.msgid.link/20240620-spi-axi-spi-engine-fix-sleep-time-v1-1-b20b527924a0@baylibre.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/spi/spi-davinci.c')
0 files changed, 0 insertions, 0 deletions