All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot
@ 2013-03-11  7:50 Sebastien Guiriec
  2013-03-11  7:50 ` [PATCH V2 1/2] ARM: dts: OMAP2+: Add SDMA Audio IPs bindings Sebastien Guiriec
                   ` (2 more replies)
  0 siblings, 3 replies; 17+ messages in thread
From: Sebastien Guiriec @ 2013-03-11  7:50 UTC (permalink / raw)
  To: Sebastien Guiriec, Peter Ujfalusi, Liam Girdwood, Mark Brown,
	Benoît Cousson, Jarkko Nikula, Tony Lindgren
  Cc: linux-omap, alsa-devel

This patch serie is converting OMAP Audio IPs in order to use OMAP sDMA DT
binding in case of DT boot on OMAP2+ platforms.

It is depending on the next patches:

[1] http://www.spinics.net/lists/arm-kernel/msg227836.html
[2] http://www.mail-archive.com/linux-omap@vger.kernel.org/msg84668.html

It has been tested on:
- OMAP5 (sEVM/panda)in DT boot (McPDM/DMIC).
- OMAP4 (SDP4430/Panda) in both DT/non DT boot (McPDM/DMIC)
- OMAP3 (Beagle XM) in both DT/non DT boot (McBSP)

Update since v1:
- Put DTS patch in first.
- Squash all OMAP IPs patch together.

Sebastien Guiriec (2):
  ARM: dts: OMAP2+: Add SDMA Audio IPs bindings
  ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding

 arch/arm/boot/dts/omap2420.dtsi |    6 ++++++
 arch/arm/boot/dts/omap2430.dtsi |   15 +++++++++++++++
 arch/arm/boot/dts/omap3.dtsi    |   15 +++++++++++++++
 arch/arm/boot/dts/omap4.dtsi    |   17 +++++++++++++++++
 arch/arm/boot/dts/omap5.dtsi    |   14 ++++++++++++++
 sound/soc/omap/mcbsp.c          |   26 ++++++++++++++++----------
 sound/soc/omap/omap-dmic.c      |   15 +++++++++------
 sound/soc/omap/omap-mcpdm.c     |   22 ++++++++++++++--------
 sound/soc/omap/omap-pcm.c       |   12 ++++++++++--
 sound/soc/omap/omap-pcm.h       |    1 +
 10 files changed, 117 insertions(+), 26 deletions(-)

-- 
1.7.10.4


