All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] dma: rcar-hpbdma: add dma_dev->directions
@ 2015-01-06  8:10 Kuninori Morimoto
  2015-01-07 14:22 ` Lars-Peter Clausen
  0 siblings, 1 reply; 2+ messages in thread
From: Kuninori Morimoto @ 2015-01-06  8:10 UTC (permalink / raw)
  To: linux-sh

From: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

ecc19d17868be9c9f8f00ed928791533c420f3e0
(dmaengine: Add a warning for drivers not using the generic slave
caps retrieval) added WARN() for DMA_SLAVE.
Kernel will shows WARNING without this patch.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 drivers/dma/sh/rcar-hpbdma.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/dma/sh/rcar-hpbdma.c b/drivers/dma/sh/rcar-hpbdma.c
index 20a6f6f..0a1fdbd 100644
--- a/drivers/dma/sh/rcar-hpbdma.c
+++ b/drivers/dma/sh/rcar-hpbdma.c
@@ -595,6 +595,7 @@ static int hpb_dmae_probe(struct platform_device *pdev)
 
 	dma_cap_set(DMA_MEMCPY, dma_dev->cap_mask);
 	dma_cap_set(DMA_SLAVE, dma_dev->cap_mask);
+	dma_dev->directions = BIT(DMA_MEM_TO_DEV) | BIT(DMA_DEV_TO_MEM);
 
 	hpbdev->shdma_dev.ops = &hpb_dmae_ops;
 	hpbdev->shdma_dev.desc_size = sizeof(struct hpb_desc);
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] dma: rcar-hpbdma: add dma_dev->directions
  2015-01-06  8:10 [PATCH] dma: rcar-hpbdma: add dma_dev->directions Kuninori Morimoto
@ 2015-01-07 14:22 ` Lars-Peter Clausen
  0 siblings, 0 replies; 2+ messages in thread
From: Lars-Peter Clausen @ 2015-01-07 14:22 UTC (permalink / raw)
  To: linux-sh

On 01/06/2015 09:10 AM, Kuninori Morimoto wrote:
[...]
>   	dma_cap_set(DMA_SLAVE, dma_dev->cap_mask);
> +	dma_dev->directions = BIT(DMA_MEM_TO_DEV) | BIT(DMA_DEV_TO_MEM);

You should also set the other capabilities: src_addr_widths, dst_addr_widths 
and residue_granularity.

- Lars


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-01-07 14:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-06  8:10 [PATCH] dma: rcar-hpbdma: add dma_dev->directions Kuninori Morimoto
2015-01-07 14:22 ` Lars-Peter Clausen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.