Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1247306

[PATCH v6 06/10] DMA: dmaengine: expose max burst capability to clients

From Shawn Lin <shawn.lin@rock-chips.com>
Newsgroups linux.kernel
Subject [PATCH v6 06/10] DMA: dmaengine: expose max burst capability to clients
Date 2015-10-15 03:40 +0200
Message-ID <qjFGq-8dL-37@gated-at.bofh.it> (permalink)
References <qjFGp-8dL-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


This patch add max_burst to dma_get_slave_caps for clients
to get the burst capability of slave dma controller.

Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>

---

Changes in v6:
- remove expose quirk and add dma max_burst caps for clients

Changes in v5: None
Changes in v4: None
Changes in v3: None
Changes in v2: None
Changes in v1: None

 drivers/dma/dmaengine.c   | 1 +
 include/linux/dmaengine.h | 4 ++++
 2 files changed, 5 insertions(+)

diff --git a/drivers/dma/dmaengine.c b/drivers/dma/dmaengine.c
index 3ecec14..1ccf64b 100644
--- a/drivers/dma/dmaengine.c
+++ b/drivers/dma/dmaengine.c
@@ -492,6 +492,7 @@ int dma_get_slave_caps(struct dma_chan *chan, struct dma_slave_caps *caps)
 	caps->src_addr_widths = device->src_addr_widths;
 	caps->dst_addr_widths = device->dst_addr_widths;
 	caps->directions = device->directions;
+	caps->max_burst = device->max_burst;
 	caps->residue_granularity = device->residue_granularity;
 
 	/*
diff --git a/include/linux/dmaengine.h b/include/linux/dmaengine.h
index 7ea9184..b6bc79e 100644
--- a/include/linux/dmaengine.h
+++ b/include/linux/dmaengine.h
@@ -401,6 +401,7 @@ enum dma_residue_granularity {
  * 	since the enum dma_transfer_direction is not defined as bits for each
  * 	type of direction, the dma controller should fill (1 << <TYPE>) and same
  * 	should be checked by controller as well
+ * @max_burst: max burst capability per-transfer
  * @cmd_pause: true, if pause and thereby resume is supported
  * @cmd_terminate: true, if terminate cmd is supported
  * @residue_granularity: granularity of the reported transfer residue
@@ -411,6 +412,7 @@ struct dma_slave_caps {
 	u32 src_addr_widths;
 	u32 dst_addr_widths;
 	u32 directions;
+	u32 max_burst;
 	bool cmd_pause;
 	bool cmd_terminate;
 	enum dma_residue_granularity residue_granularity;
@@ -627,6 +629,7 @@ enum dmaengine_alignment {
  * 	the enum dma_transfer_direction is not defined as bits for
  * 	each type of direction, the dma controller should fill (1 <<
  * 	<TYPE>) and same should be checked by controller as well
+ * @max_burst: max burst capability per-transfer
  * @residue_granularity: granularity of the transfer residue reported
  *	by tx_status
  * @device_alloc_chan_resources: allocate resources and return the
@@ -680,6 +683,7 @@ struct dma_device {
 	u32 src_addr_widths;
 	u32 dst_addr_widths;
 	u32 directions;
+	u32 max_burst;
 	enum dma_residue_granularity residue_granularity;
 
 	int (*device_alloc_chan_resources)(struct dma_chan *chan);
-- 
2.3.7


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v6 0/10] Fix broken DMAFLUSHP on Rockchips platform Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 03:40 +0200
  [PATCH v6 04/10] ARM: dts: Add arm,pl330-broken-no-flushp quirk for rk3288 platform Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 03:40 +0200
  [PATCH v6 01/10] DMA: pl330: support burst mode for dev-to-mem and mem-to-dev transmit Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 03:40 +0200
    Re: [PATCH v6 01/10] DMA: pl330: support burst mode for dev-to-mem  and mem-to-dev transmit Vinod Koul <vinod.koul@intel.com> - 2015-10-15 06:10 +0200
      Re: [PATCH v6 01/10] DMA: pl330: support burst mode for dev-to-mem  and mem-to-dev transmit Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 09:00 +0200
  [PATCH v6 02/10] Documentation: arm-pl330: add description of arm,pl330-broken-no-flushp Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 03:40 +0200
  [PATCH v6 05/10] ARM: dts: Add arm,pl330-broken-no-flushp quirk for rk3xxx platform Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 03:40 +0200
  [PATCH v6 10/10] ASoC: rockchip_i2s: modify DMA max burst to 1 Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 03:40 +0200
    Re: [PATCH v6 10/10] ASoC: rockchip_i2s: modify DMA max burst to  1 Lars-Peter Clausen <lars@metafoo.de> - 2015-10-15 11:00 +0200
      Re: [PATCH v6 10/10] ASoC: rockchip_i2s: modify DMA max burst to 1 Jianqun Xu <jay.xu@rock-chips.com> - 2015-10-15 12:50 +0200
  [PATCH v6 07/10] DMA: pl330: add max burst for dmaengine Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 03:40 +0200
  [PATCH v6 03/10] DMA: pl330: add quirk for broken no flushp Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 03:40 +0200
  [PATCH v6 06/10] DMA: dmaengine: expose max burst capability to clients Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 03:40 +0200
  [PATCH v6 08/10] spi: rockchip: modify DMA max burst to 1 Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 04:00 +0200
  [PATCH v6 09/10] snd: dmaengine-pcm: add snd_dmaengine_pcm_get_caps interface Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 04:00 +0200
    Re: [alsa-devel] [PATCH v6 09/10] snd: dmaengine-pcm: add  snd_dmaengine_pcm_get_caps interface kbuild test robot <lkp@intel.com> - 2015-10-15 05:10 +0200
    Re: [PATCH v6 09/10] snd: dmaengine-pcm: add  snd_dmaengine_pcm_get_caps interface Vinod Koul <vinod.koul@intel.com> - 2015-10-15 06:10 +0200
      Re: [PATCH v6 09/10] snd: dmaengine-pcm: add  snd_dmaengine_pcm_get_caps interface Shawn Lin <shawn.lin@rock-chips.com> - 2015-10-15 09:00 +0200

csiph-web