diff mbox series

[v2,3/8] dt-bindings: sdhci-omap: Add properties for using external dma

Message ID 20190215192033.24203-4-faiz_abbas@ti.com (mailing list archive)
State New, archived
Headers show
Series Port am335 and am437 devices to sdhci-omap | expand

Commit Message

Faiz Abbas Feb. 15, 2019, 7:20 p.m. UTC
From: Chunyan Zhang <zhang.chunyan@linaro.org>

sdhci-omap can support both external dma controller via dmaengine
framework as well as ADMA which standard SD host controller
provides.

Signed-off-by: Chunyan Zhang <zhang.chunyan@linaro.org>
Signed-off-by: Faiz Abbas <faiz_abbas@ti.com>
---
 Documentation/devicetree/bindings/mmc/sdhci-omap.txt | 7 +++++++
 1 file changed, 7 insertions(+)

Comments

Tony Lindgren Feb. 15, 2019, 8:07 p.m. UTC | #1
* Faiz Abbas <faiz_abbas@ti.com> [190215 19:18]:
> From: Chunyan Zhang <zhang.chunyan@linaro.org>
> 
> sdhci-omap can support both external dma controller via dmaengine
> framework as well as ADMA which standard SD host controller
> provides.

Care to describe here also how to configure things for ADMA and
instead of DMA? Just leave out dmas property?

Regards,

Tony
Faiz Abbas Feb. 18, 2019, 1:41 p.m. UTC | #2
Hi Tony,

On 16/02/19 1:37 AM, Tony Lindgren wrote:
> * Faiz Abbas <faiz_abbas@ti.com> [190215 19:18]:
>> From: Chunyan Zhang <zhang.chunyan@linaro.org>
>>
>> sdhci-omap can support both external dma controller via dmaengine
>> framework as well as ADMA which standard SD host controller
>> provides.
> 
> Care to describe here also how to configure things for ADMA and
> instead of DMA? Just leave out dmas property?
> 

That's correct. If dmas property is populated, then use external DMA.
Otherwise use ADMA/SDMA depending on what you read from the CAPS register.

Thanks,
Faiz
Tony Lindgren Feb. 18, 2019, 4:20 p.m. UTC | #3
* Faiz Abbas <faiz_abbas@ti.com> [190218 13:38]:
> Hi Tony,
> 
> On 16/02/19 1:37 AM, Tony Lindgren wrote:
> > * Faiz Abbas <faiz_abbas@ti.com> [190215 19:18]:
> >> From: Chunyan Zhang <zhang.chunyan@linaro.org>
> >>
> >> sdhci-omap can support both external dma controller via dmaengine
> >> framework as well as ADMA which standard SD host controller
> >> provides.
> > 
> > Care to describe here also how to configure things for ADMA and
> > instead of DMA? Just leave out dmas property?
> >
> That's correct. If dmas property is populated, then use external DMA.
> Otherwise use ADMA/SDMA depending on what you read from the CAPS register.

OK thanks.

Tony
Tony Lindgren Feb. 18, 2019, 4:28 p.m. UTC | #4
* Tony Lindgren <tony@atomide.com> [190218 16:20]:
> * Faiz Abbas <faiz_abbas@ti.com> [190218 13:38]:
> > Hi Tony,
> > 
> > On 16/02/19 1:37 AM, Tony Lindgren wrote:
> > > * Faiz Abbas <faiz_abbas@ti.com> [190215 19:18]:
> > >> From: Chunyan Zhang <zhang.chunyan@linaro.org>
> > >>
> > >> sdhci-omap can support both external dma controller via dmaengine
> > >> framework as well as ADMA which standard SD host controller
> > >> provides.
> > > 
> > > Care to describe here also how to configure things for ADMA and
> > > instead of DMA? Just leave out dmas property?
> > >
> > That's correct. If dmas property is populated, then use external DMA.
> > Otherwise use ADMA/SDMA depending on what you read from the CAPS register.
> 
> OK thanks.

So I guess the dma properties should be under optional
properties in the binding doc then.

Regards,

Tony
Rob Herring (Arm) Feb. 18, 2019, 8:12 p.m. UTC | #5
On Mon, Feb 18, 2019 at 07:11:32PM +0530, Faiz Abbas wrote:
> Hi Tony,
> 
> On 16/02/19 1:37 AM, Tony Lindgren wrote:
> > * Faiz Abbas <faiz_abbas@ti.com> [190215 19:18]:
> >> From: Chunyan Zhang <zhang.chunyan@linaro.org>
> >>
> >> sdhci-omap can support both external dma controller via dmaengine
> >> framework as well as ADMA which standard SD host controller
> >> provides.
> > 
> > Care to describe here also how to configure things for ADMA and
> > instead of DMA? Just leave out dmas property?
> > 
> 
> That's correct. If dmas property is populated, then use external DMA.
> Otherwise use ADMA/SDMA depending on what you read from the CAPS register.

Then the properties should be optional.

Rob
Faiz Abbas Feb. 19, 2019, 1:32 p.m. UTC | #6
Hi Rob,

On 19/02/19 1:42 AM, Rob Herring wrote:
> On Mon, Feb 18, 2019 at 07:11:32PM +0530, Faiz Abbas wrote:
>> Hi Tony,
>>
>> On 16/02/19 1:37 AM, Tony Lindgren wrote:
>>> * Faiz Abbas <faiz_abbas@ti.com> [190215 19:18]:
>>>> From: Chunyan Zhang <zhang.chunyan@linaro.org>
>>>>
>>>> sdhci-omap can support both external dma controller via dmaengine
>>>> framework as well as ADMA which standard SD host controller
>>>> provides.
>>>
>>> Care to describe here also how to configure things for ADMA and
>>> instead of DMA? Just leave out dmas property?
>>>
>>
>> That's correct. If dmas property is populated, then use external DMA.
>> Otherwise use ADMA/SDMA depending on what you read from the CAPS register.
> 
> Then the properties should be optional.
> 

Will move it to optional in v3.

Thanks,
Faiz
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/mmc/sdhci-omap.txt b/Documentation/devicetree/bindings/mmc/sdhci-omap.txt
index 72c4dec7e1db..4485dbceb373 100644
--- a/Documentation/devicetree/bindings/mmc/sdhci-omap.txt
+++ b/Documentation/devicetree/bindings/mmc/sdhci-omap.txt
@@ -14,6 +14,11 @@  Required properties:
 		 "ddr_1_8v-rev11", "ddr_1_8v" or "ddr_3_3v", "hs200_1_8v-rev11",
 		 "hs200_1_8v",
 - pinctrl-<n> : Pinctrl states as described in bindings/pinctrl/pinctrl-bindings.txt
+- dmas:		List of DMA specifiers with the controller specific format as described
+		in the generic DMA client binding. A tx and rx specifier is required.
+- dma-names:	List of DMA request names. These strings correspond 1:1 with the
+		DMA specifiers listed in dmas. The string naming is to be "tx"
+		and "rx" for TX and RX DMA requests, respectively.
 
 Example:
 	mmc1: mmc@4809c000 {
@@ -22,4 +27,6 @@  Example:
 		ti,hwmods = "mmc1";
 		bus-width = <4>;
 		vmmc-supply = <&vmmc>; /* phandle to regulator node */
+		dmas = <&sdma 61 &sdma 62>;
+		dma-names = "tx", "rx";
 	};