spi: imx: dynamic burst length adjust for PIO mode
authorjiada wang <jiada_wang@mentor.com>
Thu, 10 Aug 2017 04:50:08 +0000 (13:50 +0900)
committerMark Brown <broonie@kernel.org>
Thu, 17 Aug 2017 14:27:13 +0000 (15:27 +0100)
commit1673c81d9435bcf758da6ccaa291513e34c1cb82
tree5ba1073ddd4c112752292a06a26ef0b440b775f8
parentab2f357223eb8fa6acc96bfa002053b6f1f92341
spi: imx: dynamic burst length adjust for PIO mode

previously burst length (BURST_LENGTH) is always set to equal
to bits_per_word, causes a 10us gap between each word in
transfer, which significantly affects performance.

This patch uses 32 bits transfer to simulate lower bits transfer,
and adjusts burst length runtimely to use biggeest burst length
as possible to reduce the gaps in transfer for PIO mode.

Signed-off-by: Jiada Wang <jiada_wang@mentor.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-imx.c