[<prev] [next>] [day] [month] [year] [list]
Message-id: <000001ce10d3$354dd440$9fe97cc0$%kim@samsung.com>
Date: Fri, 22 Feb 2013 17:04:15 +0900
From: Boojin Kim <boojin.kim@...sung.com>
To: linux-kernel@...r.kernel.org, linux-samsung-soc@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org,
spi-devel-general@...ts.sourceforge.net,
alsa-devel@...a-project.org
Cc: 'Vinod Koul' <vinod.koul@...el.com>, 'Dan Williams' <djbw@...com>,
'Russell King' <linux@....linux.org.uk>,
'Kukjin Kim' <kgene.kim@...sung.com>,
'Grant Likely' <grant.likely@...retlab.ca>,
'Mark Brown' <broonie@...nsource.wolfsonmicro.com>,
'Rob Herring' <rob.herring@...xeda.com>,
'Sangbeom Kim' <sbkim73@...sung.com>,
'Boojin Kim' <boojin.kim@...sung.com>
Subject: [PATCH v2 1/4] DMA: pl330: support burst mode for dev-to-mem and
mem-to-dev transmit
This patch adds to support burst mode for dev-to-mem and mem-to-dev transmit
Change-Id: I9723e49383416773699cf7735168177c8d036f30
Signed-off-by: Boojin Kim <boojin.kim@...sung.com>
---
drivers/dma/pl330.c | 12 +++++++-----
1 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
index 80680ee..c67f037 100644
--- a/drivers/dma/pl330.c
+++ b/drivers/dma/pl330.c
@@ -1271,10 +1271,11 @@ static inline int _ldst_devtomem(unsigned dry_run, u8 buf[],
const struct _xfer_spec *pxs, int cyc)
{
int off = 0;
+ enum pl330_cond cond = (pxs->r->cfg->brst_len == 1) ? SINGLE : BURST;
while (cyc--) {
- off += _emit_WFP(dry_run, &buf[off], SINGLE, pxs->r->peri);
- off += _emit_LDP(dry_run, &buf[off], SINGLE, pxs->r->peri);
+ off += _emit_WFP(dry_run, &buf[off], cond, pxs->r->peri);
+ off += _emit_LDP(dry_run, &buf[off], cond, pxs->r->peri);
off += _emit_ST(dry_run, &buf[off], ALWAYS);
off += _emit_FLUSHP(dry_run, &buf[off], pxs->r->peri);
}
@@ -1286,11 +1287,12 @@ static inline int _ldst_memtodev(unsigned dry_run, u8 buf[],
const struct _xfer_spec *pxs, int cyc)
{
int off = 0;
+ enum pl330_cond cond = (pxs->r->cfg->brst_len == 1) ? SINGLE : BURST;
while (cyc--) {
- off += _emit_WFP(dry_run, &buf[off], SINGLE, pxs->r->peri);
+ off += _emit_WFP(dry_run, &buf[off], cond, pxs->r->peri);
off += _emit_LD(dry_run, &buf[off], ALWAYS);
- off += _emit_STP(dry_run, &buf[off], SINGLE, pxs->r->peri);
+ off += _emit_STP(dry_run, &buf[off], cond, pxs->r->peri);
off += _emit_FLUSHP(dry_run, &buf[off], pxs->r->peri);
}
@@ -2835,7 +2837,7 @@ pl330_prep_slave_sg(struct dma_chan *chan, struct scatterlist *sgl,
}
desc->rqcfg.brst_size = pch->burst_sz;
- desc->rqcfg.brst_len = 1;
+ desc->rqcfg.brst_len = pch->burst_len;
}
/* Return the last desc in the chain */
--
1.7.5.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists