ARM/dts: OMAP audio related updates for OMAP2/3/4/5
v3 cover ARM/dts: OMAP audio related updates for OMAP2/3/4/5
Hello,
Changes since v2:
- Fixed the interrupts properties of McBSP for OMAP2/3
- omap2420.dtsi, omap2430.dtsi header date updated to 2012
Changes since v1:
- Rebased on current l-o:devel-dt branch
- Two new patch, one for OMAP4 to add reg-names for the mem areas, one for OMAP5 to add McPDM and DMIC section
The series adds/fixes the audio related IPs (McBSP, McPDM, DMIC) in the dtsi files and enable the audio on BeagleBoard when booted with DT.
I have created on top of:git://git.kernel.org/pub/scm/linux/kernel/git/bcousson/linux-omap-dt.git
for_3.7/dts
Regards,
Peter
---
Peter Ujfalusi (8):
ARM/dts: omap2: Add McBSP entries for OMAP2420 and OMAP2430 SoC ARM/dts: omap2420-h4: Include omap2420.dtsi file instead the common
omap2
ARM/dts: omap3: Add McBSP entries
ARM/dts: omap4: Add McBSP entries
ARM/dts: omap4: Add reg-names for McPDM and DMIC ARM/dts: omap5: Add McBSP entries
ARM/dts: omap5: Add McPDM and DMIC section to the dtsi file ARM/dts: omap3-beagle: Enable audio support
arch/arm/boot/dts/omap2420-h4.dts | 2 +- arch/arm/boot/dts/omap2420.dtsi | 39 ++++++++++++++++++ arch/arm/boot/dts/omap2430.dtsi | 83 ++++++++++++++++++++++++++++++++++++++ arch/arm/boot/dts/omap3-beagle.dts | 14 +++++++ arch/arm/boot/dts/omap3.dtsi | 69 +++++++++++++++++++++++++++++++ arch/arm/boot/dts/omap4.dtsi | 49 ++++++++++++++++++++++ arch/arm/boot/dts/omap5.dtsi | 56 +++++++++++++++++++++++++ 7 files changed, 311 insertions(+), 1 deletion(-) create mode 100644 arch/arm/boot/dts/omap2420.dtsi create mode 100644 arch/arm/boot/dts/omap2430.dtsi
Signature · 1 line
1.7.12
PATCH v3 1/8 ARM/dts: omap2: Add McBSP entries for OMAP2420 and OMAP2430 SoC
The McBSP IP within OMAP2420 and 2430 is different we need to create separate dtsi files for them.
--- arch/arm/boot/dts/omap2420.dtsi | 39 +++++++++++++++++++ arch/arm/boot/dts/omap2430.dtsi | 83 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 122 insertions(+) create mode 100644 arch/arm/boot/dts/omap2420.dtsi create mode 100644 arch/arm/boot/dts/omap2430.dtsi
arch/arm/boot/dts/omap2420.dtsi new file +39 -0
@@ -0,0 +1,39 @@ +/* + * Device Tree Source for OMAP2420 SoC + * + * Copyright (C) 2012 Texas Instruments Incorporated - http://www.ti.com/ + * + * This file is licensed under the terms of the GNU General Public License + * version 2. This program is licensed "as is" without any warranty of any + * kind, whether express or implied. + */ + +/include/ "omap2.dtsi" + +/ { + compatible = "ti,omap2420", "ti,omap2"; + + ocp { + mcbsp1: mcbsp@48074000 { + compatible = "ti,omap2420-mcbsp"; + reg = <0x48074000 0xff>; + reg-names = "mpu"; + interrupts = <59>, /* TX interrupt */ + <60>; /* RX interrupt */ + interrupt-names = "tx", "rx"; + interrupt-parent = <&intc>; + ti,hwmods = "mcbsp1"; + }; + + mcbsp2: mcbsp@48076000 { + compatible = "ti,omap2420-mcbsp"; + reg = <0x48076000 0xff>; + reg-names = "mpu"; + interrupts = <62>, /* TX interrupt */ + <63>; /* RX interrupt */ + interrupt-names = "tx", "rx"; + interrupt-parent = <&intc>; + ti,hwmods = "mcbsp2"; + }; + }; +};
arch/arm/boot/dts/omap2430.dtsi new file +83 -0
83 lines not on this page · raw message
Signature · 1 line
1.7.12
PATCH v3 1/8 ARM/dts: omap2: Add McBSP entries for OMAP2420 and OMAP2430 SoC
Quoted 14 lines · Peter Ujfalusi
arch/arm/boot/dts/omap2420.dtsi new file +14
-0+ + ocp { + mcbsp1: mcbsp at 48074000 { + compatible = "ti,omap2420-mcbsp"; + reg = <0x48074000 0xff>; + reg-names = "mpu"; + interrupts = <59>, /* TX interrupt */ + <60>; /* RX interrupt */ + interrupt-names = "tx", "rx"; + interrupt-parent = <&intc>; + ti,hwmods = "mcbsp1"; + }; + + mcbsp2: mcbsp at 48076000 {
arch/arm/boot/dts/omap2420.dtsi line 38
Quoted 10 lines
arch/arm/boot/dts/omap2420.dtsi new file +10
-0+ compatible = "ti,omap2420-mcbsp"; + reg = <0x48076000 0xff>; + reg-names = "mpu"; + interrupts = <62>, /* TX interrupt */ + <63>; /* RX interrupt */ + interrupt-names = "tx", "rx"; + interrupt-parent = <&intc>; + ti,hwmods = "mcbsp2"; + }; + };
Hmm don't you need to specify the interrupt chip and offset for the interrupts here?
Regards,
Tony
PATCH v3 1/8 ARM/dts: omap2: Add McBSP entries for OMAP2420 and OMAP2430 SoC
Hi Tony,
Quoted 20 lines · Tony Lindgren
Quoted 19 lines · Peter Ujfalusi
arch/arm/boot/dts/omap2420.dtsi new file +19
-0+ + ocp { + mcbsp1: mcbsp at 48074000 { + compatible = "ti,omap2420-mcbsp"; + reg = <0x48074000 0xff>; + reg-names = "mpu"; + interrupts = <59>, /* TX interrupt */ + <60>; /* RX interrupt */ + interrupt-names = "tx", "rx"; + interrupt-parent = <&intc>; + ti,hwmods = "mcbsp1"; + }; + + mcbsp2: mcbsp at 48076000 { + compatible = "ti,omap2420-mcbsp"; + reg = <0x48076000 0xff>; + reg-names = "mpu"; + interrupts = <62>, /* TX interrupt */ + <63>; /* RX interrupt */
Quoted 8 lines
arch/arm/boot/dts/omap2420.dtsi line 38
Quoted 5 lines
arch/arm/boot/dts/omap2420.dtsi new file +5
-0+ interrupt-names = "tx", "rx"; + interrupt-parent = <&intc>; + ti,hwmods = "mcbsp2"; + }; + };Hmm don't you need to specify the interrupt chip and offset for the interrupts here?
Mmm, I'm not sure to get your question, there is the link to the interrupt-parent.
The interrupt number is relative to the parent interrupt domain. So even if the INTC IRQ offset start at 32 instead of 0, DT IRQ mechanism will convert that to the proper hwirq thanks to irqdomain.
In that case we should always provide interrupt number relative to the interrupt controller HW number and not assuming any Linux IRQ number offset like before.
And in fact the interrupt-parent is not even needed, by default if will look to the parent to get the interrupt-controller.
Extract from [1]
interrupt-parent:
"Because the hierarchy of the nodes in the interrupt tree might not match the device tree, the interrupt-parent property is available to make the definition of an interrupt parent explicit.
The value is the phandle to the interrupt parent. If this property is missing from a device, its interrupt parent is assumed to be its device tree parent."
[1] http://www.power.org/resources/downloads/Power_ePAPR_APPROVED_v1.0.pdf
Regards,
Benoit
PATCH v3 1/8 ARM/dts: omap2: Add McBSP entries for OMAP2420 and OMAP2430 SoC
Hi Benoit,
Quoted 43 lines · Benoit Cousson
Hi Tony,
Quoted 20 lines · Tony Lindgren
Quoted 19 lines · Peter Ujfalusi
arch/arm/boot/dts/omap2420.dtsi new file +19
-0+ + ocp { + mcbsp1: mcbsp@48074000 { + compatible = "ti,omap2420-mcbsp"; + reg = <0x48074000 0xff>; + reg-names = "mpu"; + interrupts = <59>, /* TX interrupt */ + <60>; /* RX interrupt */ + interrupt-names = "tx", "rx"; + interrupt-parent = <&intc>; + ti,hwmods = "mcbsp1"; + }; + + mcbsp2: mcbsp@48076000 { + compatible = "ti,omap2420-mcbsp"; + reg = <0x48076000 0xff>; + reg-names = "mpu"; + interrupts = <62>, /* TX interrupt */ + <63>; /* RX interrupt */Quoted 8 lines
arch/arm/boot/dts/omap2420.dtsi line 38
Quoted 5 lines
arch/arm/boot/dts/omap2420.dtsi new file +5
-0+ interrupt-names = "tx", "rx"; + interrupt-parent = <&intc>; + ti,hwmods = "mcbsp2"; + }; + };Hmm don't you need to specify the interrupt chip and offset for the interrupts here?
Mmm, I'm not sure to get your question, there is the link to the interrupt-parent.
The interrupt number is relative to the parent interrupt domain. So even if the INTC IRQ offset start at 32 instead of 0, DT IRQ mechanism will convert that to the proper hwirq thanks to irqdomain.
In that case we should always provide interrupt number relative to the interrupt controller HW number and not assuming any Linux IRQ number offset like before.
Quoted 2 lines
And in fact the interrupt-parent is not even needed, by default if will look to the parent to get the interrupt-controller.
This is true, but it makes the 'code' a bit more readable if I (we) specify the interrupt-parent.
Quoted 16 lines
Extract from [1]
interrupt-parent:
"Because the hierarchy of the nodes in the interrupt tree might not match the device tree, the interrupt-parent property is available to make the definition of an interrupt parent explicit.
The value is the phandle to the interrupt parent. If this property is missing from a device, its interrupt parent is assumed to be its device tree parent."[1] http://www.power.org/resources/downloads/Power_ePAPR_APPROVED_v1.0.pdf
Regards,
Benoit
Signature · 5 lines
Péter -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
PATCH v3 1/8 ARM/dts: omap2: Add McBSP entries for OMAP2420 and OMAP2430 SoC
Quoted 44 lines · Peter Ujfalusi
Hi Benoit,
Quoted 41 lines · Benoit Cousson
Hi Tony,
Quoted 20 lines · Tony Lindgren
Quoted 19 lines · Peter Ujfalusi
arch/arm/boot/dts/omap2420.dtsi new file +19
-0+ + ocp { + mcbsp1: mcbsp at 48074000 { + compatible = "ti,omap2420-mcbsp"; + reg = <0x48074000 0xff>; + reg-names = "mpu"; + interrupts = <59>, /* TX interrupt */ + <60>; /* RX interrupt */ + interrupt-names = "tx", "rx"; + interrupt-parent = <&intc>; + ti,hwmods = "mcbsp1"; + }; + + mcbsp2: mcbsp at 48076000 { + compatible = "ti,omap2420-mcbsp"; + reg = <0x48076000 0xff>; + reg-names = "mpu"; + interrupts = <62>, /* TX interrupt */ + <63>; /* RX interrupt */Quoted 8 lines
arch/arm/boot/dts/omap2420.dtsi line 38
Quoted 5 lines
arch/arm/boot/dts/omap2420.dtsi new file +5
-0+ interrupt-names = "tx", "rx"; + interrupt-parent = <&intc>; + ti,hwmods = "mcbsp2"; + }; + };Hmm don't you need to specify the interrupt chip and offset for the interrupts here?
Mmm, I'm not sure to get your question, there is the link to the interrupt-parent.
The interrupt number is relative to the parent interrupt domain. So even if the INTC IRQ offset start at 32 instead of 0, DT IRQ mechanism will convert that to the proper hwirq thanks to irqdomain.
In that case we should always provide interrupt number relative to the interrupt controller HW number and not assuming any Linux IRQ number offset like before.
Yes never mind, I was confused. We have #interrupt-cells = <1> and the interrupt specifier is just the interrupt offset..
Regards,
Tony
Quoted 26 lines
Quoted 2 lines
And in fact the interrupt-parent is not even needed, by default if will look to the parent to get the interrupt-controller.
This is true, but it makes the 'code' a bit more readable if I (we) specify the interrupt-parent.
Quoted 16 lines
Extract from [1]
interrupt-parent:
"Because the hierarchy of the nodes in the interrupt tree might not match the device tree, the interrupt-parent property is available to make the definition of an interrupt parent explicit.
The value is the phandle to the interrupt parent. If this property is missing from a device, its interrupt parent is assumed to be its device tree parent."[1] http://www.power.org/resources/downloads/Power_ePAPR_APPROVED_v1.0.pdf
Regards,
BenoitSignature · 1 line
P?ter
PATCH v3 2/8 ARM/dts: omap2420-h4: Include omap2420.dtsi file instead the common omap2
In reply to Peter UjfalusiSince the board is based on OMAP2420 we should include the dedicated dtsi file (which includes the common omap2 dtsi).
--- arch/arm/boot/dts/omap2420-h4.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/omap2420-h4.dts +1 -1
@@ -7,7 +7,7 @@ */ /dts-v1/; -/include/ "omap2.dtsi" +/include/ "omap2420.dtsi" / { model = "TI OMAP2420 H4 board";
Signature · 1 line
1.7.12
PATCH v3 3/8 ARM/dts: omap3: Add McBSP entries
In reply to Peter UjfalusiCreate the needed sections to be able to probe McBSP ports via DT.
--- arch/arm/boot/dts/omap3.dtsi | 69 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 69 insertions(+)
arch/arm/boot/dts/omap3.dtsi +69 -0
@@ -220,5 +220,74 @@ compatible = "ti,omap3-wdt"; ti,hwmods = "wd_timer2"; }; + + mcbsp1: mcbsp at 48074000 { + compatible = "ti,omap3-mcbsp"; + reg = <0x48074000 0xff>; + reg-names = "mpu"; + interrupts = <16>, /* OCP compliant interrupt */ + <59>, /* TX interrupt */ + <60>; /* RX interrupt */ + interrupt-names = "common", "tx", "rx"; + interrupt-parent = <&intc>; + ti,buffer-size = <128>; + ti,hwmods = "mcbsp1"; + }; + + mcbsp2: mcbsp at 49022000 { + compatible = "ti,omap3-mcbsp"; + reg = <0x49022000 0xff>, + <0x49028000 0xff>; + reg-names = "mpu", "sidetone"; + interrupts = <17>, /* OCP compliant interrupt */ + <62>, /* TX interrupt */ + <63>, /* RX interrupt */ + <4>; /* Sidetone */ + interrupt-names = "common", "tx", "rx", "sidetone"; + interrupt-parent = <&intc>; + ti,buffer-size = <1280>; + ti,hwmods = "mcbsp2"; + }; + + mcbsp3: mcbsp at 49024000 { + compatible = "ti,omap3-mcbsp"; + reg = <0x49024000 0xff>, + <0x4902a000 0xff>; + reg-names = "mpu", "sidetone"; + interrupts = <22>, /* OCP compliant interrupt */ + <89>, /* TX interrupt */ + <90>, /* RX interrupt */ + <5>; /* Sidetone */ + interrupt-names = "common", "tx", "rx", "sidetone"; + interrupt-parent = <&intc>; + ti,buffer-size = <128>; + ti,hwmods = "mcbsp3"; + }; + + mcbsp4: mcbsp at 49026000 { + compatible = "ti,omap3-mcbsp"; + reg = <0x49026000 0xff>; + reg-names = "mpu"; + interrupts = <23>, /* OCP compliant interrupt */ + <54>, /* TX interrupt */ + <55>; /* RX interrupt */ + interrupt-names = "common", "tx", "rx"; + interrupt-parent = <&intc>; + ti,buffer-size = <128>; + ti,hwmods = "mcbsp4"; + }; + + mcbsp5: mcbsp at 48096000 { + compatible = "ti,omap3-mcbsp"; + reg = <0x48096000 0xff>; + reg-names = "mpu"; + interrupts = <27>, /* OCP compliant interrupt */ + <81>, /* TX interrupt */ + <82>; /* RX interrupt */ + interrupt-names = "common", "tx", "rx"; + interrupt-parent = <&intc>; + ti,buffer-size = <128>; + ti,hwmods = "mcbsp5"; + }; }; };
Signature · 1 line
1.7.12
PATCH v3 4/8 ARM/dts: omap4: Add McBSP entries
In reply to Peter UjfalusiCreate the sections describing the McBSP ports to be able to use them via DT.
--- arch/arm/boot/dts/omap4.dtsi | 47 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+)
arch/arm/boot/dts/omap4.dtsi +47 -0
@@ -287,6 +287,53 @@ ti,hwmods = "dmic"; }; + mcbsp1: mcbsp at 40122000 { + compatible = "ti,omap4-mcbsp"; + reg = <0x40122000 0xff>, /* MPU private access */ + <0x49022000 0xff>; /* L3 Interconnect */ + reg-names = "mpu", "dma"; + interrupts = <0 17 0x4>; + interrupt-names = "common"; + interrupt-parent = <&gic>; + ti,buffer-size = <128>; + ti,hwmods = "mcbsp1"; + }; + + mcbsp2: mcbsp at 40124000 { + compatible = "ti,omap4-mcbsp"; + reg = <0x40124000 0xff>, /* MPU private access */ + <0x49024000 0xff>; /* L3 Interconnect */ + reg-names = "mpu", "dma"; + interrupts = <0 22 0x4>; + interrupt-names = "common"; + interrupt-parent = <&gic>; + ti,buffer-size = <128>; + ti,hwmods = "mcbsp2"; + }; + + mcbsp3: mcbsp at 40126000 { + compatible = "ti,omap4-mcbsp"; + reg = <0x40126000 0xff>, /* MPU private access */ + <0x49026000 0xff>; /* L3 Interconnect */ + reg-names = "mpu", "dma"; + interrupts = <0 23 0x4>; + interrupt-names = "common"; + interrupt-parent = <&gic>; + ti,buffer-size = <128>; + ti,hwmods = "mcbsp3"; + }; + + mcbsp4: mcbsp at 48096000 { + compatible = "ti,omap4-mcbsp"; + reg = <0x48096000 0xff>; /* L4 Interconnect */ + reg-names = "mpu"; + interrupts = <0 16 0x4>; + interrupt-names = "common"; + interrupt-parent = <&gic>; + ti,buffer-size = <128>; + ti,hwmods = "mcbsp4"; + }; + keypad: keypad at 4a31c000 { compatible = "ti,omap4-keypad"; ti,hwmods = "kbd";
Signature · 1 line
1.7.12
PATCH v3 5/8 ARM/dts: omap4: Add reg-names for McPDM and DMIC
In reply to Peter UjfalusiIn order to get the memory areas by name when booted with DT.
--- arch/arm/boot/dts/omap4.dtsi | 2 ++ 1 file changed, 2 insertions(+)
arch/arm/boot/dts/omap4.dtsi +2 -0
@@ -273,6 +273,7 @@ compatible = "ti,omap4-mcpdm"; reg = <0x40132000 0x7f>, /* MPU private access */ <0x49032000 0x7f>; /* L3 Interconnect */ + reg-names = "mpu", "dma"; interrupts = <0 112 0x4>; interrupt-parent = <&gic>; ti,hwmods = "mcpdm";
@@ -282,6 +283,7 @@ compatible = "ti,omap4-dmic"; reg = <0x4012e000 0x7f>, /* MPU private access */ <0x4902e000 0x7f>; /* L3 Interconnect */ + reg-names = "mpu", "dma"; interrupts = <0 114 0x4>; interrupt-parent = <&gic>; ti,hwmods = "dmic";
Signature · 1 line
1.7.12
PATCH v3 6/8 ARM/dts: omap5: Add McBSP entries
In reply to Peter UjfalusiCreate the sections describing the McBSP ports to be able to use them via DT.
--- arch/arm/boot/dts/omap5.dtsi | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+)
arch/arm/boot/dts/omap5.dtsi +36 -0
@@ -251,5 +251,41 @@ compatible = "ti,omap4-keypad"; ti,hwmods = "kbd"; }; + + mcbsp1: mcbsp at 40122000 { + compatible = "ti,omap4-mcbsp"; + reg = <0x40122000 0xff>, /* MPU private access */ + <0x49022000 0xff>; /* L3 Interconnect */ + reg-names = "mpu", "dma"; + interrupts = <0 17 0x4>; + interrupt-names = "common"; + interrupt-parent = <&gic>; + ti,buffer-size = <128>; + ti,hwmods = "mcbsp1"; + }; + + mcbsp2: mcbsp at 40124000 { + compatible = "ti,omap4-mcbsp"; + reg = <0x40124000 0xff>, /* MPU private access */ + <0x49024000 0xff>; /* L3 Interconnect */ + reg-names = "mpu", "dma"; + interrupts = <0 22 0x4>; + interrupt-names = "common"; + interrupt-parent = <&gic>; + ti,buffer-size = <128>; + ti,hwmods = "mcbsp2"; + }; + + mcbsp3: mcbsp at 40126000 { + compatible = "ti,omap4-mcbsp"; + reg = <0x40126000 0xff>, /* MPU private access */ + <0x49026000 0xff>; /* L3 Interconnect */ + reg-names = "mpu", "dma"; + interrupts = <0 23 0x4>; + interrupt-names = "common"; + interrupt-parent = <&gic>; + ti,buffer-size = <128>; + ti,hwmods = "mcbsp3"; + }; }; };
Signature · 1 line
1.7.12
PATCH v3 7/8 ARM/dts: omap5: Add McPDM and DMIC section to the dtsi file
In reply to Peter UjfalusiTo be able to load the McPDM and DMIC driver when booted with device tree.
--- arch/arm/boot/dts/omap5.dtsi | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+)
arch/arm/boot/dts/omap5.dtsi +20 -0
@@ -252,6 +252,26 @@ ti,hwmods = "kbd"; }; + mcpdm: mcpdm at 40132000 { + compatible = "ti,omap4-mcpdm"; + reg = <0x40132000 0x7f>, /* MPU private access */ + <0x49032000 0x7f>; /* L3 Interconnect */ + reg-names = "mpu", "dma"; + interrupts = <0 112 0x4>; + interrupt-parent = <&gic>; + ti,hwmods = "mcpdm"; + }; + + dmic: dmic at 4012e000 { + compatible = "ti,omap4-dmic"; + reg = <0x4012e000 0x7f>, /* MPU private access */ + <0x4902e000 0x7f>; /* L3 Interconnect */ + reg-names = "mpu", "dma"; + interrupts = <0 114 0x4>; + interrupt-parent = <&gic>; + ti,hwmods = "dmic"; + }; + mcbsp1: mcbsp at 40122000 { compatible = "ti,omap4-mcbsp"; reg = <0x40122000 0xff>, /* MPU private access */
Signature · 1 line
1.7.12
PATCH v3 8/8 ARM/dts: omap3-beagle: Enable audio support
In reply to Peter UjfalusiAdd the needed sections to enable audio support on BeagleBoard when booted with DT blob.
--- arch/arm/boot/dts/omap3-beagle.dts | 14 ++++++++++++++ 1 file changed, 14 insertions(+)
arch/arm/boot/dts/omap3-beagle.dts +14 -0
@@ -25,6 +25,14 @@ gpios = <&twl_gpio 19 0>; /* LEDB */ }; }; + + sound { + compatible = "ti,omap-twl4030"; + ti,model = "omap3beagle"; + + ti,mcbsp = <&mcbsp2>; + ti,codec = <&twl_audio>; + }; }; &i2c1 {
@@ -40,6 +48,12 @@ regulator-min-microvolt = <1800000>; regulator-max-microvolt = <3000000>; }; + + twl_audio: audio { + compatible = "ti,twl4030-audio"; + codec { + }; + }; }; };
Signature · 1 line
1.7.12