add RTC support for Armada 370 and Armada XP
Subsystems (2)
cover add RTC support for Armada 370 and Armada XP
Hello Jason,
This small patchset adds RTC support for Armada 370 and Armada XP. It was succesfully tested on the evaluation board. The second patch add the lacking documentation for the device tree binding. This serie is 3.9 material.
Thanks,
Gregory CLEMENT (2):
arm: mvebu: add RTC support for Armada 370 and Armada XP
rtc: rtc-mv: Add the device tree binding documentation
.../devicetree/bindings/rtc/orion-rtc.txt | 18 ++++++++++++++++++ arch/arm/boot/dts/armada-370-xp.dtsi | 6 ++++++ drivers/rtc/Kconfig | 2 +- 3 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 Documentation/devicetree/bindings/rtc/orion-rtc.txt
Signature · 1 line
1.7.9.5
PATCH 1/2 arm: mvebu: add RTC support for Armada 370 and Armada XP
The Armada 370 and Armada XP Socs have the same controller that the one used in the orion platforms. This patch enables the selection of rtc-mv with mvebu platform, and updates the device tree for these SoCs.
--- arch/arm/boot/dts/armada-370-xp.dtsi | 6 ++++++ drivers/rtc/Kconfig | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-)
arch/arm/boot/dts/armada-370-xp.dtsi +6 -0
@@ -129,6 +129,12 @@ clocks = <&coreclk 0>; status = "disabled"; }; + + rtc at 10300 { + compatible = "marvell,orion-rtc"; + reg = <0xd0010300 0x20>; + interrupts = <50>; + }; }; };
drivers/rtc/Kconfig +1 -1
@@ -994,7 +994,7 @@ config RTC_DRV_TX4939 config RTC_DRV_MV tristate "Marvell SoC RTC" - depends on ARCH_KIRKWOOD || ARCH_DOVE + depends on ARCH_KIRKWOOD || ARCH_DOVE || ARCH_MVEBU help If you say yes here you will get support for the in-chip RTC that can be found in some of Marvell's SoC devices, such as
Signature · 1 line
1.7.9.5
PATCH 1/2 arm: mvebu: add RTC support for Armada 370 and Armada XP
Dear Gregory CLEMENT,
arch/arm/boot/dts/armada-370-xp.dtsi line 137
Quoted 5 lines · Gregory CLEMENT
arch/arm/boot/dts/armada-370-xp.dtsi +5
-0+ rtc at 10300 { + compatible = "marvell,orion-rtc"; + reg = <0xd0010300 0x20>; + interrupts = <50>; + };
Maybe an explicit status = "okay" here?
Thomas
Signature · 4 lines
Thomas Petazzoni, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com
PATCH 1/2 arm: mvebu: add RTC support for Armada 370 and Armada XP
Quoted 11 lines · Thomas Petazzoni
Dear Gregory CLEMENT,
arch/arm/boot/dts/armada-370-xp.dtsi line 137
Quoted 5 lines · Gregory CLEMENT
arch/arm/boot/dts/armada-370-xp.dtsi +5
-0+ rtc at 10300 { + compatible = "marvell,orion-rtc"; + reg = <0xd0010300 0x20>; + interrupts = <50>; + };Maybe an explicit status = "okay" here?
Only necessary if it is typical for the device to get disabled. I don't add status="okay" properties unless it is to enable a device previously disabled with status="disabled"
g.
PATCH 1/2 arm: mvebu: add RTC support for Armada 370 and Armada XP
Dear Grant Likely,
Quoted 5 lines · Grant Likely
Quoted 1 line
Maybe an explicit status = "okay" here?
Only necessary if it is typical for the device to get disabled. I don't add status="okay" properties unless it is to enable a device previously disabled with status="disabled"
Ok, thanks for clarifying what the best practice is. This device being internal to the SoC and having no dependency on external components, it is indeed always available.
Thanks again for the clarification!
Thomas
Signature · 4 lines
Thomas Petazzoni, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com
PATCH 1/2 arm: mvebu: add RTC support for Armada 370 and Armada XP
Quoted 6 lines · Thomas Petazzoni
Dear Grant Likely,
Quoted 2 lines · Grant Likely
Quoted 1 line
Maybe an explicit status = "okay" here?
Quoted 7 lines
Quoted 3 lines
Only necessary if it is typical for the device to get disabled. I don't add status="okay" properties unless it is to enable a device previously disabled with status="disabled"
Ok, thanks for clarifying what the best practice is. This device being internal to the SoC and having no dependency on external components, it is indeed always available.
Hi Thomas
This is not actually true. Its dependent on at least one external component, a battery. The driver determines at load time if the clock is ticking.
There are a few Kirkwood and XP designs which use an external i2c RTC, because the battery recommended by Marvell is mechanically not so easy to attached to the board, in a robust way.
So i expect some boards will disable this from there own .dts file. However, defaulting to enabled would make sense.
Andrew
PATCH 1/2 arm: mvebu: add RTC support for Armada 370 and Armada XP
Dear Andrew Lunn,
Quoted 10 lines · Andrew Lunn
This is not actually true. Its dependent on at least one external component, a battery. The driver determines at load time if the clock is ticking.
There are a few Kirkwood and XP designs which use an external i2c RTC, because the battery recommended by Marvell is mechanically not so easy to attached to the board, in a robust way.
So i expect some boards will disable this from there own .dts file. However, defaulting to enabled would make sense.
Ok, thanks for the clarification!
Indeed, the OpenBlocks for example has a RTC on I2C, so maybe it'll want to disable the on-SoC RTC.
Best regards,
Thomas
Signature · 4 lines
Thomas Petazzoni, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com
PATCH 2/2 rtc: rtc-mv: Add the device tree binding documentation
In reply to Gregory CLEMENTThe support was already written, but the binding documentation was lacking.
--- .../devicetree/bindings/rtc/orion-rtc.txt | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 Documentation/devicetree/bindings/rtc/orion-rtc.txt
Documentation/devicetree/bindings/rtc/orion-rtc.txt new file +18 -0
@@ -0,0 +1,18 @@ +* Mvebu Real Time Clock + +RTC controller for the Kirkwood, the Dove, the Armada 370 and the +Armada XP SoCs + +Required properties: +- compatible : Should be "marvell,orion-rtc" +- reg: physical base address of the controller and length of memory mapped + region. +- interrupts: IRQ line for the RTC. + +Example: + +rtc at 10300 { + compatible = "marvell,orion-rtc"; + reg = <0xd0010300 0x20>; + interrupts = <50>; +};
Signature · 1 line
1.7.9.5
PATCH 2/2 rtc: rtc-mv: Add the device tree binding documentation
Quoted 2 lines · Gregory CLEMENT
The support was already written, but the binding documentation was lacking.
Thanks for doing this, Gregory. I missed this the first time around when we added the DT bindings to the rtc driver.
thx,
Jason.
Quoted 34 lines
Signed-off-by Gregory CLEMENT <[email protected]>--- .../devicetree/bindings/rtc/orion-rtc.txt | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 Documentation/devicetree/bindings/rtc/orion-rtc.txtDocumentation/devicetree/bindings/rtc/orion-rtc.txt new file +18
-0@@ -0,0 +1,18 @@ +* Mvebu Real Time Clock + +RTC controller for the Kirkwood, the Dove, the Armada 370 and the +Armada XP SoCs + +Required properties: +- compatible : Should be "marvell,orion-rtc" +- reg: physical base address of the controller and length of memory mapped + region. +- interrupts: IRQ line for the RTC. + +Example: + +rtc at 10300 { + compatible = "marvell,orion-rtc"; + reg = <0xd0010300 0x20>; + interrupts = <50>; +};Signature · 1 line
1.7.9.5
PATCH 2/2 rtc: rtc-mv: Add the device tree binding documentation
Quoted 8 lines · Jason Cooper
Quoted 2 lines · Gregory CLEMENT
The support was already written, but the binding documentation was lacking.
Thanks for doing this, Gregory. I missed this the first time around when we added the DT bindings to the rtc driver.
thx,
Applied the documentation patch, thanks. The code patch should go through the rtc tree.
g.
Quoted 42 lines
Jason.
Quoted 34 lines
Signed-off-by Gregory CLEMENT <[email protected]>--- .../devicetree/bindings/rtc/orion-rtc.txt | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 Documentation/devicetree/bindings/rtc/orion-rtc.txtDocumentation/devicetree/bindings/rtc/orion-rtc.txt new file +18
-0@@ -0,0 +1,18 @@ +* Mvebu Real Time Clock + +RTC controller for the Kirkwood, the Dove, the Armada 370 and the +Armada XP SoCs + +Required properties: +- compatible : Should be "marvell,orion-rtc" +- reg: physical base address of the controller and length of memory mapped + region. +- interrupts: IRQ line for the RTC. + +Example: + +rtc at 10300 { + compatible = "marvell,orion-rtc"; + reg = <0xd0010300 0x20>; + interrupts = <50>; +};Signature · 1 line
1.7.9.5_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel at lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Signature · 2 lines
Grant Likely, B.Sc, P.Eng. Secret Lab Technologies, Ltd.
cover add RTC support for Armada 370 and Armada XP
In reply to Gregory CLEMENTQuoted 6 lines · Gregory CLEMENT
Hello Jason,
This small patchset adds RTC support for Armada 370 and Armada XP. It was succesfully tested on the evaluation board. The second patch add the lacking documentation for the device tree binding. This serie is 3.9 material.
Andrew
Quoted 17 lines
Thanks,
Gregory CLEMENT (2):
arm: mvebu: add RTC support for Armada 370 and Armada XP
rtc: rtc-mv: Add the device tree binding documentation.../devicetree/bindings/rtc/orion-rtc.txt | 18 ++++++++++++++++++ arch/arm/boot/dts/armada-370-xp.dtsi | 6 ++++++ drivers/rtc/Kconfig | 2 +- 3 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 Documentation/devicetree/bindings/rtc/orion-rtc.txtSignature · 1 line
1.7.9.5
cover add RTC support for Armada 370 and Armada XP
In reply to Gregory CLEMENTDear Gregory CLEMENT,
Quoted 11 lines · Gregory CLEMENT
This small patchset adds RTC support for Armada 370 and Armada XP. It was succesfully tested on the evaluation board. The second patch add the lacking documentation for the device tree binding. This serie is 3.9 material.
Thanks,
Gregory CLEMENT (2):
arm: mvebu: add RTC support for Armada 370 and Armada XP
rtc: rtc-mv: Add the device tree binding documentation
Would you mind adding a patch that updates the mvebu_defconfig to include the RTC driver by default?
Thanks!
Thomas
Signature · 4 lines
Thomas Petazzoni, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com
cover add RTC support for Armada 370 and Armada XP
Quoted 12 lines · Thomas Petazzoni
Dear Gregory CLEMENT,
Quoted 8 lines · Gregory CLEMENT
This small patchset adds RTC support for Armada 370 and Armada XP. It was succesfully tested on the evaluation board. The second patch add the lacking documentation for the device tree binding. This serie is 3.9 material.
Thanks,
Quoted 6 lines
Quoted 3 lines
Gregory CLEMENT (2):
arm: mvebu: add RTC support for Armada 370 and Armada XP
rtc: rtc-mv: Add the device tree binding documentationWould you mind adding a patch that updates the
mvebu_defconfigto include the RTC driver by default?
Sure. I will.
Quoted 5 lines
Thanks!
Thomas
Signature · 4 lines
Gregory Clement, Free Electrons Kernel, drivers, real-time and embedded Linux development, consulting, training and support. http://free-electrons.com