Commit 8e8fbab4 authored by Conor Dooley's avatar Conor Dooley Committed by Stephen Boyd

dt-bindings: rtc: add refclk to mpfs-rtc

The rtc on PolarFire SoC does not use the AHB clock as its reference
frequency, but rather a 1 MHz refclk that it shares with MTIMER. Add
this second clock to the binding as a required property.

Fixes: 4cbcc0d7 ("dt-bindings: rtc: add bindings for microchip mpfs rtc")
Reviewed-by: default avatarDaire McNamara <daire.mcnamara@microchip.com>
Acked-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: default avatarConor Dooley <conor.dooley@microchip.com>
Link: https://lore.kernel.org/r/20220413075835.3354193-7-conor.dooley@microchip.comAcked-by: default avatarPalmer Dabbelt <palmer@rivosinc.com>
Signed-off-by: default avatarStephen Boyd <sboyd@kernel.org>
parent 8be99c7b
...@@ -31,11 +31,19 @@ properties: ...@@ -31,11 +31,19 @@ properties:
to that of the RTC's count register. to that of the RTC's count register.
clocks: clocks:
maxItems: 1 items:
- description: |
AHB clock
- description: |
Reference clock: divided by the prescaler to create a time-based
strobe (typically 1 Hz) for the calendar counter. By default, the rtc
on the PolarFire SoC shares it's reference with MTIMER so this will
be a 1 MHz clock.
clock-names: clock-names:
items: items:
- const: rtc - const: rtc
- const: rtcref
required: required:
- compatible - compatible
...@@ -48,11 +56,12 @@ additionalProperties: false ...@@ -48,11 +56,12 @@ additionalProperties: false
examples: examples:
- | - |
#include "dt-bindings/clock/microchip,mpfs-clock.h"
rtc@20124000 { rtc@20124000 {
compatible = "microchip,mpfs-rtc"; compatible = "microchip,mpfs-rtc";
reg = <0x20124000 0x1000>; reg = <0x20124000 0x1000>;
clocks = <&clkcfg 21>; clocks = <&clkcfg CLK_RTC>, <&clkcfg CLK_RTCREF>;
clock-names = "rtc"; clock-names = "rtc", "rtcref";
interrupts = <80>, <81>; interrupts = <80>, <81>;
}; };
... ...
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment