Skip to contentSkip to conversation

arm64: dts: imx8mm: Deduplicate PCIe clock-names property

PATCH Applied Marek Vasut 3 participants 7 messages Jan 16, 2023 – Jan 26, 2023

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

PATCH v3 1/2 arm64: dts: imx8mm: Deduplicate PCIe clock-names property

Move the PCIe clock-names property from various DTs into SoC dtsi to reduce duplication. In case of a couple of boards, reorder the clock so they match the order in yaml DT bindings.

---
Cc: Fabio Estevam <[email protected]>
Cc: Peng Fan <[email protected]>
Cc: Richard Zhu <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: NXP Linux Team <[email protected]>
To: [email protected]
---
V2: - Add RB from Alex
- Fix venice build
- Add default pcie clock entry into dtsi
V3: - Drop clocks altogether from imx8mm-innocomm-wb15.dtsi imx8mm-phyboard-polis-rdk.dts imx8mm-verdin.dtsi
as they are identical to imx8mm.dtsi

---
 arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi  | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc.dts | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-evk.dtsi               | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-innocomm-wb15.dtsi     | 3 ---
 arch/arm64/boot/dts/freescale/imx8mm-phyboard-polis-rdk.dts | 3 ---
 arch/arm64/boot/dts/freescale/imx8mm-tqma8mqml-mba8mx.dts   | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw71xx.dtsi     | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw72xx.dtsi     | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw73xx.dtsi     | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw7901.dts      | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw7902.dts      | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw7903.dts      | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw7904.dts      | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi            | 4 ----
 arch/arm64/boot/dts/freescale/imx8mm.dtsi                   | 4 ++++
 15 files changed, 26 insertions(+), 43 deletions(-)
arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi +2 -3
index 169f047fbca50..bc531175ff765 100644
@@ -241,9 +241,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 21 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk_gated>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk_gated>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc.dts +2 -3
index 9889319d4f045..b1f2beb40a98f 100644
@@ -905,9 +905,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio1 5 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcieclk 0>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcieclk 0>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-evk.dtsi +2 -3
index e0b604ac0da4f..0ce3005d578d2 100644
@@ -360,9 +360,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 21 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-innocomm-wb15.dtsi +0 -3
index 44e87b1568e79..299752aa82772 100644
@@ -210,9 +210,6 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio5 21 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_PHY>,
-		 <&clk IMX8MM_CLK_PCIE1_AUX>;
-	clock-names = "pcie", "pcie_bus", "pcie_aux";
 	fsl,max-link-speed = <1>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>, <&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-phyboard-polis-rdk.dts +0 -3
