linux-rtc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] rtc: add amlogic C3 RTC node
@ 2025-07-17  9:38 Xianwei Zhao via B4 Relay
  2025-07-17  9:38 ` [PATCH 1/2] dt-bindings: rtc: amlogic,a4-rtc: Add compatible string for C3 Xianwei Zhao via B4 Relay
  2025-07-17  9:38 ` [PATCH 2/2] arm64: dts: amlogic: C3: Add RTC controller node Xianwei Zhao via B4 Relay
  0 siblings, 2 replies; 6+ messages in thread
From: Xianwei Zhao via B4 Relay @ 2025-07-17  9:38 UTC (permalink / raw)
  To: Yiting Deng, Alexandre Belloni, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Neil Armstrong, Kevin Hilman, Jerome Brunet,
	Martin Blumenstingl
  Cc: linux-amlogic, linux-rtc, devicetree, linux-kernel,
	linux-arm-kernel, Xianwei Zhao

Add C3 rtc compatible string and device node.

Signed-off-by: Xianwei Zhao <xianwei.zhao@amlogic.com>
---
Xianwei Zhao (2):
      dt-bindings: rtc: amlogic,a4-rtc: Add compatible string for C3
      arm64: dts: amlogic: C3: Add RTC controller node

 .../devicetree/bindings/rtc/amlogic,a4-rtc.yaml          | 11 ++++++++---
 arch/arm64/boot/dts/amlogic/amlogic-c3.dtsi              | 16 ++++++++++++++++
 2 files changed, 24 insertions(+), 3 deletions(-)
---
base-commit: 0bafe291cb429d39b5ff70bcf7b2f3ab026dcb02
change-id: 20250717-rtc-c3-node-bb78598d91b3

Best regards,
-- 
Xianwei Zhao <xianwei.zhao@amlogic.com>



^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH 1/2] dt-bindings: rtc: amlogic,a4-rtc: Add compatible string for C3
  2025-07-17  9:38 [PATCH 0/2] rtc: add amlogic C3 RTC node Xianwei Zhao via B4 Relay
@ 2025-07-17  9:38 ` Xianwei Zhao via B4 Relay
  2025-07-20 23:30   ` Rob Herring (Arm)
  2025-07-23 21:44   ` (subset) " Alexandre Belloni
  2025-07-17  9:38 ` [PATCH 2/2] arm64: dts: amlogic: C3: Add RTC controller node Xianwei Zhao via B4 Relay
  1 sibling, 2 replies; 6+ messages in thread
From: Xianwei Zhao via B4 Relay @ 2025-07-17  9:38 UTC (permalink / raw)
  To: Yiting Deng, Alexandre Belloni, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Neil Armstrong, Kevin Hilman, Jerome Brunet,
	Martin Blumenstingl
  Cc: linux-amlogic, linux-rtc, devicetree, linux-kernel,
	linux-arm-kernel, Xianwei Zhao

From: Xianwei Zhao <xianwei.zhao@amlogic.com>

Amlogic C3 SoCs uses the same rtc controller as A5 SoCs. There is
no need for an extra compatible line in the driver, but add C3
compatible line for documentation.

Signed-off-by: Xianwei Zhao <xianwei.zhao@amlogic.com>
---
 Documentation/devicetree/bindings/rtc/amlogic,a4-rtc.yaml | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/Documentation/devicetree/bindings/rtc/amlogic,a4-rtc.yaml b/Documentation/devicetree/bindings/rtc/amlogic,a4-rtc.yaml
index 5d3ac737abcb..e61f22eca85b 100644
--- a/Documentation/devicetree/bindings/rtc/amlogic,a4-rtc.yaml
+++ b/Documentation/devicetree/bindings/rtc/amlogic,a4-rtc.yaml
@@ -16,9 +16,14 @@ allOf:
 
 properties:
   compatible:
-    enum:
-      - amlogic,a4-rtc
-      - amlogic,a5-rtc
+    oneOf:
+      - enum:
+          - amlogic,a4-rtc
+          - amlogic,a5-rtc
+      - items:
+          - enum:
+              - amlogic,c3-rtc
+          - const: amlogic,a5-rtc
 
   reg:
     maxItems: 1

-- 
2.37.1



