summaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorPeter Crosthwaite <peter.crosthwaite@xilinx.com>2013-06-03 17:17:44 +0100
committerPeter Maydell <peter.maydell@linaro.org>2013-06-03 17:17:44 +0100
commita66418f6f181ca6ee04e77896674253ff83db45e (patch)
tree63b3cfd8ad968a5d028d64decc1452a34dab8c1e /hw
parent4a5b6fa8d9bdeec71f4f92e8b7a31fc344ef512f (diff)
xilinx_spips: lqspi: Push more data to tx-fifo
Do 16 words per fifo flush. Increases performance and decreases debug verbosity. This data depth has no real hardware analogue, so just go with something that has reasonable performance. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Edgar E. Iglesias <edgar.iglesias@gmail.com> Message-id: 5621ee4621941d3639b5cacfdec26bd3148f31d5.1369117359.git.peter.crosthwaite@xilinx.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw')
-rw-r--r--hw/ssi/xilinx_spips.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/hw/ssi/xilinx_spips.c b/hw/ssi/xilinx_spips.c
index 665f471bb1..e975a876c6 100644
--- a/hw/ssi/xilinx_spips.c
+++ b/hw/ssi/xilinx_spips.c
@@ -608,11 +608,14 @@ lqspi_read(void *opaque, hwaddr addr, unsigned int size)
DB_PRINT_L(0, "starting QSPI data read\n");
- for (i = 0; i < LQSPI_CACHE_SIZE / 4; ++i) {
- tx_data_bytes(s, 0, 4);
+ while (cache_entry < LQSPI_CACHE_SIZE / 4) {
+ for (i = 0; i < 16; ++i) {
+ tx_data_bytes(s, 0, 4);
+ }
xilinx_spips_flush_txfifo(s);
- rx_data_bytes(s, &q->lqspi_buf[cache_entry], 4);
- cache_entry++;
+ for (i = 0; i < 16; ++i) {
+ rx_data_bytes(s, &q->lqspi_buf[cache_entry++], 4);
+ }
}
s->regs[R_LQSPI_STS] &= ~LQSPI_CFG_U_PAGE;