summaryrefslogtreecommitdiff
path: root/include/linux/dma
diff options
context:
space:
mode:
authorEric Long <eric.long@spreadtrum.com>2018-05-23 12:31:11 +0300
committerVinod Koul <vkoul@kernel.org>2018-05-29 07:45:33 +0300
commitca1b7d3daff43a269fb7a0479055ac5b741638d8 (patch)
tree48bf81c31fea321429c692e321d26e41449e978c /include/linux/dma
parent32fa20139ebc1521954b9ccb411e5772411efc87 (diff)
downloadlinux-ca1b7d3daff43a269fb7a0479055ac5b741638d8.tar.xz
dmaengine: sprd: Add Spreadtrum DMA configuration
This patch adds the 'device_config' and 'device_prep_slave_sg' interfaces for users to configure DMA, as well as adding one 'struct sprd_dma_config' structure to save Spreadtrum DMA configuration for each DMA channel. Signed-off-by: Eric Long <eric.long@spreadtrum.com> Signed-off-by: Baolin Wang <baolin.wang@linaro.org> Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'include/linux/dma')
-rw-r--r--include/linux/dma/sprd-dma.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/dma/sprd-dma.h b/include/linux/dma/sprd-dma.h
index c545162e725b..b0115e340fbc 100644
--- a/include/linux/dma/sprd-dma.h
+++ b/include/linux/dma/sprd-dma.h
@@ -3,6 +3,10 @@
#ifndef _SPRD_DMA_H_
#define _SPRD_DMA_H_
+#define SPRD_DMA_REQ_SHIFT 16
+#define SPRD_DMA_FLAGS(req_mode, int_type) \
+ ((req_mode) << SPRD_DMA_REQ_SHIFT | (int_type))
+
/*
* enum sprd_dma_req_mode: define the DMA request mode
* @SPRD_DMA_FRAG_REQ: fragment request mode