^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 2/2] arm64: dts: amlogic: C3: Add RTC controller node
  2025-07-17  9:38 [PATCH 0/2] rtc: add amlogic C3 RTC node Xianwei Zhao via B4 Relay
  2025-07-17  9:38 ` [PATCH 1/2] dt-bindings: rtc: amlogic,a4-rtc: Add compatible string for C3 Xianwei Zhao via B4 Relay
@ 2025-07-17  9:38 ` Xianwei Zhao via B4 Relay
  2025-07-22 10:05   ` Neil Armstrong
  1 sibling, 1 reply; 6+ messages in thread
From: Xianwei Zhao via B4 Relay @ 2025-07-17  9:38 UTC (permalink / raw)
  To: Yiting Deng, Alexandre Belloni, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Neil Armstrong, Kevin Hilman, Jerome Brunet,
	Martin Blumenstingl
  Cc: linux-amlogic, linux-rtc, devicetree, linux-kernel,
	linux-arm-kernel, Xianwei Zhao

From: Xianwei Zhao <xianwei.zhao@amlogic.com>

Add the RTC controller node for C3 SoC family.

Signed-off-by: Xianwei Zhao <xianwei.zhao@amlogic.com>
---
 arch/arm64/boot/dts/amlogic/amlogic-c3.dtsi | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/arch/arm64/boot/dts/amlogic/amlogic-c3.dtsi b/arch/arm64/boot/dts/amlogic/amlogic-c3.dtsi
index cb9ea3ca6ee0..b81bffac7732 100644
--- a/arch/arm64/boot/dts/amlogic/amlogic-c3.dtsi
+++ b/arch/arm64/boot/dts/amlogic/amlogic-c3.dtsi
@@ -53,6 +53,13 @@ xtal: xtal-clk {
 		#clock-cells = <0>;
 	};
 
+	xtal_32k: xtal-clk-32k {
+		compatible = "fixed-clock";
+		clock-frequency = <32768>;
+		clock-output-names = "xtal_32k";
+		#clock-cells = <0>;
+	};
+
 	sm: secure-monitor {
 		compatible = "amlogic,meson-gxbb-sm";
 
@@ -967,6 +974,15 @@ nand: nand-controller@8d000 {
 				clock-names = "core", "device";
 				status = "disabled";
 			};
+
+			rtc@9a000 {
+				compatible = "amlogic,c3-rtc",
+					     "amlogic,a5-rtc";
+				reg = <0x0 0x9a000 0x0 0x38>;
+				interrupts = <GIC_SPI 131 IRQ_TYPE_EDGE_RISING>;
+				clocks = <&xtal_32k>, <&clkc_periphs CLKID_SYS_RTC>;
+				clock-names = "osc", "sys";
+			};
 		};
 
 		ethmac: ethernet@fdc00000 {

-- 
2.37.1



^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/2] dt-bindings: rtc: amlogic,a4-rtc: Add compatible string for C3
  2025-07-17  9:38 ` [PATCH 1/2] dt-bindings: rtc: amlogic,a4-rtc: Add compatible string for C3 Xianwei Zhao via B4 Relay
@ 2025-07-20 23:30   ` Rob Herring (Arm)
  2025-07-23 21:44   ` (subset) " Alexandre Belloni
  1 sibling, 0 replies; 6+ messages in thread
From: Rob Herring (Arm) @ 2025-07-20 23:30 UTC (permalink / raw)
  To: Xianwei Zhao
  Cc: linux-kernel, devicetree, Kevin Hilman, Yiting Deng,
	Alexandre Belloni, Neil Armstrong, linux-amlogic, Jerome Brunet,
	linux-rtc, Krzysztof Kozlowski, linux-arm-kernel,
	Martin Blumenstingl, Conor Dooley


On Thu, 17 Jul 2025 17:38:37 +0800, Xianwei Zhao wrote:
> Amlogic C3 SoCs uses the same rtc controller as A5 SoCs. There is
> no need for an extra compatible line in the driver, but add C3
> compatible line for documentation.
> 
> Signed-off-by: Xianwei Zhao <xianwei.zhao@amlogic.com>
> ---
>  Documentation/devicetree/bindings/rtc/amlogic,a4-rtc.yaml | 11 ++++++++---
>  1 file changed, 8 insertions(+), 3 deletions(-)
> 

Reviewed-by: Rob Herring (Arm) <robh@kernel.org>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 2/2] arm64: dts: amlogic: C3: Add RTC controller node
  2025-07-17  9:38 ` [PATCH 2/2] arm64: dts: amlogic: C3: Add RTC controller node Xianwei Zhao via B4 Relay
@ 2025-07-22 10:05   ` Neil Armstrong
  0 siblings, 0 replies; 6+ messages in thread
From: Neil Armstrong @ 2025-07-22 10:05 UTC (permalink / raw)
  To: xianwei.zhao, Yiting Deng, Alexandre Belloni, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Kevin Hilman, Jerome Brunet,
	Martin Blumenstingl
  Cc: linux-amlogic, linux-rtc, devicetree, linux-kernel,
	linux-arm-kernel

On 17/07/2025 11:38, Xianwei Zhao via B4 Relay wrote:
> From: Xianwei Zhao <xianwei.zhao@amlogic.com>
> 
> Add the RTC controller node for C3 SoC family.
> 
> Signed-off-by: Xianwei Zhao <xianwei.zhao@amlogic.com>
> ---
>   arch/arm64/boot/dts/amlogic/amlogic-c3.dtsi | 16 ++++++++++++++++
>   1 file changed, 16 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/amlogic/amlogic-c3.dtsi b/arch/arm64/boot/dts/amlogic/amlogic-c3.dtsi
> index cb9ea3ca6ee0..b81bffac7732 100644
> --- a/arch/arm64/boot/dts/amlogic/amlogic-c3.dtsi
> +++ b/arch/arm64/boot/dts/amlogic/amlogic-c3.dtsi
> @@ -53,6 +53,13 @@ xtal: xtal-clk {
>   		#clock-cells = <0>;
>   	};
>   
> +	xtal_32k: xtal-clk-32k {
> +		compatible = "fixed-clock";
> +		clock-frequency = <32768>;
> +		clock-output-names = "xtal_32k";
> +		#clock-cells = <0>;
> +	};
> +
>   	sm: secure-monitor {
>   		compatible = "amlogic,meson-gxbb-sm";
>   
> @@ -967,6 +974,15 @@ nand: nand-controller@8d000 {
>   				clock-names = "core", "device";
>   				status = "disabled";
>   			};
> +
> +			rtc@9a000 {
> +				compatible = "amlogic,c3-rtc",
> +					     "amlogic,a5-rtc";
> +				reg = <0x0 0x9a000 0x0 0x38>;
> +				interrupts = <GIC_SPI 131 IRQ_TYPE_EDGE_RISING>;
> +				clocks = <&xtal_32k>, <&clkc_periphs CLKID_SYS_RTC>;
> +				clock-names = "osc", "sys";
> +			};
>   		};
>   
>   		ethmac: ethernet@fdc00000 {
> 

Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: (subset) [PATCH 1/2] dt-bindings: rtc: amlogic,a4-rtc: Add compatible string for C3
  2025-07-17  9:38 ` [PATCH 1/2] dt-bindings: rtc: amlogic,a4-rtc: Add compatible string for C3 Xianwei Zhao via B4 Relay
  2025-07-20 23:30   ` Rob Herring (Arm)
@ 2025-07-23 21:44   ` Alexandre Belloni
  1 sibling, 0 replies; 6+ messages in thread
From: Alexandre Belloni @ 2025-07-23 21:44 UTC (permalink / raw)
  To: Yiting Deng, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Neil Armstrong, Kevin Hilman, Jerome Brunet, Martin Blumenstingl,
	Xianwei Zhao
  Cc: linux-amlogic, linux-rtc, devicetree, linux-kernel,
	linux-arm-kernel

On Thu, 17 Jul 2025 17:38:37 +0800, Xianwei Zhao wrote:
> Amlogic C3 SoCs uses the same rtc controller as A5 SoCs. There is
> no need for an extra compatible line in the driver, but add C3
> compatible line for documentation.
> 
> 

Applied, thanks!

[1/2] dt-bindings: rtc: amlogic,a4-rtc: Add compatible string for C3
      https://git.kernel.org/abelloni/c/db22fd8880a2

Best regards,

-- 
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2025-07-23 21:44 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-17  9:38 [PATCH 0/2] rtc: add amlogic C3 RTC node Xianwei Zhao via B4 Relay
2025-07-17  9:38 ` [PATCH 1/2] dt-bindings: rtc: amlogic,a4-rtc: Add compatible string for C3 Xianwei Zhao via B4 Relay
2025-07-20 23:30   ` Rob Herring (Arm)
2025-07-23 21:44   ` (subset) " Alexandre Belloni
2025-07-17  9:38 ` [PATCH 2/2] arm64: dts: amlogic: C3: Add RTC controller node Xianwei Zhao via B4 Relay
2025-07-22 10:05   ` Neil Armstrong

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).