summaryrefslogtreecommitdiffstats
path: root/dma
diff options
context:
space:
mode:
Diffstat (limited to 'dma')
-rw-r--r--dma/nwl_engine.c4
-rw-r--r--dma/nwl_engine_buffers.h6
2 files changed, 5 insertions, 5 deletions
diff --git a/dma/nwl_engine.c b/dma/nwl_engine.c
index c3dea49..b098943 100644
--- a/dma/nwl_engine.c
+++ b/dma/nwl_engine.c
@@ -124,7 +124,7 @@ int dma_nwl_start_engine(nwl_dma_t *ctx, pcilib_dma_engine_t dma) {
dma_nwl_acknowledge_irq((pcilib_dma_context_t*)ctx, PCILIB_DMA_IRQ, dma);
- ring_pa = pcilib_kmem_get_pa(ctx->dmactx.pcilib, ectx->ring);
+ ring_pa = pcilib_kmem_get_ba(ctx->dmactx.pcilib, ectx->ring);
nwl_write_register(ring_pa, ctx, ectx->base_addr, REG_DMA_ENG_NEXT_BD);
nwl_write_register(ring_pa, ctx, ectx->base_addr, REG_SW_NEXT_BD);
@@ -188,7 +188,7 @@ int dma_nwl_stop_engine(nwl_dma_t *ctx, pcilib_dma_engine_t dma) {
} while ((val & (DMA_ENG_RUNNING))&&(((cur.tv_sec - start.tv_sec)*1000000 + (cur.tv_usec - start.tv_usec)) < PCILIB_NWL_REGISTER_TIMEOUT));
if (ectx->ring) {
- ring_pa = pcilib_kmem_get_pa(ctx->dmactx.pcilib, ectx->ring);
+ ring_pa = pcilib_kmem_get_ba(ctx->dmactx.pcilib, ectx->ring);
nwl_write_register(ring_pa, ctx, ectx->base_addr, REG_DMA_ENG_NEXT_BD);
nwl_write_register(ring_pa, ctx, ectx->base_addr, REG_SW_NEXT_BD);
}
diff --git a/dma/nwl_engine_buffers.h b/dma/nwl_engine_buffers.h
index ef1c74f..0cc5343 100644
--- a/dma/nwl_engine_buffers.h
+++ b/dma/nwl_engine_buffers.h
@@ -121,7 +121,7 @@ static int dma_nwl_allocate_engine_buffers(nwl_dma_t *ctx, pcilib_nwl_engine_con
unsigned char *data = (unsigned char*)pcilib_kmem_get_ua(ctx->dmactx.pcilib, ring);
- uint32_t ring_pa = pcilib_kmem_get_pa(ctx->dmactx.pcilib, ring);
+ uint32_t ring_pa = pcilib_kmem_get_ba(ctx->dmactx.pcilib, ring);
if (preserve) {
if (ectx->desc->direction == PCILIB_DMA_FROM_DEVICE) err = dma_nwl_compute_read_c2s_pointers(ctx, ectx, data, ring_pa);
@@ -251,7 +251,7 @@ static int dma_nwl_push_buffer(nwl_dma_t *ctx, pcilib_nwl_engine_context_t *ectx
uint32_t val;
unsigned char *ring = pcilib_kmem_get_ua(ctx->dmactx.pcilib, ectx->ring);
- uint32_t ring_pa = pcilib_kmem_get_pa(ctx->dmactx.pcilib, ectx->ring);
+ uint32_t ring_pa = pcilib_kmem_get_ba(ctx->dmactx.pcilib, ectx->ring);
ring += ectx->head * PCILIB_NWL_DMA_DESCRIPTOR_SIZE;
@@ -338,7 +338,7 @@ static int dma_nwl_return_buffer(nwl_dma_t *ctx, pcilib_nwl_engine_context_t *ec
uint32_t val;
unsigned char *ring = pcilib_kmem_get_ua(ctx->dmactx.pcilib, ectx->ring);
- uint32_t ring_pa = pcilib_kmem_get_pa(ctx->dmactx.pcilib, ectx->ring);
+ uint32_t ring_pa = pcilib_kmem_get_ba(ctx->dmactx.pcilib, ectx->ring);
size_t bufsz = pcilib_kmem_get_block_size(ctx->dmactx.pcilib, ectx->pages, ectx->tail);
ring += ectx->tail * PCILIB_NWL_DMA_DESCRIPTOR_SIZE;