Skip to contentSkip to conversation

armv8: ls1088aqds: Add IFC-NOR as boot source for LS1088

PATCH New Ashish Kumar 2 participants 2 messages Feb 19, 2018 – Mar 21, 2018 Arm (32-bit)

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 armv8: ls1088aqds: Add IFC-NOR as boot source for LS1088

IFC-NOR and QSPI-NOR pins are muxed on SoC,so they cannot be accessed simultaneously, but IFC-NOR can be accessed along with SD-BOOT.

ls1088aqds_sdcard_ifc_defconfig: is defconfig for SD as boot source and IFC-NOR to be used as flash, this will be used to write IFC-NOR image on IFC flash. QSPI and DSPI cannot be accessed in this defconfig.

IFC-NOR image is generated by ls1088aqds_defconfig.

---
depends upon:
http://patchwork.ozlabs.org/project/uboot/list/?series=29287

v2:
Remove hardcoded timing for sys, ddr clock
Remove hardcoded timing for IFC
Move unrelated code to different clean-up patch

 arch/arm/dts/fsl-ls1088a-qds.dts        | 37 ++++++++++++++++++++++
 arch/arm/dts/fsl-ls1088a.dtsi           |  5 +++
 board/freescale/ls1088a/MAINTAINERS     |  2 ++
 configs/ls1088aqds_defconfig            | 43 ++++++++++++++++++++++++++
 configs/ls1088aqds_sdcard_ifc_defconfig | 54 +++++++++++++++++++++++++++++++++
 include/configs/ls1088aqds.h            | 12 +++++---
 6 files changed, 148 insertions(+), 5 deletions(-)
 create mode 100644 configs/ls1088aqds_defconfig
 create mode 100644 configs/ls1088aqds_sdcard_ifc_defconfig
arch/arm/dts/fsl-ls1088a-qds.dts +37 -0
index 225c7c5..02000fc 100644
@@ -19,6 +19,43 @@
 	};
 };
 
+&ifc {
+	#address-cells = <2>;
+	#size-cells = <1>;
+	/* NOR, NAND Flashes and FPGA on board */
+	ranges = <0 0 0x5 0x80000000 0x08000000
+			2 0 0x5 0x30000000 0x00010000
+			3 0 0x5 0x20000000 0x00010000>;
+	status = "okay";
+
+	nor at 0,0 {
+		#address-cells = <1>;
+		#size-cells = <1>;
+		compatible = "cfi-flash";
+		reg = <0x0 0x0 0x8000000>;
+		bank-width = <2>;
+		device-width = <1>;
+	};
+
+	nand at 2,0 {
+		compatible = "fsl,ifc-nand";
+		#address-cells = <1>;
+		#size-cells = <1>;
+		reg = <0x1 0x0 0x10000>;
+	};
+
+	fpga: board-control at 3,0 {
+		#address-cells = <1>;
+		#size-cells = <1>;
+		compatible = "simple-bus", "fsl,ls1088aqds-fpga",
+				"fsl,fpga-qixis";
+		reg = <0x2 0x0 0x0000100>;
+		bank-width = <1>;
+		device-width = <1>;
+		ranges = <0 2 0 0x100>;
+	};
+};
+
 &dspi {
 	bus-num = <0>;
 	status = "okay";
arch/arm/dts/fsl-ls1088a.dtsi +5 -0
index f8f8654..b4a42cf 100644
@@ -75,6 +75,11 @@
 		reg-names = "QuadSPI", "QuadSPI-memory";
 		num-cs = <4>;
 	};