index 4a3df2b77b0be..266129b4a70d9 100644
@@ -175,9 +175,6 @@ &pcie0 {
 	assigned-clock-parents = <&clk IMX8MM_SYS_PLL2_50M>,
 				 <&clk IMX8MM_SYS_PLL2_250M>;
 	assigned-clock-rates = <10000000>, <250000000>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&clk IMX8MM_CLK_PCIE1_PHY>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie>;
 	reset-gpio = <&gpio4 9 GPIO_ACTIVE_LOW>;
arch/arm64/boot/dts/freescale/imx8mm-tqma8mqml-mba8mx.dts +2 -3
index a0aeac6199299..156d793a0c972 100644
@@ -79,9 +79,8 @@ &pcie_phy {
 
 &pcie0 {
 	reset-gpio = <&expander0 14 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		<&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 				<&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-venice-gw71xx.dtsi +2 -3
index c557dbf4dcd60..0ce60ad9c7d50 100644
@@ -120,9 +120,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 6 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-venice-gw72xx.dtsi +2 -3
index 41d0de6a7027b..570992a52b759 100644
@@ -142,9 +142,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 6 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-venice-gw73xx.dtsi +2 -3
index 7761d5671cb13..1800c6a4b1fc6 100644
@@ -162,9 +162,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 6 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-venice-gw7901.dts +2 -3
index 64b366e83fa14..df3b2c93d2d58 100644
@@ -702,9 +702,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio5 2 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-venice-gw7902.dts +2 -3
index e8bc1fccc47be..c33ec6826d324 100644
@@ -623,9 +623,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 5 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-venice-gw7903.dts +2 -3
index acc2ba8e00a88..363020a08c9b8 100644
@@ -557,9 +557,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio5 11 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-venice-gw7904.dts +2 -3
index eceed9816f5dc..93088fa1c3b9c 100644
@@ -618,9 +618,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio5 11 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;
 	assigned-clock-rates = <10000000>, <250000000>;
arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi +0 -4
index 7e8b3b0fa3066..5b2493bb8dd93 100644
@@ -657,10 +657,6 @@ &pcie0 {
 	assigned-clock-parents = <&clk IMX8MM_SYS_PLL2_50M>,
 				 <&clk IMX8MM_SYS_PLL2_250M>;
 	assigned-clock-rates = <10000000>, <250000000>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>,
-		 <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&clk IMX8MM_CLK_PCIE1_PHY>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	/* PCIE_1_RESET# (SODIMM 244) */
arch/arm64/boot/dts/freescale/imx8mm.dtsi +4 -0
index 04cf2c3c9928b..31f4548f85cfa 100644
@@ -1302,6 +1302,10 @@ pcie0: pcie@33800000 {
 					<0 0 0 4 &gic GIC_SPI 122 IRQ_TYPE_LEVEL_HIGH>;
 			fsl,max-link-speed = <2>;
 			linux,pci-domain = <0>;
+			clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>,
+				 <&clk IMX8MM_CLK_PCIE1_PHY>,
+				 <&clk IMX8MM_CLK_PCIE1_AUX>;
+			clock-names = "pcie", "pcie_bus", "pcie_aux";
 			power-domains = <&pgc_pcie>;
 			resets = <&src IMX8MQ_RESET_PCIE_CTRL_APPS_EN>,
 				 <&src IMX8MQ_RESET_PCIE_CTRL_APPS_TURNOFF>;
Signature · 7 lines
2.39.0


_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
#1 lore raw

PATCH v3 2/2 arm64: dts: imx8mq: Deduplicate PCIe clock-names property

Move the PCIe clock-names property from various DTs into SoC dtsi to reduce duplication. In case of a couple of boards, reorder the clock so they match the order in yaml DT bindings.

---
Cc: Fabio Estevam <[email protected]>
Cc: Peng Fan <[email protected]>
Cc: Richard Zhu <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: NXP Linux Team <[email protected]>
To: [email protected]
---
V2: - Add RB from Alex
- Add default pcie clock entry into dtsi
- Fix the Ultra board
V3: Rebase on latest next-20230116

---
 arch/arm64/boot/dts/freescale/imx8mq-evk.dts           | 10 ++++------
 .../boot/dts/freescale/imx8mq-kontron-pitx-imx8m.dts   | 10 ++++------
 arch/arm64/boot/dts/freescale/imx8mq-mnt-reform2.dts   |  5 ++---
 .../arm64/boot/dts/freescale/imx8mq-tqma8mq-mba8mx.dts | 10 ++++------
 arch/arm64/boot/dts/freescale/imx8mq-zii-ultra.dtsi    | 10 ++++------
 arch/arm64/boot/dts/freescale/imx8mq.dtsi              | 10 ++++++++++
 6 files changed, 28 insertions(+), 27 deletions(-)
arch/arm64/boot/dts/freescale/imx8mq-evk.dts +4 -6
index 78937910f4039..7507548cdb16b 100644
@@ -356,10 +356,9 @@ &pcie0 {
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio5 28 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE1_AUX>,
+		 <&pcie0_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE1_PHY>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE1_AUX>;
 	vph-supply = <&vgen5_reg>;
 	status = "okay";
 };
@@ -369,10 +368,9 @@ &pcie1 {
 	pinctrl-0 = <&pinctrl_pcie1>;
 	reset-gpio = <&gpio5 12 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE2_AUX>,
+		 <&pcie0_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE2_PHY>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE2_AUX>;
 	vpcie-supply = <&reg_pcie1>;
 	vph-supply = <&vgen5_reg>;
 	status = "okay";
arch/arm64/boot/dts/freescale/imx8mq-kontron-pitx-imx8m.dts +4 -6
index a91c136797f60..6376417e918c2 100644
@@ -245,20 +245,18 @@ &pcie0 {
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio1 9 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE1_AUX>,
+		 <&pcie0_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE1_PHY>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE1_AUX>;
 	status = "okay";
 };
 
 /* Intel Ethernet Controller I210/I211 */
 &pcie1 {
 	clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE2_AUX>,
+		 <&pcie1_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE2_PHY>,
-		 <&pcie1_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE2_AUX>;
 	fsl,max-link-speed = <1>;
 	status = "okay";
 };
arch/arm64/boot/dts/freescale/imx8mq-mnt-reform2.dts +2 -3
index 055031bba8c4b..200268660518d 100644
@@ -197,10 +197,9 @@ &pcie1 {
 	pinctrl-0 = <&pinctrl_pcie1>;
 	reset-gpio = <&gpio3 23 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE2_AUX>,
+		 <&pcie1_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE2_PHY>,
-		 <&pcie1_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE2_AUX>;
 	status = "okay";
 };
 
arch/arm64/boot/dts/freescale/imx8mq-tqma8mq-mba8mx.dts +4 -6
index d7660eab68b94..344cfdaeb1d59 100644
@@ -105,10 +105,9 @@ &led2 {
 &pcie0 {
 	reset-gpio = <&expander0 14 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE1_AUX>,
+		 <&pcie0_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE1_PHY>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE1_AUX>;
 	epdev_on-supply = <&reg_vcc_3v3>;
 	hard-wired = <1>;
 	status = "okay";
@@ -120,10 +119,9 @@ &pcie0 {
  */
 &pcie1 {
 	clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE2_AUX>,
+		 <&pcie1_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE2_PHY>,
-		 <&pcie1_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE2_AUX>;
 	epdev_on-supply = <&reg_vcc_3v3>;
 	hard-wired = <1>;
 	status = "okay";
arch/arm64/boot/dts/freescale/imx8mq-zii-ultra.dtsi +4 -6
index 4e05120c62d41..74a7a589a3296 100644
@@ -551,10 +551,9 @@ &pcie0 {
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio1 3 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
-	         <&clk IMX8MQ_CLK_PCIE1_AUX>,
+	         <&pcie0_refclk>,
 	         <&clk IMX8MQ_CLK_PCIE1_PHY>,
-	         <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+	         <&clk IMX8MQ_CLK_PCIE1_AUX>;
 	vph-supply = <&vgen5_reg>;
 	status = "okay";
 };
@@ -564,10 +563,9 @@ &pcie1 {
 	pinctrl-0 = <&pinctrl_pcie1>;
 	reset-gpio = <&gpio1 6 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
-	         <&clk IMX8MQ_CLK_PCIE2_AUX>,
+	         <&pcie1_refclk>,
 	         <&clk IMX8MQ_CLK_PCIE2_PHY>,
-	         <&pcie1_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+	         <&clk IMX8MQ_CLK_PCIE2_AUX>;
 	vph-supply = <&vgen5_reg>;
 	status = "okay";
 };
arch/arm64/boot/dts/freescale/imx8mq.dtsi +10 -0
index faed28e3ffa17..98fbba4c99a99 100644
@@ -1542,6 +1542,11 @@ pcie0: pcie@33800000 {
 			                <0 0 0 4 &gic GIC_SPI 122 IRQ_TYPE_LEVEL_HIGH>;
 			fsl,max-link-speed = <2>;
 			linux,pci-domain = <0>;
+			clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
+				 <&clk IMX8MQ_CLK_PCIE1_PHY>,
+				 <&clk IMX8MQ_CLK_PCIE1_PHY>,
+				 <&clk IMX8MQ_CLK_PCIE1_AUX>;
+			clock-names = "pcie", "pcie_bus", "pcie_phy", "pcie_aux";
 			power-domains = <&pgc_pcie>;
 			resets = <&src IMX8MQ_RESET_PCIEPHY>,
 			         <&src IMX8MQ_RESET_PCIE_CTRL_APPS_EN>,
@@ -1579,6 +1584,11 @@ pcie1: pcie@33c00000 {
 					<0 0 0 4 &gic GIC_SPI 74 IRQ_TYPE_LEVEL_HIGH>;
 			fsl,max-link-speed = <2>;
 			linux,pci-domain = <1>;
+			clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
+				 <&clk IMX8MQ_CLK_PCIE2_PHY>,
+				 <&clk IMX8MQ_CLK_PCIE2_PHY>,
+				 <&clk IMX8MQ_CLK_PCIE2_AUX>;
+			clock-names = "pcie", "pcie_bus", "pcie_phy", "pcie_aux";
 			power-domains = <&pgc_pcie>;
 			resets = <&src IMX8MQ_RESET_PCIEPHY2>,
 			         <&src IMX8MQ_RESET_PCIE2_CTRL_APPS_EN>,
Signature · 7 lines
2.39.0


_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
#2 lore raw

RE: [PATCH v3 2/2] arm64: dts: imx8mq: Deduplicate PCIe clock-names property

Hi Marek:
Thanks for your patches.

Quoted 187 lines

-----Original Message-----
From: Marek Vasut <[email protected]>
Sent: 2023年1月16日 18:14
To: [email protected]
Cc: Marek Vasut <[email protected]>; Alexander Stein <[email protected]>; Fabio Estevam <[email protected]>; Peng Fan <[email protected]>; Hongxing Zhu <[email protected]>; Shawn Guo <[email protected]>; dl-linux-imx <[email protected]>
Subject: [PATCH v3 2/2] arm64: dts: imx8mq: Deduplicate PCIe clock-names property

Move the PCIe clock-names property from various DTs into SoC dtsi to reduce duplication. In case of a couple of boards, reorder the clock so they match the order in yaml DT bindings.

imx8mq.dtsi, imx8mq-tqma8mq-mba8mx.dts

---
Cc: Fabio Estevam <[email protected]>
Cc: Peng Fan <[email protected]>
Cc: Richard Zhu <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: NXP Linux Team <[email protected]>
To: [email protected]
---
V2: - Add RB from Alex
- Add default pcie clock entry into dtsi
- Fix the Ultra board
V3: Rebase on latest next-20230116

---
 arch/arm64/boot/dts/freescale/imx8mq-evk.dts           | 10 ++++------
 .../boot/dts/freescale/imx8mq-kontron-pitx-imx8m.dts   | 10 ++++------
 arch/arm64/boot/dts/freescale/imx8mq-mnt-reform2.dts   |  5 ++---
 .../arm64/boot/dts/freescale/imx8mq-tqma8mq-mba8mx.dts | 10 ++++------
 arch/arm64/boot/dts/freescale/imx8mq-zii-ultra.dtsi    | 10 ++++------
 arch/arm64/boot/dts/freescale/imx8mq.dtsi              | 10
++++++++++
 6 files changed, 28 insertions(+), 27 deletions(-)
arch/arm64/boot/dts/freescale/imx8mq-evk.dts +4 -6
index 78937910f4039..7507548cdb16b 100644
@@ -356,10 +356,9 @@ &pcie0 {
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio5 28 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE1_AUX>,
+		 <&pcie0_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE1_PHY>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE1_AUX>;
 	vph-supply = <&vgen5_reg>;
 	status = "okay";
 };
@@ -369,10 +368,9 @@ &pcie1 {
 	pinctrl-0 = <&pinctrl_pcie1>;
 	reset-gpio = <&gpio5 12 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE2_AUX>,
+		 <&pcie0_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE2_PHY>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE2_AUX>;
 	vpcie-supply = <&reg_pcie1>;
 	vph-supply = <&vgen5_reg>;
 	status = "okay";
arch/arm64/boot/dts/freescale/imx8mq-kontron-pitx-imx8m.dts +4 -6
index a91c136797f60..6376417e918c2 100644
@@ -245,20 +245,18 @@ &pcie0 {
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio1 9 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE1_AUX>,
+		 <&pcie0_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE1_PHY>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE1_AUX>;
 	status = "okay";
 };
 
 /* Intel Ethernet Controller I210/I211 */
 &pcie1 {
 	clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE2_AUX>,
+		 <&pcie1_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE2_PHY>,
-		 <&pcie1_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE2_AUX>;
 	fsl,max-link-speed = <1>;
 	status = "okay";
 };
arch/arm64/boot/dts/freescale/imx8mq-mnt-reform2.dts +2 -3
index 055031bba8c4b..200268660518d 100644
@@ -197,10 +197,9 @@ &pcie1 {
 	pinctrl-0 = <&pinctrl_pcie1>;
 	reset-gpio = <&gpio3 23 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE2_AUX>,
+		 <&pcie1_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE2_PHY>,
-		 <&pcie1_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE2_AUX>;
 	status = "okay";
 };
 
arch/arm64/boot/dts/freescale/imx8mq-tqma8mq-mba8mx.dts +4 -6
index d7660eab68b94..344cfdaeb1d59 100644
@@ -105,10 +105,9 @@ &led2 {
 &pcie0 {
 	reset-gpio = <&expander0 14 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE1_AUX>,
+		 <&pcie0_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE1_PHY>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE1_AUX>;
 	epdev_on-supply = <&reg_vcc_3v3>;
 	hard-wired = <1>;
 	status = "okay";
@@ -120,10 +119,9 @@ &pcie0 {
  */
 &pcie1 {
 	clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
-		 <&clk IMX8MQ_CLK_PCIE2_AUX>,
+		 <&pcie1_refclk>,
 		 <&clk IMX8MQ_CLK_PCIE2_PHY>,
-		 <&pcie1_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+		 <&clk IMX8MQ_CLK_PCIE2_AUX>;
 	epdev_on-supply = <&reg_vcc_3v3>;
 	hard-wired = <1>;
 	status = "okay";
arch/arm64/boot/dts/freescale/imx8mq-zii-ultra.dtsi +4 -6
index 4e05120c62d41..74a7a589a3296 100644
@@ -551,10 +551,9 @@ &pcie0 {
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio1 3 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
-	         <&clk IMX8MQ_CLK_PCIE1_AUX>,
+	         <&pcie0_refclk>,
 	         <&clk IMX8MQ_CLK_PCIE1_PHY>,
-	         <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+	         <&clk IMX8MQ_CLK_PCIE1_AUX>;
 	vph-supply = <&vgen5_reg>;
 	status = "okay";
 };
@@ -564,10 +563,9 @@ &pcie1 {
 	pinctrl-0 = <&pinctrl_pcie1>;
 	reset-gpio = <&gpio1 6 GPIO_ACTIVE_LOW>;
 	clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
-	         <&clk IMX8MQ_CLK_PCIE2_AUX>,
+	         <&pcie1_refclk>,
 	         <&clk IMX8MQ_CLK_PCIE2_PHY>,
-	         <&pcie1_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
+	         <&clk IMX8MQ_CLK_PCIE2_AUX>;
 	vph-supply = <&vgen5_reg>;
 	status = "okay";
 };
arch/arm64/boot/dts/freescale/imx8mq.dtsi +0 -0
index faed28e3ffa17..98fbba4c99a99 100644

arch/arm64/boot/dts/freescale/imx8mq.dtsi pcie0: pcie@33800000 { · line 1548

Quoted 7 lines
arch/arm64/boot/dts/freescale/imx8mq.dtsi +3 -0
@@ -1542,6 +1542,11 @@ pcie0: pcie@33800000 {
 			                <0 0 0 4 &gic GIC_SPI 122
 IRQ_TYPE_LEVEL_HIGH>;
 			fsl,max-link-speed = <2>;
 			linux,pci-domain = <0>;
+			clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
+				 <&clk IMX8MQ_CLK_PCIE1_PHY>,
+				 <&clk IMX8MQ_CLK_PCIE1_PHY>,

Why there are two PHY clocks?
Do you want to define IMX8MQ_CLK_PCIE1_PHY clock as "pcie_bus" clock here,
and then change "pcie_bus" clock to "pcie0_refclk" in the evk board dts later?

How about to set the "pcie_bus" clock as " pcie#_refclk " directly in i.MX8MQ
dtsi file?
Thus, it can avoid more duplicated codes in boards dts files further.

arch/arm64/boot/dts/freescale/imx8mq.dtsi pcie1: pcie@33c00000 { · line 1589

Quoted 12 lines
arch/arm64/boot/dts/freescale/imx8mq.dtsi +2 -0
+				 <&clk IMX8MQ_CLK_PCIE1_AUX>;
+			clock-names = "pcie", "pcie_bus", "pcie_phy", "pcie_aux";
 			power-domains = <&pgc_pcie>;
 			resets = <&src IMX8MQ_RESET_PCIEPHY>,
arch/arm64/boot/dts/freescale/imx8mq.dtsi +3 -1
 			         <&src IMX8MQ_RESET_PCIE_CTRL_APPS_EN>, @@
-1579,6 +1584,11 @@ pcie1: pcie@33c00000 {
 					<0 0 0 4 &gic GIC_SPI 74 IRQ_TYPE_LEVEL_HIGH>;
 			fsl,max-link-speed = <2>;
 			linux,pci-domain = <1>;
+			clocks = <&clk IMX8MQ_CLK_PCIE2_ROOT>,
+				 <&clk IMX8MQ_CLK_PCIE2_PHY>,
+				 <&clk IMX8MQ_CLK_PCIE2_PHY>,

Same to above.

Best Regards
Richard Zhu

Quoted 7 lines
arch/arm64/boot/dts/freescale/imx8mq.dtsi +2 -1
+				 <&clk IMX8MQ_CLK_PCIE2_AUX>;
+			clock-names = "pcie", "pcie_bus", "pcie_phy", "pcie_aux";
 			power-domains = <&pgc_pcie>;
 			resets = <&src IMX8MQ_RESET_PCIEPHY2>,
 			         <&src IMX8MQ_RESET_PCIE2_CTRL_APPS_EN>,
--

2.39.0

_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

#3 lore raw

Re: [PATCH v3 2/2] arm64: dts: imx8mq: Deduplicate PCIe clock-names property

On 1/17/23 05:00, Hongxing Zhu wrote:

Hi,

[...]

Quoted 8 lines
Quoted 8 lines
arch/arm64/boot/dts/freescale/imx8mq.dtsi +0 -0
index faed28e3ffa17..98fbba4c99a99 100644
@@ -1542,6 +1542,11 @@ pcie0: pcie@33800000 {
  			                <0 0 0 4 &gic GIC_SPI 122
 IRQ_TYPE_LEVEL_HIGH>;
Quoted 8 lines

arch/arm64/boot/dts/freescale/imx8mq.dtsi pcie0: pcie@33800000 { · line 1547

Quoted 5 lines
arch/arm64/boot/dts/freescale/imx8mq.dtsi +3 -0
  			fsl,max-link-speed = <2>;
  			linux,pci-domain = <0>;
+			clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
+				 <&clk IMX8MQ_CLK_PCIE1_PHY>,
+				 <&clk IMX8MQ_CLK_PCIE1_PHY>,

Why there are two PHY clocks?
Do you want to define IMX8MQ_CLK_PCIE1_PHY clock as "pcie_bus" clock here,
and then change "pcie_bus" clock to "pcie0_refclk" in the evk board dts later?

Yes

Quoted 3 lines

How about to set the "pcie_bus" clock as " pcie#_refclk " directly in i.MX8MQ
dtsi file?
Thus, it can avoid more duplicated codes in boards dts files further.

I can do that, but is that really the right approach ?

Consider a board which supplies 'pcie_bus' from some I2C PCIe clock generator, such board would now have a useless /pcie#-clock {} node in DT , right ?

_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

Reviewed-by
#4 lore raw

RE: [PATCH v3 2/2] arm64: dts: imx8mq: Deduplicate PCIe clock-names property

Hi:

Quoted 38 lines

-----Original Message-----
From: Marek Vasut <[email protected]>
Sent: 2023年1月17日 20:32
To: Hongxing Zhu <[email protected]>; [email protected]
Cc: Alexander Stein <[email protected]>; Fabio Estevam <[email protected]>; Peng Fan <[email protected]>; Shawn Guo <[email protected]>; dl-linux-imx <[email protected]>
Subject: Re: [PATCH v3 2/2] arm64: dts: imx8mq: Deduplicate PCIe clock-names property

On 1/17/23 05:00, Hongxing Zhu wrote:

Hi,

[...]

Quoted 7 lines

arch/arm64/boot/dts/freescale/imx8mq.dtsi pcie0: pcie@33800000 { · line 1542

Quoted 7 lines
arch/arm64/boot/dts/freescale/imx8mq.dtsi +0 -0
index faed28e3ffa17..98fbba4c99a99 100644
@@ -1542,6 +1542,11 @@ pcie0: pcie@33800000 {
  			                <0 0 0 4 &gic GIC_SPI 122

IRQ_TYPE_LEVEL_HIGH>;

Quoted 7 lines

arch/arm64/boot/dts/freescale/imx8mq.dtsi pcie0: pcie@33800000 { · line 1547

Quoted 5 lines
arch/arm64/boot/dts/freescale/imx8mq.dtsi +3 -0
  			fsl,max-link-speed = <2>;
  			linux,pci-domain = <0>;
+			clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
+				 <&clk IMX8MQ_CLK_PCIE1_PHY>,
+				 <&clk IMX8MQ_CLK_PCIE1_PHY>,

Why there are two PHY clocks?
Do you want to define IMX8MQ_CLK_PCIE1_PHY clock as "pcie_bus" clock

here,

Quoted 1 line

and then change "pcie_bus" clock to "pcie0_refclk" in the evk board dts

later?

Yes

Quoted 8 lines
Quoted 3 lines

How about to set the "pcie_bus" clock as " pcie#_refclk " directly in i.MX8MQ
dtsi file?
Thus, it can avoid more duplicated codes in boards dts files further.

I can do that, but is that really the right approach ?

Consider a board which supplies 'pcie_bus' from some I2C PCIe clock generator, such board would now have a useless /pcie#-clock {} node in DT , right ?

You're right.
I only consider the fixed external PCIe clock generator design contained on
i.MX8MQ EVK board.
I'm fine with this patch-set, thanks.

Best Regards
Richard Zhu
_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

Reviewed-by on v3 1/2
#5 lore raw
In reply to Marek Vasut

Hi Marek:

Quoted 11 lines

-----Original Message-----
From: Marek Vasut <[email protected]>
Sent: 2023年1月16日 18:14
To: [email protected]
Cc: Marek Vasut <[email protected]>; Alexander Stein <[email protected]>; Fabio Estevam <[email protected]>; Peng Fan <[email protected]>; Hongxing Zhu <[email protected]>; Shawn Guo <[email protected]>; dl-linux-imx <[email protected]>
Subject: [PATCH v3 1/2] arm64: dts: imx8mm: Deduplicate PCIe clock-names property

Quoted 7 lines

Move the PCIe clock-names property from various DTs into SoC dtsi to reduce duplication. In case of a couple of boards, reorder the clock so they match the order in yaml DT bindings.

imx8mm.dtsi, imx8mm-tqma8mqml-mba8mx.dts

Thanks for your patch.

Best Regards
Richard Zhu

Quoted 297 lines

---
Cc: Fabio Estevam <[email protected]>
Cc: Peng Fan <[email protected]>
Cc: Richard Zhu <[email protected]>
Cc: Shawn Guo <[email protected]>
Cc: NXP Linux Team <[email protected]>
To: [email protected]
---
V2: - Add RB from Alex
- Fix venice build
- Add default pcie clock entry into dtsi
V3: - Drop clocks altogether from imx8mm-innocomm-wb15.dtsi imx8mm-phyboard-polis-rdk.dts imx8mm-verdin.dtsi
as they are identical to imx8mm.dtsi

---
 arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi  | 5 ++---
arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc.dts | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-evk.dtsi               | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-innocomm-wb15.dtsi     | 3 ---
 arch/arm64/boot/dts/freescale/imx8mm-phyboard-polis-rdk.dts | 3 ---
 arch/arm64/boot/dts/freescale/imx8mm-tqma8mqml-mba8mx.dts   | 5
++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw71xx.dtsi     | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw72xx.dtsi     | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw73xx.dtsi     | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw7901.dts      | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw7902.dts      | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw7903.dts      | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-venice-gw7904.dts      | 5 ++---
 arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi            | 4 ----
 arch/arm64/boot/dts/freescale/imx8mm.dtsi                   | 4 ++++
 15 files changed, 26 insertions(+), 43 deletions(-)
arch/arm64/boot/dts/freescale/imx8mm-beacon-baseboard.dtsi +2 -3
index 169f047fbca50..bc531175ff765 100644
@@ -241,9 +241,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 21 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk_gated>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk_gated>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;

assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc.dts b/arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc.dts index 9889319d4f045..b1f2beb40a98f 100644

arch/arm64/boot/dts/freescale/imx8mm-data-modul-edm-sbc.dts +2 -3
@@ -905,9 +905,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio1 5 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcieclk 0>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcieclk 0>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;

assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-evk.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-evk.dtsi
index e0b604ac0da4f..0ce3005d578d2 100644

arch/arm64/boot/dts/freescale/imx8mm-evk.dtsi +2 -3
@@ -360,9 +360,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 21 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;

assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-innocomm-wb15.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-innocomm-wb15.dtsi index 44e87b1568e79..299752aa82772 100644

arch/arm64/boot/dts/freescale/imx8mm-innocomm-wb15.dtsi +0 -3
@@ -210,9 +210,6 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio5 21 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_PHY>,
-		 <&clk IMX8MM_CLK_PCIE1_AUX>;
-	clock-names = "pcie", "pcie_bus", "pcie_aux";
 	fsl,max-link-speed = <1>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>, <&clk

IMX8MM_CLK_PCIE1_CTRL>;
assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-phyboard-polis-rdk.dts b/arch/arm64/boot/dts/freescale/imx8mm-phyboard-polis-rdk.dts index 4a3df2b77b0be..266129b4a70d9 100644

arch/arm64/boot/dts/freescale/imx8mm-phyboard-polis-rdk.dts +0 -3
@@ -175,9 +175,6 @@ &pcie0 {
 	assigned-clock-parents = <&clk IMX8MM_SYS_PLL2_50M>,
 				 <&clk IMX8MM_SYS_PLL2_250M>;
 	assigned-clock-rates = <10000000>, <250000000>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		 <&clk IMX8MM_CLK_PCIE1_PHY>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie>;

reset-gpio = <&gpio4 9 GPIO_ACTIVE_LOW>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-tqma8mqml-mba8mx.dts b/arch/arm64/boot/dts/freescale/imx8mm-tqma8mqml-mba8mx.dts index a0aeac6199299..156d793a0c972 100644

arch/arm64/boot/dts/freescale/imx8mm-tqma8mqml-mba8mx.dts +2 -3
@@ -79,9 +79,8 @@ &pcie_phy {
 
 &pcie0 {
 	reset-gpio = <&expander0 14 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		<&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 				<&clk IMX8MM_CLK_PCIE1_CTRL>;

assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-venice-gw71xx.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-venice-gw71xx.dtsi index c557dbf4dcd60..0ce60ad9c7d50 100644

arch/arm64/boot/dts/freescale/imx8mm-venice-gw71xx.dtsi +2 -3
@@ -120,9 +120,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 6 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;

assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-venice-gw72xx.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-venice-gw72xx.dtsi index 41d0de6a7027b..570992a52b759 100644

arch/arm64/boot/dts/freescale/imx8mm-venice-gw72xx.dtsi +2 -3
@@ -142,9 +142,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 6 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;

assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-venice-gw73xx.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-venice-gw73xx.dtsi index 7761d5671cb13..1800c6a4b1fc6 100644

arch/arm64/boot/dts/freescale/imx8mm-venice-gw73xx.dtsi +2 -3
@@ -162,9 +162,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 6 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;

assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-venice-gw7901.dts b/arch/arm64/boot/dts/freescale/imx8mm-venice-gw7901.dts index 64b366e83fa14..df3b2c93d2d58 100644

arch/arm64/boot/dts/freescale/imx8mm-venice-gw7901.dts +2 -3
@@ -702,9 +702,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio5 2 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;

assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-venice-gw7902.dts b/arch/arm64/boot/dts/freescale/imx8mm-venice-gw7902.dts index e8bc1fccc47be..c33ec6826d324 100644

arch/arm64/boot/dts/freescale/imx8mm-venice-gw7902.dts +2 -3
@@ -623,9 +623,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio4 5 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;

assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-venice-gw7903.dts b/arch/arm64/boot/dts/freescale/imx8mm-venice-gw7903.dts index acc2ba8e00a88..363020a08c9b8 100644

arch/arm64/boot/dts/freescale/imx8mm-venice-gw7903.dts +2 -3
@@ -557,9 +557,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio5 11 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;

assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-venice-gw7904.dts b/arch/arm64/boot/dts/freescale/imx8mm-venice-gw7904.dts index eceed9816f5dc..93088fa1c3b9c 100644

arch/arm64/boot/dts/freescale/imx8mm-venice-gw7904.dts +2 -3
@@ -618,9 +618,8 @@ &pcie0 {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	reset-gpio = <&gpio5 11 GPIO_ACTIVE_LOW>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&clk
 IMX8MM_CLK_PCIE1_AUX>,
-		 <&pcie0_refclk>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
+	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>, <&pcie0_refclk>,
+		 <&clk IMX8MM_CLK_PCIE1_AUX>;
 	assigned-clocks = <&clk IMX8MM_CLK_PCIE1_AUX>,
 			  <&clk IMX8MM_CLK_PCIE1_CTRL>;

assigned-clock-rates = <10000000>, <250000000>; diff --git
a/arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi b/arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi index 7e8b3b0fa3066..5b2493bb8dd93 100644

arch/arm64/boot/dts/freescale/imx8mm-verdin.dtsi +0 -4
@@ -657,10 +657,6 @@ &pcie0 {
 	assigned-clock-parents = <&clk IMX8MM_SYS_PLL2_50M>,
 				 <&clk IMX8MM_SYS_PLL2_250M>;
 	assigned-clock-rates = <10000000>, <250000000>;
-	clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>,
-		 <&clk IMX8MM_CLK_PCIE1_AUX>,
-		 <&clk IMX8MM_CLK_PCIE1_PHY>;
-	clock-names = "pcie", "pcie_aux", "pcie_bus";
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_pcie0>;
 	/* PCIE_1_RESET# (SODIMM 244) */
arch/arm64/boot/dts/freescale/imx8mm.dtsi +4 -1
index 04cf2c3c9928b..31f4548f85cfa 100644
@@ -1302,6 +1302,10 @@ pcie0: pcie@33800000 {
 					<0 0 0 4 &gic GIC_SPI 122 IRQ_TYPE_LEVEL_HIGH>;
 			fsl,max-link-speed = <2>;
 			linux,pci-domain = <0>;
+			clocks = <&clk IMX8MM_CLK_PCIE1_ROOT>,
+				 <&clk IMX8MM_CLK_PCIE1_PHY>,
+				 <&clk IMX8MM_CLK_PCIE1_AUX>;
+			clock-names = "pcie", "pcie_bus", "pcie_aux";
 			power-domains = <&pgc_pcie>;
 			resets = <&src IMX8MQ_RESET_PCIE_CTRL_APPS_EN>,
 				 <&src IMX8MQ_RESET_PCIE_CTRL_APPS_TURNOFF>;
--
Quoted 1 line

2.39.0

_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

Applied
#6 lore raw
In reply to Marek Vasut
Quoted 6 lines · Marek Vasut

Move the PCIe clock-names property from various DTs into SoC dtsi to reduce duplication. In case of a couple of boards, reorder the clock so they match the order in yaml DT bindings.

Applied both, thanks!

_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel