Skip to contentSkip to conversation

Add rtc PCF2131 support

PATCH Superseded Joy Zou 3 participants 8 messages Apr 17, 2024 – Apr 24, 2024

Subsystems (2)

v4 of 5 Superseded Latest is v5 →

lore
Share & tools
lore

Joy Zou

author
#0 lore raw

v4 cover Add rtc PCF2131 support

The patchset supports RTC PCF2131 on board dts. For the details, please check the patch commit log.

Joy Zou (1):
arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

 .../boot/dts/freescale/imx93-11x11-evk.dts    | 24 +++++++++++++++++++
 1 file changed, 24 insertions(+)
Signature · 1 line
2.37.1
author
#1 lore raw

PATCH v4 1/1 arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

Support rtc PCF2131 on imx93-11x11-evk.

---
Changes in v4:
1. remove the sleep from the pinctrl-names.

Changes in v3:
1.adjust the indentation.

Changes in v2:
1. remove unnecessary status property.

---
 .../boot/dts/freescale/imx93-11x11-evk.dts    | 24 +++++++++++++++++++
 1 file changed, 24 insertions(+)
arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts +24 -0
index 07e85a30a25f..bc3c9271d747 100644
@@ -281,6 +281,23 @@ ldo5: LDO5 {
 	};
 };
 
+&lpi2c3 {
+	#address-cells = <1>;
+	#size-cells = <0>;
+	clock-frequency = <400000>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_lpi2c3>;
+	pinctrl-1 = <&pinctrl_lpi2c3>;
+	status = "okay";
+
+	pcf2131: rtc@53 {
+		compatible = "nxp,pcf2131";
+		reg = <0x53>;
+		interrupt-parent = <&pcal6524>;
+		interrupts = <1 IRQ_TYPE_EDGE_FALLING>;
+	};
+};
+
 &iomuxc {
 	pinctrl_eqos: eqosgrp {
 		fsl,pins = <
@@ -343,6 +360,13 @@ MX93_PAD_I2C2_SDA__LPI2C2_SDA			0x40000b9e
 		>;
 	};
 
+	pinctrl_lpi2c3: lpi2c3grp {
+		fsl,pins = <
+			MX93_PAD_GPIO_IO28__LPI2C3_SDA			0x40000b9e
+			MX93_PAD_GPIO_IO29__LPI2C3_SCL			0x40000b9e
+		>;
+	};
+
 	pinctrl_pcal6524: pcal6524grp {
 		fsl,pins = <
 			MX93_PAD_CCM_CLKO2__GPIO3_IO27			0x31e
Signature · 1 line
2.37.1
reviewer
#2 lore raw

Re: [PATCH v4 1/1] arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

Quoted 2 lines · Joy Zou

Support rtc PCF2131 on imx93-11x11-evk.

s/rtc/RTC

arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts ldo5: LDO5 { · line 290

Quoted 7 lines

+&lpi2c3 {

arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts +6 -0
+       #address-cells = <1>;
+       #size-cells = <0>;
+       clock-frequency = <400000>;
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_lpi2c3>;
+       pinctrl-1 = <&pinctrl_lpi2c3>;

Why is the pinctrl-1 still here?

author
#3 lore raw

RE: [EXT] Re: [PATCH v4 1/1] arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

Quoted 17 lines

-----Original Message-----
From: Fabio Estevam <[email protected]>
Sent: 2024年4月17日 11:10
To: Joy Zou <[email protected]>
Cc: [email protected]; Frank Li <[email protected]>; Jacky Bai <[email protected]>; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; dl-linux-imx <[email protected]>; [email protected]; [email protected]; [email protected]; [email protected]
Subject: [EXT] Re: [PATCH v4 1/1] arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

Quoted 5 lines
Quoted 2 lines · Joy Zou

Support rtc PCF2131 on imx93-11x11-evk.

s/rtc/RTC

Thanks for your comments!
Will change the format in next version.

Quoted 10 lines

arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts ldo5: LDO5 { · line 290

Quoted 8 lines

+&lpi2c3 {

arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts +6 -0
+       #address-cells = <1>;
+       #size-cells = <0>;
+       clock-frequency = <400000>;
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_lpi2c3>;
+       pinctrl-1 = <&pinctrl_lpi2c3>;

Why is the pinctrl-1 still here?

Yeah, Sorry for forgetting to delete the pinctrl-1, will delete in next version.

BR
Joy Zou

#4 lore raw

Re: [PATCH v4 1/1] arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

In reply to Joy Zou

Hi Joy,

Quoted 21 lines · Joy Zou

Support rtc PCF2131 on imx93-11x11-evk.

---
Changes in v4:
1. remove the sleep from the pinctrl-names.

Changes in v3:
1.adjust the indentation.

Changes in v2:
1. remove unnecessary status property.

---
 .../boot/dts/freescale/imx93-11x11-evk.dts    | 24 +++++++++++++++++++
 1 file changed, 24 insertions(+)
arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts +0 -0
index 07e85a30a25f..bc3c9271d747 100644

arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts ldo5: LDO5 { · line 286

Quoted 6 lines
arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts +3 -0
@@ -281,6 +281,23 @@ ldo5: LDO5 {
 	};
 };
 
+&lpi2c3 {
+	#address-cells = <1>;
+	#size-cells = <0>;

while reading your patch I also noticed that you had to specify these cells here. It is very common to specify it within the base dtsi file imx93.dtsi. Can you please provde an extra patch which adds this to the base dtsi followed by this patch, which of course do need to specify it again.

Thanks you,
Marco

Quoted 35 lines
arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts +21 -0
+	clock-frequency = <400000>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_lpi2c3>;
+	pinctrl-1 = <&pinctrl_lpi2c3>;
+	status = "okay";
+
+	pcf2131: rtc@53 {
+		compatible = "nxp,pcf2131";
+		reg = <0x53>;
+		interrupt-parent = <&pcal6524>;
+		interrupts = <1 IRQ_TYPE_EDGE_FALLING>;
+	};
+};
+
 &iomuxc {
 	pinctrl_eqos: eqosgrp {
 		fsl,pins = <
@@ -343,6 +360,13 @@ MX93_PAD_I2C2_SDA__LPI2C2_SDA			0x40000b9e
 		>;
 	};
 
+	pinctrl_lpi2c3: lpi2c3grp {
+		fsl,pins = <
+			MX93_PAD_GPIO_IO28__LPI2C3_SDA			0x40000b9e
+			MX93_PAD_GPIO_IO29__LPI2C3_SCL			0x40000b9e
+		>;
+	};
+
 	pinctrl_pcal6524: pcal6524grp {
 		fsl,pins = <
 			MX93_PAD_CCM_CLKO2__GPIO3_IO27			0x31e
Signature · 1 line
2.37.1
author
#5 lore raw

RE: [EXT] Re: [PATCH v4 1/1] arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

Quoted 34 lines

-----Original Message-----
From: Marco Felsch <[email protected]>
Sent: 2024年4月17日 12:57
To: Joy Zou <[email protected]>
Cc: Frank Li <[email protected]>; Jacky Bai <[email protected]>; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; dl-linux-imx <[email protected]>; [email protected]; [email protected]; [email protected]; [email protected]
Subject: [EXT] Re: [PATCH v4 1/1] arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

Hi Joy,

arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts ldo5: LDO5 { · line 286

Quoted 12 lines
arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts +3 -0
index 07e85a30a25f..bc3c9271d747 100644
@@ -281,6 +281,23 @@ ldo5: LDO5 {
      };
 };
 
+&lpi2c3 {
+     #address-cells = <1>;
+     #size-cells = <0>;

while reading your patch I also noticed that you had to specify these cells here. It is very common to specify it within the base dtsi file imx93.dtsi. Can you please provde an extra patch which adds this to the base dtsi followed by this patch, which of course do need to specify it again.

Quoted 3 lines

Thanks you,
Marco

Thanks for your comments!
Have checked the base dtsi file imx93.dtsi. The these cells already existed. The current cells is same with the lpi2c3 node in imx93.dtsi. So should remove these cells in order to keep terse?
BR
Joy Zou

#6 lore raw

Re: [EXT] Re: [PATCH v4 1/1] arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

Quoted 34 lines · Joy Zou
Quoted 34 lines

-----Original Message-----
From: Marco Felsch <[email protected]>
Sent: 2024年4月17日 12:57
To: Joy Zou <[email protected]>
Cc: Frank Li <[email protected]>; Jacky Bai <[email protected]>; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; dl-linux-imx <[email protected]>; [email protected]; [email protected]; [email protected]; [email protected]
Subject: [EXT] Re: [PATCH v4 1/1] arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

Hi Joy,

arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts ldo5: LDO5 { · line 286

Quoted 12 lines
arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts +3 -0
index 07e85a30a25f..bc3c9271d747 100644
@@ -281,6 +281,23 @@ ldo5: LDO5 {
      };
 };
 
+&lpi2c3 {
+     #address-cells = <1>;
+     #size-cells = <0>;

while reading your patch I also noticed that you had to specify these cells here. It is very common to specify it within the base dtsi file imx93.dtsi. Can you please provde an extra patch which adds this to the base dtsi followed by this patch, which of course do need to specify it again.

Quoted 5 lines
Quoted 3 lines

Thanks you,
Marco

Thanks for your comments!
Have checked the base dtsi file imx93.dtsi. The these cells already existed.

You're right, not sure why I didn't saw it in the first place.

Quoted 2 lines

The current cells is same with the lpi2c3 node in imx93.dtsi. So should remove these cells in order to keep terse?

Yes please remove it.

Regards,
Marco

author
#7 lore raw

RE: Re: [PATCH v4 1/1] arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

Quoted 42 lines

-----Original Message-----
From: Marco Felsch <[email protected]>
Sent: 2024年4月24日 17:00
To: Joy Zou <[email protected]>
Cc: Frank Li <[email protected]>; Jacky Bai <[email protected]>; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; dl-linux-imx <[email protected]>; [email protected]; [email protected]; [email protected]; [email protected]
Subject: Re: Re: [PATCH v4 1/1] arm64: dts: imx93-11x11-evk: add rtc PCF2131 support

Quoted 9 lines · Joy Zou
Quoted 9 lines
Quoted 9 lines
arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts +0 -0
index 07e85a30a25f..bc3c9271d747 100644
@@ -281,6 +281,23 @@ ldo5: LDO5 {
      };
 };
 
Quoted 8 lines
Quoted 8 lines

arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts ldo5: LDO5 { · line 286

Quoted 3 lines
arch/arm64/boot/dts/freescale/imx93-11x11-evk.dts +3 -0
+&lpi2c3 {
+     #address-cells = <1>;
+     #size-cells = <0>;

while reading your patch I also noticed that you had to specify these cells here. It is very common to specify it within the base dtsi file imx93.dtsi. Can you please provde an extra patch which adds this to the base dtsi followed by this patch, which of course do need

to specify it again.

Quoted 6 lines
Quoted 4 lines

Thanks you,
Marco

Thanks for your comments!
Have checked the base dtsi file imx93.dtsi. The these cells already existed.

You're right, not sure why I didn't saw it in the first place.

Quoted 7 lines
Quoted 2 lines

The current cells is same with the lpi2c3 node in imx93.dtsi. So should remove these cells in order to keep terse?

Yes please remove it.

Regards,
Marco

Thanks for your comments!
Will change it in next version.
BR
Joy Zou