Received: from eggs.gnu.org ([2001:4830:134:3::10]:44450) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UjXlp-00029y-Sg for qemu-devel@nongnu.org; Mon, 03 Jun 2013 12:38:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UjXlk-0000c3-6L for qemu-devel@nongnu.org; Mon, 03 Jun 2013 12:38:09 -0400 Received: from 1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.d.1.0.0.b.8.0.1.0.0.2.ip6.arpa ([2001:8b0:1d0::1]:57802 helo=mnementh.archaic.org.uk) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UjXeO-0006Zk-KE for qemu-devel@nongnu.org; Mon, 03 Jun 2013 12:30:28 -0400 From: Peter Maydell Date: Mon, 3 Jun 2013 17:30:11 +0100 Message-Id: <1370277021-26129-15-git-send-email-peter.maydell@linaro.org> In-Reply-To: <1370277021-26129-1-git-send-email-peter.maydell@linaro.org> References: <1370277021-26129-1-git-send-email-peter.maydell@linaro.org> Subject: [Qemu-devel] [PULL 14/24] xilinx_spips: lqspi: Push more data to tx-fifo List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: qemu-devel@nongnu.org, Paul Brook From: Peter Crosthwaite 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 Reviewed-by: Peter Maydell Reviewed-by: Edgar E. Iglesias Message-id: 5621ee4621941d3639b5cacfdec26bd3148f31d5.1369117359.git.peter.crosthwaite@xilinx.com Signed-off-by: Peter Maydell --- hw/ssi/xilinx_spips.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/hw/ssi/xilinx_spips.c b/hw/ssi/xilinx_spips.c index 665f471..e975a87 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; -- 1.7.9.5