diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2015-08-31 17:09:23 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2015-11-30 08:22:31 +0100 |
commit | 412a0e175069102761e85d4518c50dfb9b03519b (patch) | |
tree | 75850365d2cbc8c8c7b43021500614818dd141b2 /include/spi/imx-spi.h | |
parent | 7da99e58bdf6ccf421dacd83e5c9d1231c12507b (diff) | |
download | barebox-412a0e175069102761e85d4518c50dfb9b03519b.tar.gz barebox-412a0e175069102761e85d4518c50dfb9b03519b.tar.xz |
spi: i.MX: optimize transfers for ECSPI v2.3
Instead of writing one word to the txfifo and then wait until
one is received in the rxfifo we can write while the txfifos
are not full and read as long the rxfifos contain data. This
makes transfers for the m25p80 driver around 7 times faster
here.
Unlike the last version this time we only optimize the common
case with 8 bits per word and SPI_LSB_FIRST cleared. The other
cases would require more bit shuffling of the data.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/spi/imx-spi.h')
-rw-r--r-- | include/spi/imx-spi.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/spi/imx-spi.h b/include/spi/imx-spi.h index 5c89634770..221c66502f 100644 --- a/include/spi/imx-spi.h +++ b/include/spi/imx-spi.h @@ -79,6 +79,7 @@ #define CSPI_2_3_INT_RREN (1 << 3) #define CSPI_2_3_STAT 0x18 -#define CSPI_2_3_STAT_RR (1 << 3) +#define CSPI_2_3_STAT_TF (1 << 2) +#define CSPI_2_3_STAT_RR (1 << 3) #endif /* __SPI_IMX_SPI_H */ |