From: Marek Vasut <marex@denx.de>
To: dmaengine@vger.kernel.org
Cc: Marek Vasut <marex@denx.de>,
Akinobu Mita <akinobu.mita@gmail.com>,
Kedareswara rao Appana <appana.durga.rao@xilinx.com>,
Michal Simek <monstr@monstr.eu>,
Vinod Koul <vinod.koul@intel.com>
Subject: [PATCH] dmaengine: xilinx: Add empty device_config function
Date: Sat, 13 Jun 2020 16:58:42 +0200 [thread overview]
Message-ID: <20200613145842.113671-1-marex@denx.de> (raw)
Various DMA users call the dmaengine_slave_config() and expect it to
succeed, but that can only succeed if .device_config is implemented.
Add empty device_config function rather than patching all the places
which use dmaengine_slave_config().
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Akinobu Mita <akinobu.mita@gmail.com>
Cc: Kedareswara rao Appana <appana.durga.rao@xilinx.com>
Cc: Michal Simek <monstr@monstr.eu>
Cc: Vinod Koul <vinod.koul@intel.com>
---
drivers/dma/xilinx/xilinx_dma.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/drivers/dma/xilinx/xilinx_dma.c b/drivers/dma/xilinx/xilinx_dma.c
index 5429497d3560b..058150ff9e0d9 100644
--- a/drivers/dma/xilinx/xilinx_dma.c
+++ b/drivers/dma/xilinx/xilinx_dma.c
@@ -1637,6 +1637,17 @@ static void xilinx_dma_issue_pending(struct dma_chan *dchan)
spin_unlock_irqrestore(&chan->lock, flags);
}
+/**
+ * xilinx_dma_issue_pending - Configure the DMA channel
+ * @dchan: DMA channel
+ * @config: channel configuration
+ */
+static int xilinx_dma_device_config(struct dma_chan *dchan,
+ struct dma_slave_config *config)
+{
+ return 0;
+}
+
/**
* xilinx_dma_complete_descriptor - Mark the active descriptor as complete
* @chan : xilinx DMA channel
@@ -3076,6 +3087,7 @@ static int xilinx_dma_probe(struct platform_device *pdev)
xdev->common.device_terminate_all = xilinx_dma_terminate_all;
xdev->common.device_tx_status = xilinx_dma_tx_status;
xdev->common.device_issue_pending = xilinx_dma_issue_pending;
+ xdev->common.device_config = xilinx_dma_device_config;
if (xdev->dma_config->dmatype == XDMA_TYPE_AXIDMA) {
dma_cap_set(DMA_CYCLIC, xdev->common.cap_mask);
xdev->common.device_prep_slave_sg = xilinx_dma_prep_slave_sg;
--
2.26.2
next reply other threads:[~2020-06-13 14:59 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-13 14:58 Marek Vasut [this message]
2020-06-14 15:38 ` [PATCH] dmaengine: xilinx: Add empty device_config function Vinod Koul
2021-07-16 18:22 Marek Vasut
2021-07-17 11:36 ` Vinod Koul
2021-07-17 12:01 ` Marek Vasut
2021-07-17 14:34 ` Vinod Koul
2021-07-17 14:48 ` Marek Vasut
2021-07-28 11:07 ` Vinod Koul
2021-07-18 19:38 ` kernel test robot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200613145842.113671-1-marex@denx.de \
--to=marex@denx.de \
--cc=akinobu.mita@gmail.com \
--cc=appana.durga.rao@xilinx.com \
--cc=dmaengine@vger.kernel.org \
--cc=monstr@monstr.eu \
--cc=vinod.koul@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).