Skip to contentSkip to conversation

arm64: dts: imx8mp-dhcom-pdk3: Use symbolic macro for IOMUXC_SAI2_TXC__GPIO4_IO25

PATCH Applied Eduard Bostina 5 participants 5 messages Mar 9 – Mar 17

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 arm64: dts: imx8mp-dhcom-pdk3: Use symbolic macro for IOMUXC_SAI2_TXC__GPIO4_IO25

Currently, in order to configure IOMUXC_SAI2_TXC__GPIO4_IO25 a magic raw value is written in this register. This makes the code not obvious to read and modify.

Use the MX8MP_SION symbolic macro instead of the magic value to improve code readability.

---
 arch/arm64/boot/dts/freescale/imx8mp-dhcom-pdk3.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/freescale/imx8mp-dhcom-pdk3.dts +1 -1
index ef012e8365b1f..6ad824a7e07e0 100644
@@ -345,7 +345,7 @@ &pinctrl_dhcom_l
 
 	pinctrl_ptn5150: ptn5150grp {
 		fsl,pins = <
-			MX8MP_IOMUXC_SAI2_TXC__GPIO4_IO25		0x40000000
+			MX8MP_IOMUXC_SAI2_TXC__GPIO4_IO25		MX8MP_SION
 		>;
 	};
 };
Signature · 1 line
2.43.0
maintainer Applied
#2 lore raw
In reply to Eduard Bostina
Quoted 8 lines · Eduard Bostina

Currently, in order to configure IOMUXC_SAI2_TXC__GPIO4_IO25 a magic raw value is written in this register. This makes the code not obvious to read and modify.

Use the MX8MP_SION symbolic macro instead of the magic value to improve code readability.

[...]

Applied, thanks!

[1/1] arm64: dts: imx8mp-dhcom-pdk3: Use symbolic macro for IOMUXC_SAI2_TXC__GPIO4_IO25

      commit: 79ab6e297167b6eee7540af315bc5569e42182ee

Best regards,

Signature · 1 line
Frank Li <[email protected]>
#3 lore raw
In reply to Eduard Bostina
Quoted 17 lines · Eduard Bostina

Currently, in order to configure IOMUXC_SAI2_TXC__GPIO4_IO25 a magic raw value is written in this register. This makes the code not obvious to read and modify.

Use the MX8MP_SION symbolic macro instead of the magic value to improve code readability.

---
  arch/arm64/boot/dts/freescale/imx8mp-dhcom-pdk3.dts | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/freescale/imx8mp-dhcom-pdk3.dts +0 -0
index ef012e8365b1f..6ad824a7e07e0 100644

arch/arm64/boot/dts/freescale/imx8mp-dhcom-pdk3.dts &pinctrl_dhcom_l · line 348

Quoted 5 lines
arch/arm64/boot/dts/freescale/imx8mp-dhcom-pdk3.dts +1 -1
@@ -345,7 +345,7 @@ &pinctrl_dhcom_l
 
  	pinctrl_ptn5150: ptn5150grp {
  		fsl,pins = <
-			MX8MP_IOMUXC_SAI2_TXC__GPIO4_IO25		0x40000000
+			MX8MP_IOMUXC_SAI2_TXC__GPIO4_IO25		MX8MP_SION

Isn't the SION bit at the same bit offset at least since iMX5x ? Maybe the MX8MP_* prefix isn't necessary ?

#4 lore raw
Quoted 4 lines · Marek Vasut
Quoted 3 lines · Eduard Bostina

Currently, in order to configure IOMUXC_SAI2_TXC__GPIO4_IO25 a magic raw value is written in this register. This makes the code not obvious to read and modify.

[..]

Quoted 7 lines
Quoted 4 lines

      pinctrl_ptn5150: ptn5150grp {
              fsl,pins = <
-                     MX8MP_IOMUXC_SAI2_TXC__GPIO4_IO25               0x40000000 +                     MX8MP_IOMUXC_SAI2_TXC__GPIO4_IO25               MX8MP_SION

Isn't the SION bit at the same bit offset at least since iMX5x ? Maybe the MX8MP_* prefix isn't necessary ?

Hi Marek,

I think this can be factored out once we finish moving all the configs to symbolic macros.