Skip to contentSkip to conversation

ARM: dts: socfpga: Flag reset manager on A10 as pre-reloc

PATCH New Marek Vasut 1 participant 5 messages Aug 13, 2018 Arm (32-bit)

lore
Share & tools
lore
#0 lore raw

PATCH 1/5 ARM: dts: socfpga: Flag reset manager on A10 as pre-reloc

The Altera reset manager block must be available very early on, since it controls ie. UART resets. Flag it as pre-reloc.

Cc Chin Liang See <[email protected]>
Cc Dinh Nguyen <[email protected]>
Cc Ley Foon Tan <[email protected]>
---
 arch/arm/dts/socfpga_arria10.dtsi | 2 ++
 1 file changed, 2 insertions(+)
arch/arm/dts/socfpga_arria10.dtsi +2 -0
index 2f935a21e9..51b31dc2b5 100644
@@ -55,6 +55,7 @@
 		device_type = "soc";
 		interrupt-parent = <&intc>;
 		ranges;
+		u-boot,dm-pre-reloc;
 
 		amba {
 			compatible = "simple-bus";
@@ -735,6 +736,7 @@
 			compatible = "altr,rst-mgr";
 			reg = <0xffd05000 0x100>;
 			altr,modrst-offset = <0x20>;
+			u-boot,dm-pre-reloc;
 		};
 
 		scu: snoop-control-unit at ffffc000 {
Signature · 1 line
2.16.2
#1 lore raw

PATCH 2/5 ARM: dts: socfpga: Add missing UART resets

The UART0 and UART1 resets are missing from DT, so the reset manager cannot control them. Add the missing DT reset entries.

Cc Chin Liang See <[email protected]>
Cc Dinh Nguyen <[email protected]>
Cc Ley Foon Tan <[email protected]>
---
 arch/arm/dts/socfpga_arria10.dtsi | 2 ++
 1 file changed, 2 insertions(+)
arch/arm/dts/socfpga_arria10.dtsi +2 -0
index 51b31dc2b5..aafcfe9ce4 100644
@@ -797,6 +797,7 @@
 			reg-shift = <2>;
 			reg-io-width = <4>;
 			clocks = <&l4_sp_clk>;
+			resets = <&rst UART0_RESET>;
 			status = "disabled";
 		};
 
@@ -807,6 +808,7 @@
 			reg-shift = <2>;
 			reg-io-width = <4>;
 			clocks = <&l4_sp_clk>;
+			resets = <&rst UART1_RESET>;
 			status = "disabled";
 		};
 
Signature · 1 line
2.16.2
#2 lore raw

PATCH 3/5 ARM: dts: socfpga: Fix Arria10 GMAC resets

In reply to Marek Vasut

Add the GMAC0,1 OCP resets, which must also be ungated for those GMACs to work and add GMAC2 reset and OCP resets which were missing altogether.

Cc Chin Liang See <[email protected]>
Cc Dinh Nguyen <[email protected]>
Cc Ley Foon Tan <[email protected]>
---
 arch/arm/dts/socfpga_arria10.dtsi | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)
arch/arm/dts/socfpga_arria10.dtsi +6 -4
index aafcfe9ce4..f5f1b8db9b 100644
@@ -428,8 +428,8 @@
 			rx-fifo-depth = <16384>;
 			clocks = <&l4_mp_clk>;
 			clock-names = "stmmaceth";
-			resets = <&rst EMAC0_RESET>;
-			reset-names = "stmmaceth";
+			resets = <&rst EMAC0_RESET>, <&rst EMAC0_OCP_RESET>;
+			reset-names = "stmmaceth", "stmmaceth-ocp";
 			snps,axi-config = <&socfpga_axi_setup>;
 			status = "disabled";
 		};
@@ -448,8 +448,8 @@
 			rx-fifo-depth = <16384>;
 			clocks = <&l4_mp_clk>;
 			clock-names = "stmmaceth";
-			resets = <&rst EMAC1_RESET>;
-			reset-names = "stmmaceth";
+			resets = <&rst EMAC1_RESET>, <&rst EMAC1_OCP_RESET>;
+			reset-names = "stmmaceth", "stmmaceth-ocp";
 			snps,axi-config = <&socfpga_axi_setup>;
 			status = "disabled";
 		};
@@ -468,6 +468,8 @@
 			rx-fifo-depth = <16384>;
 			clocks = <&l4_mp_clk>;
 			clock-names = "stmmaceth";
+			resets = <&rst EMAC2_RESET>, <&rst EMAC2_OCP_RESET>;
+			reset-names = "stmmaceth", "stmmaceth-ocp";
 			snps,axi-config = <&socfpga_axi_setup>;
 			status = "disabled";
 		};
Signature · 1 line
2.16.2
#3 lore raw

PATCH 4/5 ARM: dts: socfpga: Add missing I2C resets

In reply to Marek Vasut

The I2Cx resets are missing from DT, so the reset manager cannot control them. Add the missing DT reset entries.

Cc Chin Liang See <[email protected]>
Cc Dinh Nguyen <[email protected]>
Cc Ley Foon Tan <[email protected]>
---
 arch/arm/dts/socfpga_arria10.dtsi | 10 ++++++++++
 1 file changed, 10 insertions(+)
arch/arm/dts/socfpga_arria10.dtsi +10 -0
index f5f1b8db9b..05425a03fc 100644
@@ -550,6 +550,8 @@
 			reg = <0xffc02200 0x100>;
 			interrupts = <0 105 IRQ_TYPE_LEVEL_HIGH>;
 			clocks = <&l4_sp_clk>;
+			resets = <&rst I2C0_RESET>;
+			reset-names = "i2c";
 			status = "disabled";
 		};
 
@@ -560,6 +562,8 @@
 			reg = <0xffc02300 0x100>;
 			interrupts = <0 106 IRQ_TYPE_LEVEL_HIGH>;
 			clocks = <&l4_sp_clk>;
+			resets = <&rst I2C1_RESET>;
+			reset-names = "i2c";
 			status = "disabled";
 		};
 
@@ -570,6 +574,8 @@
 			reg = <0xffc02400 0x100>;
 			interrupts = <0 107 IRQ_TYPE_LEVEL_HIGH>;
 			clocks = <&l4_sp_clk>;
+			resets = <&rst I2C2_RESET>;
+			reset-names = "i2c";
 			status = "disabled";
 		};
 
@@ -580,6 +586,8 @@
 			reg = <0xffc02500 0x100>;
 			interrupts = <0 108 IRQ_TYPE_LEVEL_HIGH>;
 			clocks = <&l4_sp_clk>;
+			resets = <&rst I2C3_RESET>;
+			reset-names = "i2c";
 			status = "disabled";
 		};
 
@@ -590,6 +598,8 @@
 			reg = <0xffc02600 0x100>;
 			interrupts = <0 109 IRQ_TYPE_LEVEL_HIGH>;
 			clocks = <&l4_sp_clk>;
+			resets = <&rst I2C4_RESET>;
+			reset-names = "i2c";
 			status = "disabled";
 		};
 
Signature · 1 line
2.16.2
#4 lore raw

PATCH 5/5 ARM: dts: socfpga: Add i2c alias to A10 SoCDK

In reply to Marek Vasut

The A10 SoCDK is missing the I2C bus alias, so DM I2C cannot assign the I2C bus a bus number. Add the missing alias.

Cc Chin Liang See <[email protected]>
Cc Dinh Nguyen <[email protected]>
Cc Ley Foon Tan <[email protected]>
---
 arch/arm/dts/socfpga_arria10_socdk.dtsi | 1 +
 1 file changed, 1 insertion(+)
arch/arm/dts/socfpga_arria10_socdk.dtsi +1 -0
index 3f59f02577..4018a5b929 100644
@@ -23,6 +23,7 @@
 	aliases {
 		ethernet0 = &gmac0;
 		serial0 = &uart1;
+		i2c0 = &i2c1;
 	};
 
 	chosen {
Signature · 1 line
2.16.2