All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] dmaengine: idxd: set DMA channel to be private
@ 2021-01-15 21:53 Dave Jiang
  2021-01-17  6:52 ` Vinod Koul
  0 siblings, 1 reply; 2+ messages in thread
From: Dave Jiang @ 2021-01-15 21:53 UTC (permalink / raw
  To: vkoul; +Cc: Srinijia Kambham, Srinijia Kambham, dmaengine

Add DMA_PRIVATE attribute flag to idxd DMA channels. The dedicated WQs are
expected to be used by a single client and not shared. While doing NTB
testing this mistake was discovered, which prevented ntb_transport from
requesting DSA wqs as DMA channels via dma_request_channel().

Reported-by: Srinijia Kambham <srinija.kambham@intel.com>
Signed-off-by: Dave Jiang <dave.jiang@intel.com>
Tested-by: Srinijia Kambham <srinija.kambham@intel.com>
Fixes: 8f47d1a5e545 ("dmaengine: idxd: connect idxd to dmaengine subsystem")
---
 drivers/dma/idxd/dma.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/dma/idxd/dma.c b/drivers/dma/idxd/dma.c
index 8ed2773d8285..90d19d06783a 100644
--- a/drivers/dma/idxd/dma.c
+++ b/drivers/dma/idxd/dma.c
@@ -165,6 +165,7 @@ int idxd_register_dma_device(struct idxd_device *idxd)
 	INIT_LIST_HEAD(&dma->channels);
 	dma->dev = &idxd->pdev->dev;
 
+	dma_cap_set(DMA_PRIVATE, dma->cap_mask);
 	dma_cap_set(DMA_COMPLETION_NO_ORDER, dma->cap_mask);
 	dma->device_release = idxd_dma_release;
 



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

* Re: [PATCH] dmaengine: idxd: set DMA channel to be private
  2021-01-15 21:53 [PATCH] dmaengine: idxd: set DMA channel to be private Dave Jiang
@ 2021-01-17  6:52 ` Vinod Koul
  0 siblings, 0 replies; 2+ messages in thread
From: Vinod Koul @ 2021-01-17  6:52 UTC (permalink / raw
  To: Dave Jiang; +Cc: Srinijia Kambham, dmaengine

On 15-01-21, 14:53, Dave Jiang wrote:
> Add DMA_PRIVATE attribute flag to idxd DMA channels. The dedicated WQs are
> expected to be used by a single client and not shared. While doing NTB
> testing this mistake was discovered, which prevented ntb_transport from
> requesting DSA wqs as DMA channels via dma_request_channel().

Applied, thanks

-- 
~Vinod

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

end of thread, other threads:[~2021-01-17  6:52 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-01-15 21:53 [PATCH] dmaengine: idxd: set DMA channel to be private Dave Jiang
2021-01-17  6:52 ` Vinod Koul

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.