+	ifc: ifc at 1530000 {
+		compatible = "fsl,ifc", "simple-bus";
+		reg = <0x0 0x2240000 0x0 0x20000>;
+		interrupts = <0 21 0x4>; /* Level high type */
+	};
 
 	usb0: usb3 at 3100000 {
 		compatible = "fsl,layerscape-dwc3";
board/freescale/ls1088a/MAINTAINERS +2 -0
index 371e5db..4d804d9 100644
@@ -15,6 +15,8 @@ F:	board/freescale/ls1088a/
 F:	include/configs/ls1088aqds.h
 F:	configs/ls1088aqds_qspi_defconfig
 F:	configs/ls1088aqds_sdcard_qspi_defconfig
+F:	configs/ls1088aqds_defconfig
+F:	configs/ls1088aqds_sdcard_ifc_defconfig
 
 LS1088AQDS_QSPI_SECURE_BOOT BOARD
 M:	Udit Agarwal <[email protected]>
configs/ls1088aqds_defconfig new file +43 -0

43 lines not on this page · raw message

configs/ls1088aqds_sdcard_ifc_defconfig new file +54 -0

54 lines not on this page · raw message

include/configs/ls1088aqds.h +7 -5
index 1f2161b..1fd2286 100644
@@ -27,7 +27,6 @@ unsigned long get_board_ddr_clk(void);
 #define CONFIG_SYS_MMC_ENV_DEV		0
 #define CONFIG_ENV_SIZE			0x2000
 #else
-#define CONFIG_ENV_IS_IN_FLASH
 #define CONFIG_ENV_ADDR			(CONFIG_SYS_FLASH_BASE + 0x300000)
 #define CONFIG_ENV_SECT_SIZE		0x20000
 #define CONFIG_ENV_SIZE			0x20000
@@ -41,6 +40,8 @@ unsigned long get_board_ddr_clk(void);
 #define CONFIG_SYS_CLK_FREQ		100000000
 #define CONFIG_DDR_CLK_FREQ		100000000
 #else
+#define CONFIG_QIXIS_I2C_ACCESS
+#define CONFIG_SYS_I2C_EARLY_INIT
 #define CONFIG_SYS_CLK_FREQ		get_board_sys_clk()
 #define CONFIG_DDR_CLK_FREQ		get_board_ddr_clk()
 #endif
@@ -89,13 +90,14 @@ unsigned long get_board_ddr_clk(void);
 #define CONFIG_SYS_NOR_CSOR	CSOR_NOR_ADM_SHIFT(12)
 #define CONFIG_SYS_NOR_FTIM0	(FTIM0_NOR_TACSE(0x4) | \
 				FTIM0_NOR_TEADC(0x5) | \
+				FTIM0_NOR_TAVDS(0x6) | \
 				FTIM0_NOR_TEAHC(0x5))
 #define CONFIG_SYS_NOR_FTIM1	(FTIM1_NOR_TACO(0x35) | \
-				FTIM1_NOR_TRAD_NOR(0x1a) |\
+				FTIM1_NOR_TRAD_NOR(0x1a) | \
 				FTIM1_NOR_TSEQRAD_NOR(0x13))
-#define CONFIG_SYS_NOR_FTIM2	(FTIM2_NOR_TCS(0x4) | \
-				FTIM2_NOR_TCH(0x4) | \
-				FTIM2_NOR_TWPH(0x0E) | \
+#define CONFIG_SYS_NOR_FTIM2	(FTIM2_NOR_TCS(0x8) | \
+				FTIM2_NOR_TCH(0x8) | \
+				FTIM2_NOR_TWPH(0xe) | \
 				FTIM2_NOR_TWP(0x1c))
 #define CONFIG_SYS_NOR_FTIM3	0x04000000
 #define CONFIG_SYS_IFC_CCR	0x01000000
Signature · 1 line
2.7.4
#1 lore raw

PATCH v2 1/1 armv8: ls1088aqds: Add IFC-NOR as boot source for LS1088

Quoted 9 lines · Ashish Kumar

IFC-NOR and QSPI-NOR pins are muxed on SoC,so they cannot be accessed simultaneously, but IFC-NOR can be accessed along with SD-BOOT.

ls1088aqds_sdcard_ifc_defconfig: is defconfig for SD as boot source and IFC-NOR to be used as flash, this will be used to write IFC-NOR image on IFC flash. QSPI and DSPI cannot be accessed in this defconfig.

Quoted 4 lines

IFC-NOR image is generated by ls1088aqds_defconfig.

---

Minor change to commit message.
Applied to fsl-qoriq master. Thanks.

York