[PATCH v2 02/17] board: cssi: Fix SPI nodes in DTS

Christophe Leroy christophe.leroy at csgroup.eu
Mon Apr 15 08:07:15 CEST 2024


When adding additional SPI peripherals, the reg property needs to
be added, and this leads to the following error:

  arch/powerpc/dts/cmpc885.dtb: Warning (reg_format): /immr at ff000000/spi at aa0/temp at 1:reg: property has invalid length (4 bytes) (#address-cells == 1, #size-cells == 1)
  arch/powerpc/dts/cmpc885.dtb: Warning (reg_format): /immr at ff000000/spi at aa0/temp at 2:reg: property has invalid length (4 bytes) (#address-cells == 1, #size-cells == 1)

Fix it by removing cell-index and cell-size which is unused and add
reg property. Also fix node name to be in line with reg value.
Also add missing compatible for eeprom node.

Signed-off-by: Christophe Leroy <christophe.leroy at csgroup.eu>
---
 arch/powerpc/dts/cmpc885.dts | 6 +++---
 arch/powerpc/dts/cmpcpro.dts | 4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/arch/powerpc/dts/cmpc885.dts b/arch/powerpc/dts/cmpc885.dts
index 7b9566a0fa..9a33e7e77c 100644
--- a/arch/powerpc/dts/cmpc885.dts
+++ b/arch/powerpc/dts/cmpc885.dts
@@ -83,13 +83,13 @@
 		spi: spi at aa0 {
 			status = "okay";
 			#address-cells = <1>;
-			#size-cells = <1>;
-			cell-index = <0>;
+			#size-cells = <0>;
 			compatible = "fsl,mpc8xx-spi";
 			gpios = <&CPM1_PIO_B 21 1>; /* /EEPROM_CS ACTIVE_LOW */
 
 			eeprom at 0 {
-				cell-index = <1>;
+				reg = <0>;
+				compatible = "atmel,at25", "cs,eeprom";
 			};
 		};
 	};
diff --git a/arch/powerpc/dts/cmpcpro.dts b/arch/powerpc/dts/cmpcpro.dts
index c27d9dba33..78f8a9f4d3 100644
--- a/arch/powerpc/dts/cmpcpro.dts
+++ b/arch/powerpc/dts/cmpcpro.dts
@@ -142,9 +142,9 @@
 			mode = "cpu";
 			gpios = <&qe_pio_d 3 1>;
 			clock-frequency = <0>;
-			eeprom at 3 {
+			eeprom at 0 {
+				reg = <0>;
 				compatible = "atmel,at25", "cs,eeprom";
-				cell-index = <1>;
 			};
 		};
 		eth0: ucc at 3000 {
-- 
2.43.0



More information about the U-Boot mailing list