ARM: dts: bcm5301x: Add TWD, I2C, and syscon
v2 cover ARM: dts: bcm5301x: Add TWD, I2C, and syscon
Reviving, correcting, and resending this patch series from December
http://lists.infradead.org/pipermail/linux-arm-kernel/2015-December/395155.html
In v2:
* Corrected TWD DT names, per Sergei Shtylyov
* Modified syscon size, per Arnd Bergmann (or atleast my rough understanding of what he was trying to say)
Jon Mason (3):
ARM: dts: bcm5301x: Add TWD WD Support to DT
ARM: dts: bcm5301x: Add I2C support to the DT
arm: dts: bcm5301x: Add syscon based reboot in DT
arch/arm/boot/dts/bcm5301x.dtsi | 36 +++++++++++++++++++++++++++++++++--- 1 file changed, 33 insertions(+), 3 deletions(-)
Signature · 1 line
1.9.1
PATCH v2 1/3 ARM: dts: bcm5301x: Add TWD WD Support to DT
Add support for the ARM TWD Watchdog to the bcm5301x device tree. The ARM TWD timer allocated the register space for the WDT, so this patch necessitated shrinking that. Also, the GIC masks were added for these.
--- arch/arm/boot/dts/bcm5301x.dtsi | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-)
arch/arm/boot/dts/bcm5301x.dtsi +12 -3
@@ -66,10 +66,19 @@ clocks = <&periph_clk>; }; - local-timer at 20600 { + timer at 20600 { compatible = "arm,cortex-a9-twd-timer"; - reg = <0x20600 0x100>; - interrupts = <GIC_PPI 13 IRQ_TYPE_LEVEL_HIGH>; + reg = <0x20600 0x20>; + interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(2) | + IRQ_TYPE_LEVEL_HIGH)>; + clocks = <&periph_clk>; + }; + + watchdog at 20620 { + compatible = "arm,cortex-a9-twd-wdt"; + reg = <0x20620 0x20>; + interrupts = <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(2) | + IRQ_TYPE_LEVEL_HIGH)>; clocks = <&periph_clk>; };
Signature · 1 line
1.9.1
PATCH v2 2/3 ARM: dts: bcm5301x: Add I2C support to the DT
In reply to Jon MasonAdd I2C support to the bcm5301x Device Tree. Since no driver changes are needed to enable this hardware, only the device tree changes are required to make this functional.
--- arch/arm/boot/dts/bcm5301x.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+)
arch/arm/boot/dts/bcm5301x.dtsi +9 -0
@@ -218,6 +218,15 @@ }; }; + i2c0: i2c at 18009000 { + compatible = "brcm,iproc-i2c"; + reg = <0x18009000 0x50>; + interrupts = <GIC_SPI 121 IRQ_TYPE_NONE>; + #address-cells = <1>; + #size-cells = <0>; + clock-frequency = <100000>; + }; + lcpll0: lcpll0 at 1800c100 { #clock-cells = <1>; compatible = "brcm,nsp-lcpll0";
Signature · 1 line
1.9.1
PATCH v2 3/3 arm: dts: bcm5301x: Add syscon based reboot in DT
In reply to Jon MasonAdd the ability to reboot via a reset of the processor. This is achieved via a write of 0x39 to the CRU Reset Register. Unfortunately, this only resets the core and not the other IP blocks. So if possible, other methods should be used on the individual boards.
--- arch/arm/boot/dts/bcm5301x.dtsi | 12 ++++++++++++ 1 file changed, 12 insertions(+)
arch/arm/boot/dts/bcm5301x.dtsi +12 -0
@@ -246,6 +246,18 @@ "sata2"; }; + cru: cru at 1800c184 { + compatible = "syscon"; + reg = <0x1800c184 0x4>; + }; + + reboot at 1800c184 { + compatible ="syscon-reboot"; + regmap = <&cru>; + offset = <0>; + mask = <0x39>; + }; + nand: nand at 18028000 { compatible = "brcm,nand-iproc", "brcm,brcmnand-v6.1", "brcm,brcmnand"; reg = <0x18028000 0x600>, <0x1811a408 0x600>, <0x18028f00 0x20>;
Signature · 1 line
1.9.1