diff mbox

[v2,1/2] dt-bindings: Add mtk-systimer bindings

Message ID 1530086039-3763-2-git-send-email-stanley.chu@mediatek.com (mailing list archive)
State New, archived
Headers show

Commit Message

Stanley Chu June 27, 2018, 7:53 a.m. UTC
Add binding documentation for the System Timer driver of
the Mediatek SoCs.

Signed-off-by: Stanley Chu <stanley.chu@mediatek.com>
---
 .../bindings/timer/mediatek,mtk-systimer.txt       |   18 ++++++++++++++++++
 1 file changed, 18 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/timer/mediatek,mtk-systimer.txt

Comments

Daniel Lezcano June 27, 2018, 8:20 a.m. UTC | #1
On 27/06/2018 09:53, Stanley Chu wrote:
> Add binding documentation for the System Timer driver of
> the Mediatek SoCs.
> 
> Signed-off-by: Stanley Chu <stanley.chu@mediatek.com>
> ---


>  .../bindings/timer/mediatek,mtk-systimer.txt       |   18 ++++++++++++++++++
>  1 file changed, 18 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/timer/mediatek,mtk-systimer.txt
> 
> diff --git a/Documentation/devicetree/bindings/timer/mediatek,mtk-systimer.txt b/Documentation/devicetree/bindings/timer/mediatek,mtk-systimer.txt
> new file mode 100644
> index 0000000..7a5bde6
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/timer/mediatek,mtk-systimer.txt
> @@ -0,0 +1,18 @@
> +Mediatek System Timers
> +----------------------
> +
> +Required properties:
> +- compatible: Should contain
> +	"mediatek,sys_timer" for those platforms which support system timer.
> +- reg: Should contain the location and length for system timer registers.
> +- clocks: System timer is drived by system clock.
> +
> +Examples:
> +
> +	sys_timer@10017000 {
> +		compatible = "mediatek,sys_timer";
> +		reg = <0 0x10017000 0 0x1000>;
> +		interrupts = <GIC_SPI 194 IRQ_TYPE_LEVEL_HIGH>;
> +		clocks = <&sys_clk>;
> +	};
> +

Actually this binding already exists for mediatek timers, it is useless
to add a new one.

I note the binding in

Documentation/devicetree/bindings/timer/mediatek,mtk-timer.txt

contains:

 clocks = <&system_clk>, <&rtc_clk>

However the existing driver does only use <&system_clk> AFAICT, I'm
questioning if <&rtc_clk> is really needed.

So, I suggest you sort out and fixup the rtc_clk thing (drop it) and
then just add your new platform in the list in this binding.
Stanley Chu June 28, 2018, 10:24 a.m. UTC | #2
On Wed, 2018-06-27 at 10:20 +0200, Daniel Lezcano wrote:
> Actually this binding already exists for mediatek timers, it is useless
> to add a new one.
> 
> I note the binding in
> 
> Documentation/devicetree/bindings/timer/mediatek,mtk-timer.txt
> 
> contains:
> 
>  clocks = <&system_clk>, <&rtc_clk>
> 
> However the existing driver does only use <&system_clk> AFAICT, I'm
> questioning if <&rtc_clk> is really needed.
> 
> So, I suggest you sort out and fixup the rtc_clk thing (drop it) and
> then just add your new platform in the list in this binding.
> 
> 
Hi Daniel,

OK! We'll fix it and merge two timers into single document file in v3.

Thanks.
Stanley Chu
diff mbox

Patch

diff --git a/Documentation/devicetree/bindings/timer/mediatek,mtk-systimer.txt b/Documentation/devicetree/bindings/timer/mediatek,mtk-systimer.txt
new file mode 100644
index 0000000..7a5bde6
--- /dev/null
+++ b/Documentation/devicetree/bindings/timer/mediatek,mtk-systimer.txt
@@ -0,0 +1,18 @@ 
+Mediatek System Timers
+----------------------
+
+Required properties:
+- compatible: Should contain
+	"mediatek,sys_timer" for those platforms which support system timer.
+- reg: Should contain the location and length for system timer registers.
+- clocks: System timer is drived by system clock.
+
+Examples:
+
+	sys_timer@10017000 {
+		compatible = "mediatek,sys_timer";
+		reg = <0 0x10017000 0 0x1000>;
+		interrupts = <GIC_SPI 194 IRQ_TYPE_LEVEL_HIGH>;
+		clocks = <&sys_clk>;
+	};
+