Add device tree support to AM33XX SoC
cover Add device tree support to AM33XX SoC
This patch series add device tree support for AM33XX SoC family.
Initialy Hiremath Vaibhav submitted a patch for AM33XX devices based on omap3 family. Details at
http://marc.info/?t=132687107200002&r=1&w=2
AM33XX family is varied from omap3 family in these aspects like memory maps, peripheral base addresses and configuration parameters. In some cases we have to use a mix of omap3 and omap4 parameters. So a seperate am33xx.dtsi file is created for all the devices comes under am33xx family and revert of above patch is required.
Two sepearte device tree source files are created (am335x-evm.dts and am335x-bone.dts) to add support for AM335X EVM and BeagleBone boards.
Linux booting is tested on AM335X-EVM and BeagleBone boards.
AnilKumar Ch (4):
Revert "arm/dts: Add support for TI AM335x EVM board" arm/dts: Add initial DT support for AM33XX SoC family arm/dts: Add support for AM335x EVM
arm/dts: Add support for AM335x BeagleBone
.../devicetree/bindings/arm/omap/omap.txt | 3 + arch/arm/boot/dts/am335x-bone.dts | 20 +++ arch/arm/boot/dts/am335x-evm.dts | 25 +-- arch/arm/boot/dts/am33xx.dtsi | 189 ++++++++++++++++++++ 4 files changed, 215 insertions(+), 22 deletions(-) create mode 100644 arch/arm/boot/dts/am335x-bone.dts create mode 100644 arch/arm/boot/dts/am33xx.dtsi
Signature · 1 line
1.7.9.5
PATCH 1/4 Revert "arm/dts: Add support for TI AM335x EVM board"
This reverts commit 6c54bbb42678c99685c8e7fd09267e1cb8c2ae40.
--- arch/arm/boot/dts/am335x-evm.dts | 39 -------------------------------------- 1 file changed, 39 deletions(-) delete mode 100644 arch/arm/boot/dts/am335x-evm.dts
arch/arm/boot/dts/am335x-evm.dts deleted +0 -39
@@ -1,39 +0,0 @@ -/* - * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/ - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. - */ -/dts-v1/; - -/include/ "omap3.dtsi" - -/ { - model = "TI AM335x EVM"; - compatible = "ti,am335x-evm", "ti,am33xx", "ti,omap3"; - - memory { - device_type = "memory"; - reg = <0x80000000 0x10000000>; /* 256 MB */ - }; -}; - -&intc { - /* - * AM33XX family of devices have 128 interrupts - */ - ti,intc-size = <128>; -}; - -&i2c1 { - clock-frequency = <400000>; -}; - -&i2c2 { - clock-frequency = <400000>; -}; - -&i2c3 { - clock-frequency = <400000>; -};
Signature · 1 line
1.7.9.5
PATCH 1/4 Revert "arm/dts: Add support for TI AM335x EVM board"
Quoted 1 line · AnilKumar Ch
This reverts commit
6c54bbb42678c99685c8e7fd09267e1cb8c2ae40.
As that has not been merged yet, I'll just drop it and set up a new devel-dt branch. Applying the reset into devel-dt.
Tony
PATCH 1/4 Revert "arm/dts: Add support for TI AM335x EVM board"
Quoted 6 lines · Tony Lindgren
Quoted 1 line · AnilKumar Ch
This reverts commit
6c54bbb42678c99685c8e7fd09267e1cb8c2ae40.As that has not been merged yet, I'll just drop it and set up a new devel-dt branch. Applying the reset into devel-dt.
Yeah, that's better.
Care to include it into you next pull request.
Thanks,
Vaibhav
PATCH 1/4 Revert "arm/dts: Add support for TI AM335x EVM board"
Hi Tony,
Quoted 6 lines · Vaibhav
Quoted 3 lines · Tony Lindgren
Quoted 1 line · AnilKumar Ch
This reverts commit
6c54bbb42678c99685c8e7fd09267e1cb8c2ae40.
Quoted 8 lines
Quoted 3 lines
As that has not been merged yet, I'll just drop it and set up a new devel-dt branch. Applying the reset into devel-dt.
Yeah, that's better.
Care to include it into you next pull request.
devel-dt branch is created but these patches are not pushed yet.
Let me know do you have any comments on the patches.
Thanks
AnilKumar
PATCH 1/4 Revert "arm/dts: Add support for TI AM335x EVM board"
Quoted 16 lines · AnilKumar, Chimata
Hi Tony,
Quoted 13 lines · Vaibhav
Quoted 6 lines · Tony Lindgren
Quoted 1 line · AnilKumar Ch
This reverts commit
6c54bbb42678c99685c8e7fd09267e1cb8c2ae40.As that has not been merged yet, I'll just drop it and set up a new devel-dt branch. Applying the reset into devel-dt.
Yeah, that's better.
Care to include it into you next pull request.
Yes that's the plan.
Quoted 3 lines
devel-dt branch is created but these patches are not pushed yet.
Let me know do you have any comments on the patches.
Oops, sorry yes looks like I only dropped the one you wanted to revert but forgot to apply the new ones. Applied now to devel-dt and pushed out.
Regards,
Tony
PATCH 2/4 arm/dts: Add initial DT support for AM33XX SoC family
In reply to AnilKumar ChAdd device tree source include file for the AM33XX SoC family. An additional .dtsi file is created to describe the generic AM33XX CPU module like intc, ocp.
Actual selection of available peripherals is handled in seperate .dts files using this am33xx.dtsi generic header file.
--- arch/arm/boot/dts/am33xx.dtsi | 189 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 189 insertions(+) create mode 100644 arch/arm/boot/dts/am33xx.dtsi
arch/arm/boot/dts/am33xx.dtsi new file +189 -0
@@ -0,0 +1,189 @@ +/* + * Device Tree Source for AM33XX 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/ "skeleton.dtsi" + +/ { + compatible = "ti,am33xx"; + + aliases { + serial0 = &uart1; + serial1 = &uart2; + serial2 = &uart3; + serial3 = &uart4; + serial4 = &uart5; + serial5 = &uart6; + }; + + cpus { + cpu at 0 { + compatible = "arm,cortex-a8"; + }; + }; + + /* + * The soc node represents the soc top level view. It is uses for IPs + * that are not memory mapped in the MPU view or for the MPU itself. + */ + soc { + compatible = "ti,omap-infra"; + mpu { + compatible = "ti,omap3-mpu"; + ti,hwmods = "mpu"; + }; + }; + + /* + * XXX: Use a flat representation of the AM33XX interconnect. + * The real AM33XX interconnect network is quite complex.Since + * that will not bring real advantage to represent that in DT + * for the moment, just use a fake OCP bus entry to represent + * the whole bus hierarchy. + */ + ocp { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + ranges; + ti,hwmods = "l3_main"; + + intc: interrupt-controller at 48200000 { + compatible = "ti,omap2-intc"; + interrupt-controller; + #interrupt-cells = <1>; + ti,intc-size = <128>; + reg = <0x48200000 0x1000>; + }; + + gpio1: gpio at 44e07000 { + compatible = "ti,omap4-gpio"; + ti,hwmods = "gpio1"; + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <1>; + }; + + gpio2: gpio at 4804C000 { + compatible = "ti,omap4-gpio"; + ti,hwmods = "gpio2"; + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <1>; + }; + + gpio3: gpio at 481AC000 { + compatible = "ti,omap4-gpio"; + ti,hwmods = "gpio3"; + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <1>; + }; + + gpio4: gpio at 481AE000 { + compatible = "ti,omap4-gpio"; + ti,hwmods = "gpio4"; + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <1>; + }; + + uart1: serial at 44E09000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart1"; + clock-frequency = <48000000>; + }; + + uart2: serial at 48022000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart2"; + clock-frequency = <48000000>; + }; + + uart3: serial at 48024000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart3"; + clock-frequency = <48000000>; + }; + + uart4: serial at 481A6000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart4"; + clock-frequency = <48000000>; + }; + + uart5: serial at 481A8000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart5"; + clock-frequency = <48000000>; + }; + + uart6: serial at 481AA000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart6"; + clock-frequency = <48000000>; + }; + + i2c1: i2c at 44E0B000 { + compatible = "ti,omap4-i2c"; + #address-cells = <1>; + #size-cells = <0>; + ti,hwmods = "i2c1"; + }; + + i2c2: i2c at 4802A000 { + compatible = "ti,omap4-i2c"; + #address-cells = <1>; + #size-cells = <0>; + ti,hwmods = "i2c2"; + }; + + i2c3: i2c at 4819C000 { + compatible = "ti,omap4-i2c"; + #address-cells = <1>; + #size-cells = <0>; + ti,hwmods = "i2c3"; + }; + + mcspi1: spi at 48030000 { + compatible = "ti,omap2-mcspi"; + #address-cells = <1>; + #size-cells = <0>; + ti,hwmods = "spi0"; + ti,spi-num-cs = <4>; + }; + + mcspi2: spi at 481Aa000 { + compatible = "ti,omap2-mcspi"; + #address-cells = <1>; + #size-cells = <0>; + ti,hwmods = "spi1"; + ti,spi-num-cs = <2>; + }; + + mmc1: mmc at 48060000 { + compatible = "ti,omap3-hsmmc"; + ti,hwmods = "mmc1"; + }; + + mmc2: mmc at 481D8000 { + compatible = "ti,omap3-hsmmc"; + ti,hwmods = "mmc2"; + }; + + mmc3: mmc at 47810000 { + compatible = "ti,omap3-hsmmc"; + ti,hwmods = "mmc3"; + }; + }; +};
Signature · 1 line
1.7.9.5
PATCH 2/4 arm/dts: Add initial DT support for AM33XX SoC family
Hi Tony,
Quoted 169 lines · Chimata
Add device tree source include file for the AM33XX SoC family. An additional .dtsi file is created to describe the generic AM33XX CPU module like intc, ocp.
Actual selection of available peripherals is handled in seperate .dts files using this
am33xx.dtsigeneric header file.Signed-off-by AnilKumar Ch <[email protected]>Reviewed-by Vaibhav Hiremath <[email protected]>--- arch/arm/boot/dts/am33xx.dtsi | 189 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 189 insertions(+) create mode 100644 arch/arm/boot/dts/am33xx.dtsiarch/arm/boot/dts/am33xx.dtsi new file +149
-0@@ -0,0 +1,189 @@ +/* + * Device Tree Source for AM33XX 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/ "skeleton.dtsi" + +/ { + compatible = "ti,am33xx"; + + aliases { + serial0 = &uart1; + serial1 = &uart2; + serial2 = &uart3; + serial3 = &uart4; + serial4 = &uart5; + serial5 = &uart6; + }; + + cpus { + cpu at 0 { + compatible = "arm,cortex-a8"; + }; + }; + + /* + * The soc node represents the soc top level view. It is uses for IPs + * that are not memory mapped in the MPU view or for the MPU itself. + */ + soc { + compatible = "ti,omap-infra"; + mpu { + compatible = "ti,omap3-mpu"; + ti,hwmods = "mpu"; + }; + }; + + /* + * XXX: Use a flat representation of the AM33XX interconnect. + * The real AM33XX interconnect network is quite complex.Since + * that will not bring real advantage to represent that in DT + * for the moment, just use a fake OCP bus entry to represent + * the whole bus hierarchy. + */ + ocp { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + ranges; + ti,hwmods = "l3_main"; + + intc: interrupt-controller at 48200000 { + compatible = "ti,omap2-intc"; + interrupt-controller; + #interrupt-cells = <1>; + ti,intc-size = <128>; + reg = <0x48200000 0x1000>; + }; + + gpio1: gpio at 44e07000 { + compatible = "ti,omap4-gpio"; + ti,hwmods = "gpio1"; + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <1>; + }; + + gpio2: gpio at 4804C000 { + compatible = "ti,omap4-gpio"; + ti,hwmods = "gpio2"; + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <1>; + }; + + gpio3: gpio at 481AC000 { + compatible = "ti,omap4-gpio"; + ti,hwmods = "gpio3"; + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <1>; + }; + + gpio4: gpio at 481AE000 { + compatible = "ti,omap4-gpio"; + ti,hwmods = "gpio4"; + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <1>; + }; + + uart1: serial at 44E09000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart1"; + clock-frequency = <48000000>; + }; + + uart2: serial at 48022000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart2"; + clock-frequency = <48000000>; + }; + + uart3: serial at 48024000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart3"; + clock-frequency = <48000000>; + }; + + uart4: serial at 481A6000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart4"; + clock-frequency = <48000000>; + }; + + uart5: serial at 481A8000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart5"; + clock-frequency = <48000000>; + }; + + uart6: serial at 481AA000 { + compatible = "ti,omap3-uart"; + ti,hwmods = "uart6"; + clock-frequency = <48000000>; + }; + + i2c1: i2c at 44E0B000 { + compatible = "ti,omap4-i2c"; + #address-cells = <1>; + #size-cells = <0>; + ti,hwmods = "i2c1"; + }; + + i2c2: i2c at 4802A000 { + compatible = "ti,omap4-i2c"; + #address-cells = <1>; + #size-cells = <0>; + ti,hwmods = "i2c2"; + };
arch/arm/boot/dts/am33xx.dtsi line 159
Quoted 10 lines
arch/arm/boot/dts/am33xx.dtsi new file +10
-0+ + i2c3: i2c at 4819C000 { + compatible = "ti,omap4-i2c"; + #address-cells = <1>; + #size-cells = <0>; + ti,hwmods = "i2c3"; + }; + + mcspi1: spi at 48030000 { + compatible = "ti,omap2-mcspi";
I realized that for mcspi and mmc, the compatible name supposed tobe close to omap4-mcspi.
These changes seems to went from my local branch, so could you please merge below patch with this5fc0b42a98556bd9f01cecc6a64fcbd15ec363f0 "arm/dts: Add initial DT support for AM33XX SoC family"
arch/arm/boot/dts/am33xx.dtsi +0 -31
@@ -166,36 +166,5 @@ #size-cells = <0>; ti,hwmods = "i2c3"; }; - - mcspi1: spi at 48030000 { - compatible = "ti,omap2-mcspi"; - #address-cells = <1>; - #size-cells = <0>; - ti,hwmods = "spi0"; - ti,spi-num-cs = <4>; - }; - - mcspi2: spi at 481Aa000 { - compatible = "ti,omap2-mcspi"; - #address-cells = <1>; - #size-cells = <0>; - ti,hwmods = "spi1"; - ti,spi-num-cs = <2>; - }; - - mmc1: mmc at 48060000 { - compatible = "ti,omap3-hsmmc"; - ti,hwmods = "mmc1"; - }; - - mmc2: mmc at 481D8000 { - compatible = "ti,omap3-hsmmc"; - ti,hwmods = "mmc2"; - }; - - mmc3: mmc at 47810000 { - compatible = "ti,omap3-hsmmc"; - ti,hwmods = "mmc3"; - }; }; };
--
Thanks
AnilKumar
PATCH 2/4 arm/dts: Add initial DT support for AM33XX SoC family
Hi,
Quoted 7 lines · AnilKumar, Chimata
I realized that for mcspi and mmc, the compatible name supposed tobe close to omap4-mcspi.
These changes seems to went from my local branch, so could you please merge below patch with this5fc0b42a98556bd9f01cecc6a64fcbd15ec363f0"arm/dts: Add initial DT support for AM33XX SoC family"
I don't quite follow, do you mean you want to change some compatible names? Your patch is just removing entries though?
Anyways, please just send a fix with a proper description and Signed-off-by on top of the devel-dt branch.
Regards,
Tony
Quoted 45 lines
arch/arm/boot/dts/am33xx.dtsi +0
-32@@ -166,36 +166,5 @@ #size-cells = <0>; ti,hwmods = "i2c3"; }; - - mcspi1: spi at 48030000 { - compatible = "ti,omap2-mcspi"; - #address-cells = <1>; - #size-cells = <0>; - ti,hwmods = "spi0"; - ti,spi-num-cs = <4>; - }; - - mcspi2: spi at 481Aa000 { - compatible = "ti,omap2-mcspi"; - #address-cells = <1>; - #size-cells = <0>; - ti,hwmods = "spi1"; - ti,spi-num-cs = <2>; - }; - - mmc1: mmc at 48060000 { - compatible = "ti,omap3-hsmmc"; - ti,hwmods = "mmc1"; - }; - - mmc2: mmc at 481D8000 { - compatible = "ti,omap3-hsmmc"; - ti,hwmods = "mmc2"; - }; - - mmc3: mmc at 47810000 { - compatible = "ti,omap3-hsmmc"; - ti,hwmods = "mmc3"; - }; }; }; --Thanks
AnilKumar
PATCH 3/4 arm/dts: Add support for AM335x EVM
In reply to AnilKumar ChAdd AM335X EVM device tree source (am335x-evm.dts) file to use the am33xx.dtsi SoC file, along with the memory node information.
--- arch/arm/boot/dts/am335x-evm.dts | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 arch/arm/boot/dts/am335x-evm.dts
arch/arm/boot/dts/am335x-evm.dts new file +20 -0
@@ -0,0 +1,20 @@ +/* + * Copyright (C) 2012 Texas Instruments Incorporated - http://www.ti.com/ + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ +/dts-v1/; + +/include/ "am33xx.dtsi" + +/ { + model = "TI AM335x EVM"; + compatible = "ti,am335x-evm", "ti,am33xx"; + + memory { + device_type = "memory"; + reg = <0x80000000 0x10000000>; /* 256 MB */ + }; +};
Signature · 1 line
1.7.9.5
PATCH 4/4 arm/dts: Add support for AM335x BeagleBone
In reply to AnilKumar ChAdd AM335X BeagleBone device tree source (am335x-evm.dts) file to use the am33xx.dtsi SoC file, along with the memory node information.
--- .../devicetree/bindings/arm/omap/omap.txt | 3 +++ arch/arm/boot/dts/am335x-bone.dts | 20 ++++++++++++++++++++ 2 files changed, 23 insertions(+) create mode 100644 arch/arm/boot/dts/am335x-bone.dts
Documentation/devicetree/bindings/arm/omap/omap.txt +3 -0
@@ -47,3 +47,6 @@ Boards: - AM335X EVM : Software Developement Board for AM335x compatible = "ti,am335x-evm", "ti,am33xx", "ti,omap3" + +- AM335X Bone : Low cost community board + compatible = "ti,am335x-bone", "ti,am33xx", "ti,omap3"
arch/arm/boot/dts/am335x-bone.dts new file +20 -0
@@ -0,0 +1,20 @@ +/* + * Copyright (C) 2012 Texas Instruments Incorporated - http://www.ti.com/ + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ +/dts-v1/; + +/include/ "am33xx.dtsi" + +/ { + model = "TI AM335x BeagleBone"; + compatible = "ti,am335x-bone", "ti,am33xx"; + + memory { + device_type = "memory"; + reg = <0x80000000 0x10000000>; /* 256 MB */ + }; +};
Signature · 1 line
1.7.9.5
cover Add device tree support to AM33XX SoC
In reply to AnilKumar ChHi,
Gentle remainder to this patch series.
Quoted 25 lines · Chimata
This patch series add device tree support for AM33XX SoC family.
Initialy Hiremath Vaibhav submitted a patch for AM33XX devices based on omap3 family. Details at
http://marc.info/?t=132687107200002&r=1&w=2AM33XX family is varied from omap3 family in these aspects like memory maps, peripheral base addresses and configuration parameters. In some cases we have to use a mix of omap3 and omap4 parameters. So a seperate
am33xx.dtsifile is created for all the devices comes under am33xx family and revert of above patch is required.Two sepearte device tree source files are created (
am335x-evm.dtsandam335x-bone.dts) to add support for AM335X EVM and BeagleBone boards.Linux booting is tested on AM335X-EVM and BeagleBone boards.
AnilKumar Ch (4):
Revert "arm/dts: Add support for TI AM335x EVM board" arm/dts: Add initial DT support for AM33XX SoC family arm/dts: Add support for AM335x EVM
arm/dts: Add support for AM335x BeagleBone
Quoted 10 lines
.../devicetree/bindings/arm/omap/omap.txt | 3 + arch/arm/boot/dts/am335x-bone.dts | 20 +++ arch/arm/boot/dts/am335x-evm.dts | 25 +-- arch/arm/boot/dts/am33xx.dtsi | 189 ++++++++++++++++++++ 4 files changed, 215 insertions(+), 22 deletions(-) create mode 100644 arch/arm/boot/dts/am335x-bone.dts create mode 100644 arch/arm/boot/dts/am33xx.dtsiSignature · 1 line
1.7.9.5
Thanks
AnilKumar