]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit - drivers/spi/spi-ti-qspi.c
spi: spi-ti-qspi: switch to polling mode for better r/w performance
authorVignesh R <vigneshr@ti.com>
Tue, 13 Oct 2015 10:21:05 +0000 (15:51 +0530)
committerMark Brown <broonie@kernel.org>
Fri, 16 Oct 2015 18:08:06 +0000 (19:08 +0100)
commit57c2ecd9bf971946ea0c6ae90a79c90a22159c73
treea27454ff77f3d5c5e8747d54a5f132ccb7191b47
parent6ff33f3902c3b1c5d0db6b1e2c70b6d76fba357f
spi: spi-ti-qspi: switch to polling mode for better r/w performance

Currently word completion interrupt is fired for transfer of every
word(8bit to 128bit in size). This adds a lot of overhead, and decreases
r/w throughput. It hardly takes 3us(@48MHz) for 128bit r/w to complete,
hence its better to poll on word complete bit to be set in
QSPI_SPI_STATUS_REG instead of using interrupts.
This increases the throughput by 30% in both read and write case.

So, switch to polling mode instead of interrupts to determine completion
of word transfer.

Signed-off-by: Vignesh R <vigneshr@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-ti-qspi.c