aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/dma
diff options
context:
space:
mode:
authorFrank Li <Frank.Li@nxp.com>2022-05-24 10:21:58 -0500
committerBjorn Helgaas <bhelgaas@google.com>2022-06-23 14:56:34 -0500
commitd6b03171f9fc8127b3a7adfd4e74ee5d4dae5d14 (patch)
treef0312c58ae1ca605751f44e9a3e789f79f07e626 /include/linux/dma
parentdmaengine: dw-edma: Fix eDMA Rd/Wr-channels and DMA-direction semantics (diff)
downloadlinux-dev-d6b03171f9fc8127b3a7adfd4e74ee5d4dae5d14.tar.xz
linux-dev-d6b03171f9fc8127b3a7adfd4e74ee5d4dae5d14.zip
dmaengine: dw-edma: Add support for chip-specific flags
Add a "flags" field to the "struct dw_edma_chip" so that the controller drivers can pass flags that are relevant to the platform. DW_EDMA_CHIP_LOCAL - Used by the controller drivers accessing eDMA locally. Local eDMA access doesn't require generating MSIs to the remote. Link: https://lore.kernel.org/r/20220524152159.2370739-8-Frank.Li@nxp.com Tested-by: Serge Semin <fancer.lancer@gmail.com> Tested-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org> Signed-off-by: Frank Li <Frank.Li@nxp.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Serge Semin <fancer.lancer@gmail.com> Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org> Acked-By: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'include/linux/dma')
-rw-r--r--include/linux/dma/edma.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/linux/dma/edma.h b/include/linux/dma/edma.h
index fdbbeda170a9..7d8062e9c544 100644
--- a/include/linux/dma/edma.h
+++ b/include/linux/dma/edma.h
@@ -34,11 +34,20 @@ enum dw_edma_map_format {
};
/**
+ * enum dw_edma_chip_flags - Flags specific to an eDMA chip
+ * @DW_EDMA_CHIP_LOCAL: eDMA is used locally by an endpoint
+ */
+enum dw_edma_chip_flags {
+ DW_EDMA_CHIP_LOCAL = BIT(0),
+};
+
+/**
* struct dw_edma_chip - representation of DesignWare eDMA controller hardware
* @dev: struct device of the eDMA controller
* @id: instance ID
* @nr_irqs: total number of DMA IRQs
* @ops DMA channel to IRQ number mapping
+ * @flags dw_edma_chip_flags
* @reg_base DMA register base address
* @ll_wr_cnt DMA write link list count
* @ll_rd_cnt DMA read link list count
@@ -55,6 +64,7 @@ struct dw_edma_chip {
int id;
int nr_irqs;
const struct dw_edma_core_ops *ops;
+ u32 flags;
void __iomem *reg_base;