^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH V2 1/2] ARM: dts: OMAP2+: Add SDMA Audio IPs bindings
  2013-03-11  7:50 [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot Sebastien Guiriec
@ 2013-03-11  7:50 ` Sebastien Guiriec
  2013-03-11 14:19   ` Peter Ujfalusi
  2013-03-11  7:50 ` [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding Sebastien Guiriec
  2013-03-15 14:27 ` [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot Benoit Cousson
  2 siblings, 1 reply; 17+ messages in thread
From: Sebastien Guiriec @ 2013-03-11  7:50 UTC (permalink / raw)
  To: Sebastien Guiriec, Peter Ujfalusi, Liam Girdwood, Mark Brown,
	Benoît Cousson, Jarkko Nikula, Tony Lindgren
  Cc: linux-omap, alsa-devel

Populate DMA client information for McBSP DMIC and McPDM periperhal on
OMAP2+ devices.

Signed-off-by: Sebastien Guiriec <s-guiriec@ti.com>
---
 arch/arm/boot/dts/omap2420.dtsi |    6 ++++++
 arch/arm/boot/dts/omap2430.dtsi |   15 +++++++++++++++
 arch/arm/boot/dts/omap3.dtsi    |   15 +++++++++++++++
 arch/arm/boot/dts/omap4.dtsi    |   17 +++++++++++++++++
 arch/arm/boot/dts/omap5.dtsi    |   14 ++++++++++++++
 5 files changed, 67 insertions(+)

diff --git a/arch/arm/boot/dts/omap2420.dtsi b/arch/arm/boot/dts/omap2420.dtsi
index af65609..45930f2 100644
--- a/arch/arm/boot/dts/omap2420.dtsi
+++ b/arch/arm/boot/dts/omap2420.dtsi
@@ -37,6 +37,9 @@
 				     <60>; /* RX interrupt */
 			interrupt-names = "tx", "rx";
 			ti,hwmods = "mcbsp1";
+			dmas = <&sdma 31>,
+			       <&sdma 32>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp2: mcbsp@48076000 {
@@ -47,6 +50,9 @@
 				     <63>; /* RX interrupt */
 			interrupt-names = "tx", "rx";
 			ti,hwmods = "mcbsp2";
+			dmas = <&sdma 33>,
+			       <&sdma 34>;
+			dma-names = "tx", "rx";
 		};
 
 		timer1: timer@48028000 {
diff --git a/arch/arm/boot/dts/omap2430.dtsi b/arch/arm/boot/dts/omap2430.dtsi
index c392445..cfe7ed9 100644
--- a/arch/arm/boot/dts/omap2430.dtsi
+++ b/arch/arm/boot/dts/omap2430.dtsi
@@ -40,6 +40,9 @@
 			interrupt-names = "common", "tx", "rx", "rx_overflow";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp1";
+			dmas = <&sdma 31>,
+			       <&sdma 32>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp2: mcbsp@48076000 {
@@ -52,6 +55,9 @@
 			interrupt-names = "common", "tx", "rx";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp2";
+			dmas = <&sdma 33>,
+			       <&sdma 34>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp3: mcbsp@4808c000 {
@@ -64,6 +70,9 @@
 			interrupt-names = "common", "tx", "rx";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp3";
+			dmas = <&sdma 17>,
+			       <&sdma 18>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp4: mcbsp@4808e000 {
@@ -76,6 +85,9 @@
 			interrupt-names = "common", "tx", "rx";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp4";
+			dmas = <&sdma 19>,
+			       <&sdma 20>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp5: mcbsp@48096000 {
@@ -88,6 +100,9 @@
 			interrupt-names = "common", "tx", "rx";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp5";
+			dmas = <&sdma 21>,
+			       <&sdma 22>;
+			dma-names = "tx", "rx";
 		};
 
 		timer1: timer@49018000 {
diff --git a/arch/arm/boot/dts/omap3.dtsi b/arch/arm/boot/dts/omap3.dtsi
index 4e7acb6..f901404 100644
--- a/arch/arm/boot/dts/omap3.dtsi
+++ b/arch/arm/boot/dts/omap3.dtsi
@@ -289,6 +289,9 @@
 			interrupt-names = "common", "tx", "rx";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp1";
+			dmas = <&sdma 31>,
+			       <&sdma 32>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp2: mcbsp@49022000 {
@@ -303,6 +306,9 @@
 			interrupt-names = "common", "tx", "rx", "sidetone";
 			ti,buffer-size = <1280>;
 			ti,hwmods = "mcbsp2", "mcbsp2_sidetone";
+			dmas = <&sdma 33>,
+			       <&sdma 34>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp3: mcbsp@49024000 {
@@ -317,6 +323,9 @@
 			interrupt-names = "common", "tx", "rx", "sidetone";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp3", "mcbsp3_sidetone";
+			dmas = <&sdma 17>,
+			       <&sdma 18>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp4: mcbsp@49026000 {
@@ -329,6 +338,9 @@
 			interrupt-names = "common", "tx", "rx";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp4";
+			dmas = <&sdma 19>,
+			       <&sdma 20>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp5: mcbsp@48096000 {
@@ -341,6 +353,9 @@
 			interrupt-names = "common", "tx", "rx";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp5";
+			dmas = <&sdma 21>,
+			       <&sdma 22>;
+			dma-names = "tx", "rx";
 		};
 
 		timer1: timer@48318000 {
diff --git a/arch/arm/boot/dts/omap4.dtsi b/arch/arm/boot/dts/omap4.dtsi
index 827f6f3..413c683 100644
--- a/arch/arm/boot/dts/omap4.dtsi
+++ b/arch/arm/boot/dts/omap4.dtsi
@@ -388,6 +388,9 @@
 			reg-names = "mpu", "dma";
 			interrupts = <0 112 0x4>;
 			ti,hwmods = "mcpdm";
+			dmas = <&sdma 65>,
+			       <&sdma 66>;
+			dma-names = "up_link", "dn_link";
 		};
 
 		dmic: dmic@4012e000 {
@@ -397,6 +400,8 @@
 			reg-names = "mpu", "dma";
 			interrupts = <0 114 0x4>;
 			ti,hwmods = "dmic";
+			dmas = <&sdma 67>;
+			dma-names = "up_link";
 		};
 
 		mcbsp1: mcbsp@40122000 {
@@ -408,6 +413,9 @@
 			interrupt-names = "common";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp1";
+			dmas = <&sdma 33>,
+			       <&sdma 34>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp2: mcbsp@40124000 {
@@ -419,6 +427,9 @@
 			interrupt-names = "common";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp2";
+			dmas = <&sdma 17>,
+			       <&sdma 18>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp3: mcbsp@40126000 {
@@ -430,6 +441,9 @@
 			interrupt-names = "common";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp3";
+			dmas = <&sdma 19>,
+			       <&sdma 20>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp4: mcbsp@48096000 {
@@ -440,6 +454,9 @@
 			interrupt-names = "common";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp4";
+			dmas = <&sdma 31>,
+			       <&sdma 32>;
+			dma-names = "tx", "rx";
 		};
 
 		keypad: keypad@4a31c000 {
diff --git a/arch/arm/boot/dts/omap5.dtsi b/arch/arm/boot/dts/omap5.dtsi
index 39b8d76..5aa6086 100644
--- a/arch/arm/boot/dts/omap5.dtsi
+++ b/arch/arm/boot/dts/omap5.dtsi
@@ -364,6 +364,9 @@
 			reg-names = "mpu", "dma";
 			interrupts = <0 112 0x4>;
 			ti,hwmods = "mcpdm";
+			dmas = <&sdma 65>,
+			       <&sdma 66>;
+			dma-names = "up_link", "dn_link";
 		};
 
 		dmic: dmic@4012e000 {
@@ -373,6 +376,8 @@
 			reg-names = "mpu", "dma";
 			interrupts = <0 114 0x4>;
 			ti,hwmods = "dmic";
+			dmas = <&sdma 67>;
+			dma-names = "up_link";
 		};
 
 		mcbsp1: mcbsp@40122000 {
@@ -384,6 +389,9 @@
 			interrupt-names = "common";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp1";
+			dmas = <&sdma 33>,
+			       <&sdma 34>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp2: mcbsp@40124000 {
@@ -395,6 +403,9 @@
 			interrupt-names = "common";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp2";
+			dmas = <&sdma 17>,
+			       <&sdma 18>;
+			dma-names = "tx", "rx";
 		};
 
 		mcbsp3: mcbsp@40126000 {
@@ -406,6 +417,9 @@
 			interrupt-names = "common";
 			ti,buffer-size = <128>;
 			ti,hwmods = "mcbsp3";
+			dmas = <&sdma 19>,
+			       <&sdma 20>;
+			dma-names = "tx", "rx";
 		};
 
 		timer1: timer@4ae18000 {
-- 
1.7.10.4


^ permalink raw reply related	[flat|nested] 17+ messages in thread

* [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding
  2013-03-11  7:50 [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot Sebastien Guiriec
  2013-03-11  7:50 ` [PATCH V2 1/2] ARM: dts: OMAP2+: Add SDMA Audio IPs bindings Sebastien Guiriec
@ 2013-03-11  7:50 ` Sebastien Guiriec
  2013-03-11 14:18   ` Peter Ujfalusi
                     ` (3 more replies)
  2013-03-15 14:27 ` [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot Benoit Cousson
  2 siblings, 4 replies; 17+ messages in thread
From: Sebastien Guiriec @ 2013-03-11  7:50 UTC (permalink / raw)
  To: Sebastien Guiriec, Peter Ujfalusi, Liam Girdwood, Mark Brown,
	Benoît Cousson, Jarkko Nikula, Tony Lindgren
  Cc: linux-omap, alsa-devel

Update OMAP2+ driver in order to use OMAP DMA DT binding for OMAP2+.
In case of DT boot snd_dmaengine_generic_pcm_open function is used.

Signed-off-by: Sebastien Guiriec <s-guiriec@ti.com>
---
 sound/soc/omap/mcbsp.c      |   26 ++++++++++++++++----------
 sound/soc/omap/omap-dmic.c  |   15 +++++++++------
 sound/soc/omap/omap-mcpdm.c |   22 ++++++++++++++--------
 sound/soc/omap/omap-pcm.c   |   12 ++++++++++--
 sound/soc/omap/omap-pcm.h   |    1 +
 5 files changed, 50 insertions(+), 26 deletions(-)

diff --git a/sound/soc/omap/mcbsp.c b/sound/soc/omap/mcbsp.c
index 285c836..16936493 100644
--- a/sound/soc/omap/mcbsp.c
+++ b/sound/soc/omap/mcbsp.c
@@ -1012,24 +1012,30 @@ int omap_mcbsp_init(struct platform_device *pdev)
 		}
 	}
 
-	res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "rx");
-	if (!res) {
-		dev_err(&pdev->dev, "invalid rx DMA channel\n");
-		return -ENODEV;
+	if (!pdev->dev.of_node) {
+		res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "rx");
+		if (!res) {
+			dev_err(&pdev->dev, "invalid rx DMA channel\n");
+			return -ENODEV;
+		}
+		mcbsp->dma_data[1].dma_req = res->start;
 	}
 	/* RX DMA request number, and port address configuration */
 	mcbsp->dma_data[1].name = "Audio Capture";
-	mcbsp->dma_data[1].dma_req = res->start;
+	mcbsp->dma_data[1].dma_name = "rx";
 	mcbsp->dma_data[1].port_addr = omap_mcbsp_dma_reg_params(mcbsp, 1);
 
-	res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "tx");
-	if (!res) {
-		dev_err(&pdev->dev, "invalid tx DMA channel\n");
-		return -ENODEV;
+	if (!pdev->dev.of_node) {
+		res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "tx");
+		if (!res) {
+			dev_err(&pdev->dev, "invalid tx DMA channel\n");
+			return -ENODEV;
+		}
+		mcbsp->dma_data[0].dma_req = res->start;
 	}
 	/* TX DMA request number, and port address configuration */
 	mcbsp->dma_data[0].name = "Audio Playback";
-	mcbsp->dma_data[0].dma_req = res->start;
+	mcbsp->dma_data[0].dma_name = "tx";
 	mcbsp->dma_data[0].port_addr = omap_mcbsp_dma_reg_params(mcbsp, 0);
 
 	mcbsp->fclk = clk_get(&pdev->dev, "fck");
diff --git a/sound/soc/omap/omap-dmic.c b/sound/soc/omap/omap-dmic.c
index ba49ccd..8695b32 100644
--- a/sound/soc/omap/omap-dmic.c
+++ b/sound/soc/omap/omap-dmic.c
@@ -62,6 +62,7 @@ struct omap_dmic {
  */
 static struct omap_pcm_dma_data omap_dmic_dai_dma_params = {
 	.name		= "DMIC capture",
+	.dma_name	= "up_link",
 };
 
 static inline void omap_dmic_write(struct omap_dmic *dmic, u16 reg, u32 val)
@@ -478,13 +479,15 @@ static int asoc_dmic_probe(struct platform_device *pdev)
 	}
 	omap_dmic_dai_dma_params.port_addr = res->start + OMAP_DMIC_DATA_REG;
 
-	res = platform_get_resource(pdev, IORESOURCE_DMA, 0);
-	if (!res) {
-		dev_err(dmic->dev, "invalid dma resource\n");
-		ret = -ENODEV;
-		goto err_put_clk;
+	if (!pdev->dev.of_node) {
+		res = platform_get_resource(pdev, IORESOURCE_DMA, 0);
+		if (!res) {
+			dev_err(dmic->dev, "invalid dma resource\n");
+			ret = -ENODEV;
+			goto err_put_clk;
+		}
+		omap_dmic_dai_dma_params.dma_req = res->start;
 	}
-	omap_dmic_dai_dma_params.dma_req = res->start;
 
 	res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "mpu");
 	if (!res) {
diff --git a/sound/soc/omap/omap-mcpdm.c b/sound/soc/omap/omap-mcpdm.c
index 5ca11bd..f41bac8 100644
--- a/sound/soc/omap/omap-mcpdm.c
+++ b/sound/soc/omap/omap-mcpdm.c
@@ -71,9 +71,11 @@ struct omap_mcpdm {
 static struct omap_pcm_dma_data omap_mcpdm_dai_dma_params[] = {
 	{
 		.name = "Audio playback",
+		.dma_name = "dn_link",
 	},
 	{
 		.name = "Audio capture",
+		.dma_name = "up_link",
 	},
 };
 
@@ -449,17 +451,21 @@ static int asoc_mcpdm_probe(struct platform_device *pdev)
 	omap_mcpdm_dai_dma_params[0].port_addr = res->start + MCPDM_REG_DN_DATA;
 	omap_mcpdm_dai_dma_params[1].port_addr = res->start + MCPDM_REG_UP_DATA;
 
-	res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "dn_link");
-	if (!res)
-		return -ENODEV;
+	if (!pdev->dev.of_node) {
+		res = platform_get_resource_byname(pdev, IORESOURCE_DMA,
+						   "dn_link");
+		if (!res)
+			return -ENODEV;
 
-	omap_mcpdm_dai_dma_params[0].dma_req = res->start;
+		omap_mcpdm_dai_dma_params[0].dma_req = res->start;
 
-	res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "up_link");
-	if (!res)
-		return -ENODEV;
+		res = platform_get_resource_byname(pdev, IORESOURCE_DMA,
+						   "up_link");
+		if (!res)
+			return -ENODEV;
 
-	omap_mcpdm_dai_dma_params[1].dma_req = res->start;
+		omap_mcpdm_dai_dma_params[1].dma_req = res->start;
+	}
 
 	res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "mpu");
 	if (res == NULL)
diff --git a/sound/soc/omap/omap-pcm.c b/sound/soc/omap/omap-pcm.c
index c722c2e..df01a95 100644
--- a/sound/soc/omap/omap-pcm.c
+++ b/sound/soc/omap/omap-pcm.c
@@ -176,13 +176,21 @@ static int omap_pcm_open(struct snd_pcm_substream *substream)
 {
 	struct snd_soc_pcm_runtime *rtd = substream->private_data;
 	struct omap_pcm_dma_data *dma_data;
+	int ret;
 
 	snd_soc_set_runtime_hwparams(substream, &omap_pcm_hardware);
 
 	dma_data = snd_soc_dai_get_dma_data(rtd->cpu_dai, substream);
 
-	return snd_dmaengine_pcm_open(substream, omap_dma_filter_fn,
-				      &dma_data->dma_req);
+	if (rtd->cpu_dai->dev->of_node)
+		ret = snd_dmaengine_generic_pcm_open(substream,
+						     rtd->cpu_dai->dev,
+						     dma_data->dma_name);
+	else
+		ret = snd_dmaengine_pcm_open(substream, omap_dma_filter_fn,
+					     &dma_data->dma_req);
+
+	return ret;
 }
 
 static int omap_pcm_close(struct snd_pcm_substream *substream)
diff --git a/sound/soc/omap/omap-pcm.h b/sound/soc/omap/omap-pcm.h
index cabe74c..06faa38 100644
--- a/sound/soc/omap/omap-pcm.h
+++ b/sound/soc/omap/omap-pcm.h
@@ -29,6 +29,7 @@ struct snd_pcm_substream;
 
 struct omap_pcm_dma_data {
 	char		*name;		/* stream identifier */
+	char		*dma_name;	/* DMA request name */
 	int		dma_req;	/* DMA request line */
 	unsigned long	port_addr;	/* transmit/receive register */
 	void (*set_threshold)(struct snd_pcm_substream *substream);
-- 
1.7.10.4


^ permalink raw reply related	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding
  2013-03-11  7:50 ` [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding Sebastien Guiriec
@ 2013-03-11 14:18   ` Peter Ujfalusi
  2013-03-11 18:29     ` Jarkko Nikula
  2013-03-11 14:33   ` Mark Brown
                     ` (2 subsequent siblings)
  3 siblings, 1 reply; 17+ messages in thread
From: Peter Ujfalusi @ 2013-03-11 14:18 UTC (permalink / raw)
  To: Sebastien Guiriec
  Cc: Liam Girdwood, Mark Brown, Benoît Cousson, Jarkko Nikula,
	Tony Lindgren, linux-omap, alsa-devel

On 03/11/2013 08:50 AM, Sebastien Guiriec wrote:
> Update OMAP2+ driver in order to use OMAP DMA DT binding for OMAP2+.
> In case of DT boot snd_dmaengine_generic_pcm_open function is used.

Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>

> 
> Signed-off-by: Sebastien Guiriec <s-guiriec@ti.com>
> ---
>  sound/soc/omap/mcbsp.c      |   26 ++++++++++++++++----------
>  sound/soc/omap/omap-dmic.c  |   15 +++++++++------
>  sound/soc/omap/omap-mcpdm.c |   22 ++++++++++++++--------
>  sound/soc/omap/omap-pcm.c   |   12 ++++++++++--
>  sound/soc/omap/omap-pcm.h   |    1 +
>  5 files changed, 50 insertions(+), 26 deletions(-)
> 
> diff --git a/sound/soc/omap/mcbsp.c b/sound/soc/omap/mcbsp.c
> index 285c836..16936493 100644
> --- a/sound/soc/omap/mcbsp.c
> +++ b/sound/soc/omap/mcbsp.c
> @@ -1012,24 +1012,30 @@ int omap_mcbsp_init(struct platform_device *pdev)
>  		}
>  	}
>  
> -	res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "rx");
> -	if (!res) {
> -		dev_err(&pdev->dev, "invalid rx DMA channel\n");
> -		return -ENODEV;
> +	if (!pdev->dev.of_node) {
> +		res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "rx");
> +		if (!res) {
> +			dev_err(&pdev->dev, "invalid rx DMA channel\n");
> +			return -ENODEV;
> +		}
> +		mcbsp->dma_data[1].dma_req = res->start;
>  	}
>  	/* RX DMA request number, and port address configuration */
>  	mcbsp->dma_data[1].name = "Audio Capture";
> -	mcbsp->dma_data[1].dma_req = res->start;
> +	mcbsp->dma_data[1].dma_name = "rx";
>  	mcbsp->dma_data[1].port_addr = omap_mcbsp_dma_reg_params(mcbsp, 1);
>  
> -	res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "tx");
> -	if (!res) {
> -		dev_err(&pdev->dev, "invalid tx DMA channel\n");
> -		return -ENODEV;
> +	if (!pdev->dev.of_node) {
> +		res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "tx");
> +		if (!res) {
> +			dev_err(&pdev->dev, "invalid tx DMA channel\n");
> +			return -ENODEV;
> +		}
> +		mcbsp->dma_data[0].dma_req = res->start;
>  	}
>  	/* TX DMA request number, and port address configuration */
>  	mcbsp->dma_data[0].name = "Audio Playback";
> -	mcbsp->dma_data[0].dma_req = res->start;
> +	mcbsp->dma_data[0].dma_name = "tx";
>  	mcbsp->dma_data[0].port_addr = omap_mcbsp_dma_reg_params(mcbsp, 0);
>  
>  	mcbsp->fclk = clk_get(&pdev->dev, "fck");
> diff --git a/sound/soc/omap/omap-dmic.c b/sound/soc/omap/omap-dmic.c
> index ba49ccd..8695b32 100644
> --- a/sound/soc/omap/omap-dmic.c
> +++ b/sound/soc/omap/omap-dmic.c
> @@ -62,6 +62,7 @@ struct omap_dmic {
>   */
>  static struct omap_pcm_dma_data omap_dmic_dai_dma_params = {
>  	.name		= "DMIC capture",
> +	.dma_name	= "up_link",
>  };
>  
>  static inline void omap_dmic_write(struct omap_dmic *dmic, u16 reg, u32 val)
> @@ -478,13 +479,15 @@ static int asoc_dmic_probe(struct platform_device *pdev)
>  	}
>  	omap_dmic_dai_dma_params.port_addr = res->start + OMAP_DMIC_DATA_REG;
>  
> -	res = platform_get_resource(pdev, IORESOURCE_DMA, 0);
> -	if (!res) {
> -		dev_err(dmic->dev, "invalid dma resource\n");
> -		ret = -ENODEV;
> -		goto err_put_clk;
> +	if (!pdev->dev.of_node) {
> +		res = platform_get_resource(pdev, IORESOURCE_DMA, 0);
> +		if (!res) {
> +			dev_err(dmic->dev, "invalid dma resource\n");
> +			ret = -ENODEV;
> +			goto err_put_clk;
> +		}
> +		omap_dmic_dai_dma_params.dma_req = res->start;
>  	}
> -	omap_dmic_dai_dma_params.dma_req = res->start;
>  
>  	res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "mpu");
>  	if (!res) {
> diff --git a/sound/soc/omap/omap-mcpdm.c b/sound/soc/omap/omap-mcpdm.c
> index 5ca11bd..f41bac8 100644
> --- a/sound/soc/omap/omap-mcpdm.c
> +++ b/sound/soc/omap/omap-mcpdm.c
> @@ -71,9 +71,11 @@ struct omap_mcpdm {
>  static struct omap_pcm_dma_data omap_mcpdm_dai_dma_params[] = {
>  	{
>  		.name = "Audio playback",
> +		.dma_name = "dn_link",
>  	},
>  	{
>  		.name = "Audio capture",
> +		.dma_name = "up_link",
>  	},
>  };
>  
> @@ -449,17 +451,21 @@ static int asoc_mcpdm_probe(struct platform_device *pdev)
>  	omap_mcpdm_dai_dma_params[0].port_addr = res->start + MCPDM_REG_DN_DATA;
>  	omap_mcpdm_dai_dma_params[1].port_addr = res->start + MCPDM_REG_UP_DATA;
>  
> -	res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "dn_link");
> -	if (!res)
> -		return -ENODEV;
> +	if (!pdev->dev.of_node) {
> +		res = platform_get_resource_byname(pdev, IORESOURCE_DMA,
> +						   "dn_link");
> +		if (!res)
> +			return -ENODEV;
>  
> -	omap_mcpdm_dai_dma_params[0].dma_req = res->start;
> +		omap_mcpdm_dai_dma_params[0].dma_req = res->start;
>  
> -	res = platform_get_resource_byname(pdev, IORESOURCE_DMA, "up_link");
> -	if (!res)
> -		return -ENODEV;
> +		res = platform_get_resource_byname(pdev, IORESOURCE_DMA,
> +						   "up_link");
> +		if (!res)
> +			return -ENODEV;
>  
> -	omap_mcpdm_dai_dma_params[1].dma_req = res->start;
> +		omap_mcpdm_dai_dma_params[1].dma_req = res->start;
> +	}
>  
>  	res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "mpu");
>  	if (res == NULL)
> diff --git a/sound/soc/omap/omap-pcm.c b/sound/soc/omap/omap-pcm.c
> index c722c2e..df01a95 100644
> --- a/sound/soc/omap/omap-pcm.c
> +++ b/sound/soc/omap/omap-pcm.c
> @@ -176,13 +176,21 @@ static int omap_pcm_open(struct snd_pcm_substream *substream)
>  {
>  	struct snd_soc_pcm_runtime *rtd = substream->private_data;
>  	struct omap_pcm_dma_data *dma_data;
> +	int ret;
>  
>  	snd_soc_set_runtime_hwparams(substream, &omap_pcm_hardware);
>  
>  	dma_data = snd_soc_dai_get_dma_data(rtd->cpu_dai, substream);
>  
> -	return snd_dmaengine_pcm_open(substream, omap_dma_filter_fn,
> -				      &dma_data->dma_req);
> +	if (rtd->cpu_dai->dev->of_node)
> +		ret = snd_dmaengine_generic_pcm_open(substream,
> +						     rtd->cpu_dai->dev,
> +						     dma_data->dma_name);
> +	else
> +		ret = snd_dmaengine_pcm_open(substream, omap_dma_filter_fn,
> +					     &dma_data->dma_req);
> +
> +	return ret;
>  }
>  
>  static int omap_pcm_close(struct snd_pcm_substream *substream)
> diff --git a/sound/soc/omap/omap-pcm.h b/sound/soc/omap/omap-pcm.h
> index cabe74c..06faa38 100644
> --- a/sound/soc/omap/omap-pcm.h
> +++ b/sound/soc/omap/omap-pcm.h
> @@ -29,6 +29,7 @@ struct snd_pcm_substream;
>  
>  struct omap_pcm_dma_data {
>  	char		*name;		/* stream identifier */
> +	char		*dma_name;	/* DMA request name */
>  	int		dma_req;	/* DMA request line */
>  	unsigned long	port_addr;	/* transmit/receive register */
>  	void (*set_threshold)(struct snd_pcm_substream *substream);
> 


-- 
Péter
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 1/2] ARM: dts: OMAP2+: Add SDMA Audio IPs bindings
  2013-03-11  7:50 ` [PATCH V2 1/2] ARM: dts: OMAP2+: Add SDMA Audio IPs bindings Sebastien Guiriec
@ 2013-03-11 14:19   ` Peter Ujfalusi
  2013-03-11 18:29     ` Jarkko Nikula
  0 siblings, 1 reply; 17+ messages in thread
From: Peter Ujfalusi @ 2013-03-11 14:19 UTC (permalink / raw)
  To: Sebastien Guiriec
  Cc: alsa-devel, Benoît Cousson, Tony Lindgren, Mark Brown,
	Liam Girdwood, linux-omap, Jarkko Nikula

On 03/11/2013 08:50 AM, Sebastien Guiriec wrote:
> Populate DMA client information for McBSP DMIC and McPDM periperhal on
> OMAP2+ devices.

Looks good to me:
Reviewed-by: Peter Ujfalusi <peter.ujfalusi@ti.com>

> 
> Signed-off-by: Sebastien Guiriec <s-guiriec@ti.com>
> ---
>  arch/arm/boot/dts/omap2420.dtsi |    6 ++++++
>  arch/arm/boot/dts/omap2430.dtsi |   15 +++++++++++++++
>  arch/arm/boot/dts/omap3.dtsi    |   15 +++++++++++++++
>  arch/arm/boot/dts/omap4.dtsi    |   17 +++++++++++++++++
>  arch/arm/boot/dts/omap5.dtsi    |   14 ++++++++++++++
>  5 files changed, 67 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/omap2420.dtsi b/arch/arm/boot/dts/omap2420.dtsi
> index af65609..45930f2 100644
> --- a/arch/arm/boot/dts/omap2420.dtsi
> +++ b/arch/arm/boot/dts/omap2420.dtsi
> @@ -37,6 +37,9 @@
>  				     <60>; /* RX interrupt */
>  			interrupt-names = "tx", "rx";
>  			ti,hwmods = "mcbsp1";
> +			dmas = <&sdma 31>,
> +			       <&sdma 32>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp2: mcbsp@48076000 {
> @@ -47,6 +50,9 @@
>  				     <63>; /* RX interrupt */
>  			interrupt-names = "tx", "rx";
>  			ti,hwmods = "mcbsp2";
> +			dmas = <&sdma 33>,
> +			       <&sdma 34>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		timer1: timer@48028000 {
> diff --git a/arch/arm/boot/dts/omap2430.dtsi b/arch/arm/boot/dts/omap2430.dtsi
> index c392445..cfe7ed9 100644
> --- a/arch/arm/boot/dts/omap2430.dtsi
> +++ b/arch/arm/boot/dts/omap2430.dtsi
> @@ -40,6 +40,9 @@
>  			interrupt-names = "common", "tx", "rx", "rx_overflow";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp1";
> +			dmas = <&sdma 31>,
> +			       <&sdma 32>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp2: mcbsp@48076000 {
> @@ -52,6 +55,9 @@
>  			interrupt-names = "common", "tx", "rx";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp2";
> +			dmas = <&sdma 33>,
> +			       <&sdma 34>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp3: mcbsp@4808c000 {
> @@ -64,6 +70,9 @@
>  			interrupt-names = "common", "tx", "rx";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp3";
> +			dmas = <&sdma 17>,
> +			       <&sdma 18>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp4: mcbsp@4808e000 {
> @@ -76,6 +85,9 @@
>  			interrupt-names = "common", "tx", "rx";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp4";
> +			dmas = <&sdma 19>,
> +			       <&sdma 20>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp5: mcbsp@48096000 {
> @@ -88,6 +100,9 @@
>  			interrupt-names = "common", "tx", "rx";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp5";
> +			dmas = <&sdma 21>,
> +			       <&sdma 22>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		timer1: timer@49018000 {
> diff --git a/arch/arm/boot/dts/omap3.dtsi b/arch/arm/boot/dts/omap3.dtsi
> index 4e7acb6..f901404 100644
> --- a/arch/arm/boot/dts/omap3.dtsi
> +++ b/arch/arm/boot/dts/omap3.dtsi
> @@ -289,6 +289,9 @@
>  			interrupt-names = "common", "tx", "rx";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp1";
> +			dmas = <&sdma 31>,
> +			       <&sdma 32>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp2: mcbsp@49022000 {
> @@ -303,6 +306,9 @@
>  			interrupt-names = "common", "tx", "rx", "sidetone";
>  			ti,buffer-size = <1280>;
>  			ti,hwmods = "mcbsp2", "mcbsp2_sidetone";
> +			dmas = <&sdma 33>,
> +			       <&sdma 34>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp3: mcbsp@49024000 {
> @@ -317,6 +323,9 @@
>  			interrupt-names = "common", "tx", "rx", "sidetone";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp3", "mcbsp3_sidetone";
> +			dmas = <&sdma 17>,
> +			       <&sdma 18>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp4: mcbsp@49026000 {
> @@ -329,6 +338,9 @@
>  			interrupt-names = "common", "tx", "rx";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp4";
> +			dmas = <&sdma 19>,
> +			       <&sdma 20>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp5: mcbsp@48096000 {
> @@ -341,6 +353,9 @@
>  			interrupt-names = "common", "tx", "rx";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp5";
> +			dmas = <&sdma 21>,
> +			       <&sdma 22>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		timer1: timer@48318000 {
> diff --git a/arch/arm/boot/dts/omap4.dtsi b/arch/arm/boot/dts/omap4.dtsi
> index 827f6f3..413c683 100644
> --- a/arch/arm/boot/dts/omap4.dtsi
> +++ b/arch/arm/boot/dts/omap4.dtsi
> @@ -388,6 +388,9 @@
>  			reg-names = "mpu", "dma";
>  			interrupts = <0 112 0x4>;
>  			ti,hwmods = "mcpdm";
> +			dmas = <&sdma 65>,
> +			       <&sdma 66>;
> +			dma-names = "up_link", "dn_link";
>  		};
>  
>  		dmic: dmic@4012e000 {
> @@ -397,6 +400,8 @@
>  			reg-names = "mpu", "dma";
>  			interrupts = <0 114 0x4>;
>  			ti,hwmods = "dmic";
> +			dmas = <&sdma 67>;
> +			dma-names = "up_link";
>  		};
>  
>  		mcbsp1: mcbsp@40122000 {
> @@ -408,6 +413,9 @@
>  			interrupt-names = "common";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp1";
> +			dmas = <&sdma 33>,
> +			       <&sdma 34>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp2: mcbsp@40124000 {
> @@ -419,6 +427,9 @@
>  			interrupt-names = "common";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp2";
> +			dmas = <&sdma 17>,
> +			       <&sdma 18>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp3: mcbsp@40126000 {
> @@ -430,6 +441,9 @@
>  			interrupt-names = "common";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp3";
> +			dmas = <&sdma 19>,
> +			       <&sdma 20>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp4: mcbsp@48096000 {
> @@ -440,6 +454,9 @@
>  			interrupt-names = "common";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp4";
> +			dmas = <&sdma 31>,
> +			       <&sdma 32>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		keypad: keypad@4a31c000 {
> diff --git a/arch/arm/boot/dts/omap5.dtsi b/arch/arm/boot/dts/omap5.dtsi
> index 39b8d76..5aa6086 100644
> --- a/arch/arm/boot/dts/omap5.dtsi
> +++ b/arch/arm/boot/dts/omap5.dtsi
> @@ -364,6 +364,9 @@
>  			reg-names = "mpu", "dma";
>  			interrupts = <0 112 0x4>;
>  			ti,hwmods = "mcpdm";
> +			dmas = <&sdma 65>,
> +			       <&sdma 66>;
> +			dma-names = "up_link", "dn_link";
>  		};
>  
>  		dmic: dmic@4012e000 {
> @@ -373,6 +376,8 @@
>  			reg-names = "mpu", "dma";
>  			interrupts = <0 114 0x4>;
>  			ti,hwmods = "dmic";
> +			dmas = <&sdma 67>;
> +			dma-names = "up_link";
>  		};
>  
>  		mcbsp1: mcbsp@40122000 {
> @@ -384,6 +389,9 @@
>  			interrupt-names = "common";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp1";
> +			dmas = <&sdma 33>,
> +			       <&sdma 34>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp2: mcbsp@40124000 {
> @@ -395,6 +403,9 @@
>  			interrupt-names = "common";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp2";
> +			dmas = <&sdma 17>,
> +			       <&sdma 18>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		mcbsp3: mcbsp@40126000 {
> @@ -406,6 +417,9 @@
>  			interrupt-names = "common";
>  			ti,buffer-size = <128>;
>  			ti,hwmods = "mcbsp3";
> +			dmas = <&sdma 19>,
> +			       <&sdma 20>;
> +			dma-names = "tx", "rx";
>  		};
>  
>  		timer1: timer@4ae18000 {
> 


-- 
Péter

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding
  2013-03-11  7:50 ` [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding Sebastien Guiriec
  2013-03-11 14:18   ` Peter Ujfalusi
@ 2013-03-11 14:33   ` Mark Brown
  2013-03-11 16:27     ` Tony Lindgren
  2013-03-12 18:26   ` Mark Brown
  2013-03-13 10:36   ` Mark Brown
  3 siblings, 1 reply; 17+ messages in thread
From: Mark Brown @ 2013-03-11 14:33 UTC (permalink / raw)
  To: Sebastien Guiriec
  Cc: Peter Ujfalusi, Liam Girdwood, Benoît Cousson,
	Jarkko Nikula, Tony Lindgren, linux-omap, alsa-devel

[-- Attachment #1: Type: text/plain, Size: 361 bytes --]

On Mon, Mar 11, 2013 at 08:50:22AM +0100, Sebastien Guiriec wrote:
> Update OMAP2+ driver in order to use OMAP DMA DT binding for OMAP2+.
> In case of DT boot snd_dmaengine_generic_pcm_open function is used.

Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>

or I can apply to ASoC if people prefer, I don't think it makes much
difference either way.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding
  2013-03-11 14:33   ` Mark Brown
@ 2013-03-11 16:27     ` Tony Lindgren
  2013-03-11 16:28       ` Mark Brown
  0 siblings, 1 reply; 17+ messages in thread
From: Tony Lindgren @ 2013-03-11 16:27 UTC (permalink / raw)
  To: Mark Brown
  Cc: Sebastien Guiriec, Peter Ujfalusi, Liam Girdwood,
	Benoît Cousson, Jarkko Nikula, linux-omap, alsa-devel

* Mark Brown <broonie@opensource.wolfsonmicro.com> [130311 07:37]:
> On Mon, Mar 11, 2013 at 08:50:22AM +0100, Sebastien Guiriec wrote:
> > Update OMAP2+ driver in order to use OMAP DMA DT binding for OMAP2+.
> > In case of DT boot snd_dmaengine_generic_pcm_open function is used.
> 
> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
> 
> or I can apply to ASoC if people prefer, I don't think it makes much
> difference either way.

I suggest you take the driver changes and Benoit takes the .dts
changes as those should be queued separately to avoid unnecessary
merge conflicts with the .dts files.

Regards,

Tony

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding
  2013-03-11 16:27     ` Tony Lindgren
@ 2013-03-11 16:28       ` Mark Brown
  2013-03-11 16:38         ` Tony Lindgren
  0 siblings, 1 reply; 17+ messages in thread
From: Mark Brown @ 2013-03-11 16:28 UTC (permalink / raw)
  To: Tony Lindgren
  Cc: Sebastien Guiriec, Peter Ujfalusi, Liam Girdwood,
	Benoît Cousson, Jarkko Nikula, linux-omap, alsa-devel

[-- Attachment #1: Type: text/plain, Size: 349 bytes --]

On Mon, Mar 11, 2013 at 09:27:00AM -0700, Tony Lindgren wrote:

> I suggest you take the driver changes and Benoit takes the .dts
> changes as those should be queued separately to avoid unnecessary
> merge conflicts with the .dts files.

Won't that cause a bisect issue if the driver starts looking for generic
DT stuff that's not in the DTS files?

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding
  2013-03-11 16:28       ` Mark Brown
@ 2013-03-11 16:38         ` Tony Lindgren
  0 siblings, 0 replies; 17+ messages in thread
From: Tony Lindgren @ 2013-03-11 16:38 UTC (permalink / raw)
  To: Mark Brown
  Cc: Sebastien Guiriec, Peter Ujfalusi, Liam Girdwood,
	Benoît Cousson, Jarkko Nikula, linux-omap, alsa-devel

* Mark Brown <broonie@opensource.wolfsonmicro.com> [130311 09:32]:
> On Mon, Mar 11, 2013 at 09:27:00AM -0700, Tony Lindgren wrote:
> 
> > I suggest you take the driver changes and Benoit takes the .dts
> > changes as those should be queued separately to avoid unnecessary
> > merge conflicts with the .dts files.
> 
> Won't that cause a bisect issue if the driver starts looking for generic
> DT stuff that's not in the DTS files?

It should only affect additional features being enabled. When the .dts
changes get merged the new features just starts working. Or if the .dts
changes go in first, the driver starts working when the driver changes
go in.

If there's some dependency between the driver and the .dts changes
breaking booting etc, that should be fixed in the patches by
for example removing old legacy code later on in a separate series.

This allows us to break the dependency between arch/arm code and
drivers in most cases to keep things simpler.

Regards,

Tony

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 1/2] ARM: dts: OMAP2+: Add SDMA Audio IPs bindings
  2013-03-11 14:19   ` Peter Ujfalusi
@ 2013-03-11 18:29     ` Jarkko Nikula
  0 siblings, 0 replies; 17+ messages in thread
From: Jarkko Nikula @ 2013-03-11 18:29 UTC (permalink / raw)
  To: Peter Ujfalusi
  Cc: Sebastien Guiriec, Liam Girdwood, Mark Brown,
	Benoît Cousson, Tony Lindgren, linux-omap, alsa-devel

On 03/11/2013 04:19 PM, Peter Ujfalusi wrote:
> On 03/11/2013 08:50 AM, Sebastien Guiriec wrote:
>> Populate DMA client information for McBSP DMIC and McPDM periperhal on
>> OMAP2+ devices.
> 
> Looks good to me:
> Reviewed-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
> 

Reviewed-by: Jarkko Nikula <jarkko.nikula@bitmer.com>

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding
  2013-03-11 14:18   ` Peter Ujfalusi
@ 2013-03-11 18:29     ` Jarkko Nikula
  0 siblings, 0 replies; 17+ messages in thread
From: Jarkko Nikula @ 2013-03-11 18:29 UTC (permalink / raw)
  To: Peter Ujfalusi
  Cc: Sebastien Guiriec, Liam Girdwood, Mark Brown,
	Benoît Cousson, Tony Lindgren, linux-omap, alsa-devel

On 03/11/2013 04:18 PM, Peter Ujfalusi wrote:
> On 03/11/2013 08:50 AM, Sebastien Guiriec wrote:
>> Update OMAP2+ driver in order to use OMAP DMA DT binding for OMAP2+.
>> In case of DT boot snd_dmaengine_generic_pcm_open function is used.
> 
> Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
> 
Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com>

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding
  2013-03-11  7:50 ` [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding Sebastien Guiriec
  2013-03-11 14:18   ` Peter Ujfalusi
  2013-03-11 14:33   ` Mark Brown
@ 2013-03-12 18:26   ` Mark Brown
  2013-03-13 10:36   ` Mark Brown
  3 siblings, 0 replies; 17+ messages in thread
From: Mark Brown @ 2013-03-12 18:26 UTC (permalink / raw)
  To: Sebastien Guiriec
  Cc: Peter Ujfalusi, Liam Girdwood, Benoît Cousson,
	Jarkko Nikula, Tony Lindgren, linux-omap, alsa-devel

[-- Attachment #1: Type: text/plain, Size: 226 bytes --]

On Mon, Mar 11, 2013 at 08:50:22AM +0100, Sebastien Guiriec wrote:
> Update OMAP2+ driver in order to use OMAP DMA DT binding for OMAP2+.
> In case of DT boot snd_dmaengine_generic_pcm_open function is used.

Applied, thanks.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding
  2013-03-11  7:50 ` [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding Sebastien Guiriec
                     ` (2 preceding siblings ...)
  2013-03-12 18:26   ` Mark Brown
@ 2013-03-13 10:36   ` Mark Brown
  3 siblings, 0 replies; 17+ messages in thread
From: Mark Brown @ 2013-03-13 10:36 UTC (permalink / raw)
  To: Sebastien Guiriec
  Cc: Peter Ujfalusi, Liam Girdwood, Benoît Cousson,
	Jarkko Nikula, Tony Lindgren, linux-omap, alsa-devel

[-- Attachment #1: Type: text/plain, Size: 356 bytes --]

On Mon, Mar 11, 2013 at 08:50:22AM +0100, Sebastien Guiriec wrote:
> Update OMAP2+ driver in order to use OMAP DMA DT binding for OMAP2+.
> In case of DT boot snd_dmaengine_generic_pcm_open function is used.
> 
> Signed-off-by: Sebastien Guiriec <s-guiriec@ti.com>

Discarded since it breaks the build as a result of depending on unmerged
patches.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot
  2013-03-11  7:50 [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot Sebastien Guiriec
  2013-03-11  7:50 ` [PATCH V2 1/2] ARM: dts: OMAP2+: Add SDMA Audio IPs bindings Sebastien Guiriec
  2013-03-11  7:50 ` [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding Sebastien Guiriec
@ 2013-03-15 14:27 ` Benoit Cousson
  2013-03-15 16:56   ` Mark Brown
  2 siblings, 1 reply; 17+ messages in thread
From: Benoit Cousson @ 2013-03-15 14:27 UTC (permalink / raw)
  To: Sebastien Guiriec
  Cc: Peter Ujfalusi, Liam Girdwood, Mark Brown, Jarkko Nikula,
	Tony Lindgren, linux-omap, alsa-devel

Hi Seb,

On 03/11/2013 08:50 AM, Sebastien Guiriec wrote:
> This patch serie is converting OMAP Audio IPs in order to use OMAP sDMA DT
> binding in case of DT boot on OMAP2+ platforms.
> 
> It is depending on the next patches:
> 
> [1] http://www.spinics.net/lists/arm-kernel/msg227836.html
> [2] http://www.mail-archive.com/linux-omap@vger.kernel.org/msg84668.html

I've just applied it in my for_3.10/dts branch on top of Jon's series
that does add the SDMA binding.

Regards,
Benoit

> 
> It has been tested on:
> - OMAP5 (sEVM/panda)in DT boot (McPDM/DMIC).
> - OMAP4 (SDP4430/Panda) in both DT/non DT boot (McPDM/DMIC)
> - OMAP3 (Beagle XM) in both DT/non DT boot (McBSP)
> 
> Update since v1:
> - Put DTS patch in first.
> - Squash all OMAP IPs patch together.
> 
> Sebastien Guiriec (2):
>   ARM: dts: OMAP2+: Add SDMA Audio IPs bindings
>   ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding
> 
>  arch/arm/boot/dts/omap2420.dtsi |    6 ++++++
>  arch/arm/boot/dts/omap2430.dtsi |   15 +++++++++++++++
>  arch/arm/boot/dts/omap3.dtsi    |   15 +++++++++++++++
>  arch/arm/boot/dts/omap4.dtsi    |   17 +++++++++++++++++
>  arch/arm/boot/dts/omap5.dtsi    |   14 ++++++++++++++
>  sound/soc/omap/mcbsp.c          |   26 ++++++++++++++++----------
>  sound/soc/omap/omap-dmic.c      |   15 +++++++++------
>  sound/soc/omap/omap-mcpdm.c     |   22 ++++++++++++++--------
>  sound/soc/omap/omap-pcm.c       |   12 ++++++++++--
>  sound/soc/omap/omap-pcm.h       |    1 +
>  10 files changed, 117 insertions(+), 26 deletions(-)
> 


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot
  2013-03-15 14:27 ` [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot Benoit Cousson
@ 2013-03-15 16:56   ` Mark Brown
  2013-03-15 17:01     ` Benoit Cousson
  0 siblings, 1 reply; 17+ messages in thread
From: Mark Brown @ 2013-03-15 16:56 UTC (permalink / raw)
  To: Benoit Cousson
  Cc: Sebastien Guiriec, Peter Ujfalusi, Liam Girdwood, Jarkko Nikula,
	Tony Lindgren, linux-omap, alsa-devel

[-- Attachment #1: Type: text/plain, Size: 242 bytes --]

On Fri, Mar 15, 2013 at 03:27:58PM +0100, Benoit Cousson wrote:

> I've just applied it in my for_3.10/dts branch on top of Jon's series
> that does add the SDMA binding.

The ASoC side doesn't build at present due to an unmerged dependency.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot
  2013-03-15 16:56   ` Mark Brown
@ 2013-03-15 17:01     ` Benoit Cousson
  2013-03-15 17:05       ` Mark Brown
  0 siblings, 1 reply; 17+ messages in thread
From: Benoit Cousson @ 2013-03-15 17:01 UTC (permalink / raw)
  To: Mark Brown
  Cc: Sebastien Guiriec, Peter Ujfalusi, Liam Girdwood, Jarkko Nikula,
	Tony Lindgren, linux-omap, alsa-devel

Hi Mark,

On 03/15/2013 05:56 PM, Mark Brown wrote:
> On Fri, Mar 15, 2013 at 03:27:58PM +0100, Benoit Cousson wrote:
> 
>> I've just applied it in my for_3.10/dts branch on top of Jon's series
>> that does add the SDMA binding.
> 
> The ASoC side doesn't build at present due to an unmerged dependency.

Oops, sorry my bad, in fact I've just applied the DTS patch. Seb told me
about that missing dependency.

Having the DTS without the ASoC change will do nothing, so it is fine
merging them separately.

Regards,
Benoit


^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot
  2013-03-15 17:01     ` Benoit Cousson
@ 2013-03-15 17:05       ` Mark Brown
  0 siblings, 0 replies; 17+ messages in thread
From: Mark Brown @ 2013-03-15 17:05 UTC (permalink / raw)
  To: Benoit Cousson
  Cc: Sebastien Guiriec, Peter Ujfalusi, Liam Girdwood, Jarkko Nikula,
	Tony Lindgren, linux-omap, alsa-devel

[-- Attachment #1: Type: text/plain, Size: 231 bytes --]

On Fri, Mar 15, 2013 at 06:01:20PM +0100, Benoit Cousson wrote:

> Having the DTS without the ASoC change will do nothing, so it is fine
> merging them separately.

Yup, that's good and minimises the risk of cross tree issues too.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2013-03-15 17:05 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-11  7:50 [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot Sebastien Guiriec
2013-03-11  7:50 ` [PATCH V2 1/2] ARM: dts: OMAP2+: Add SDMA Audio IPs bindings Sebastien Guiriec
2013-03-11 14:19   ` Peter Ujfalusi
2013-03-11 18:29     ` Jarkko Nikula
2013-03-11  7:50 ` [PATCH V2 2/2] ASoC: OMAP2+: Move McBSP, DMIC and McPDM to generic DMA DT binding Sebastien Guiriec
2013-03-11 14:18   ` Peter Ujfalusi
2013-03-11 18:29     ` Jarkko Nikula
2013-03-11 14:33   ` Mark Brown
2013-03-11 16:27     ` Tony Lindgren
2013-03-11 16:28       ` Mark Brown
2013-03-11 16:38         ` Tony Lindgren
2013-03-12 18:26   ` Mark Brown
2013-03-13 10:36   ` Mark Brown
2013-03-15 14:27 ` [PATCH V2 0/2] ASoC: OMAP2+: Update Audio IP with sDMA binding for DT boot Benoit Cousson
2013-03-15 16:56   ` Mark Brown
2013-03-15 17:01     ` Benoit Cousson
2013-03-15 17:05       ` Mark Brown

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.