Skip to contentSkip to conversation

configs: omap3/35_logic and omap3/35_logic_somlv: Reduce SPL size

PATCH New Adam Ford 1 participant 2 messages Jan 12, 2020 Arm (32-bit)

lore
Share & tools
lore

Adam Ford

author
#0 lore raw

PATCH 1/2 configs: omap3/35_logic and omap3/35_logic_somlv: Reduce SPL size

Currently the DM37 and OMAP35 boards do not boot due to SPL bring too large.

SPL doesn't need GPIO, I2C nor MMC sector access since it uses a FAT file system.

This patch unifies all these boards to remove these unused features from their defconfigs

configs/omap35_logic_defconfig +2 -0
index c7b67f0ffe..aabb438e1a 100644
@@ -21,7 +21,9 @@ CONFIG_DEFAULT_FDT_FILE="logicpd-torpedo-35xx-devkit.dtb"
 CONFIG_VERSION_VARIABLE=y
 CONFIG_SPL_SYS_MALLOC_SIMPLE=y
 CONFIG_SPL_SEPARATE_BSS=y
+# CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR is not set
 # CONFIG_SPL_FS_EXT4 is not set
+# CONFIG_SPL_I2C_SUPPORT is not set
 CONFIG_SPL_MTD_SUPPORT=y
 CONFIG_SPL_OS_BOOT=y
 CONFIG_SYS_PROMPT="OMAP Logic # "
configs/omap35_logic_somlv_defconfig +2 -0
index 9773464d04..51c5d449e0 100644
@@ -20,7 +20,9 @@ CONFIG_DEFAULT_FDT_FILE="logicpd-som-lv-35xx-devkit.dtb"
 CONFIG_VERSION_VARIABLE=y
 CONFIG_SPL_SYS_MALLOC_SIMPLE=y
 CONFIG_SPL_SEPARATE_BSS=y
+# CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR is not set
 # CONFIG_SPL_FS_EXT4 is not set
+# CONFIG_SPL_I2C_SUPPORT is not set
 CONFIG_SPL_MTD_SUPPORT=y
 CONFIG_SPL_OS_BOOT=y
 # CONFIG_SPL_POWER_SUPPORT is not set
configs/omap3_logic_defconfig +2 -0
index f336c3809c..15925fb7db 100644
@@ -20,7 +20,9 @@ CONFIG_SYS_CONSOLE_INFO_QUIET=y
 CONFIG_VERSION_VARIABLE=y
 CONFIG_SPL_SYS_MALLOC_SIMPLE=y
 CONFIG_SPL_SEPARATE_BSS=y
+# CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR is not set
 # CONFIG_SPL_FS_EXT4 is not set
+# CONFIG_SPL_I2C_SUPPORT is not set
 CONFIG_SPL_MTD_SUPPORT=y
 CONFIG_SPL_OS_BOOT=y
 CONFIG_SYS_PROMPT="OMAP Logic # "
configs/omap3_logic_somlv_defconfig +2 -0
index 163bb18375..ea8fc37f12 100644
@@ -21,7 +21,9 @@ CONFIG_DEFAULT_FDT_FILE="logicpd-som-lv-37xx-devkit.dtb"
 CONFIG_VERSION_VARIABLE=y
 CONFIG_SPL_SYS_MALLOC_SIMPLE=y
 CONFIG_SPL_SEPARATE_BSS=y
+# CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR is not set
 # CONFIG_SPL_FS_EXT4 is not set
+# CONFIG_SPL_I2C_SUPPORT is not set
 CONFIG_SPL_MTD_SUPPORT=y
 CONFIG_SPL_OS_BOOT=y
 # CONFIG_SPL_POWER_SUPPORT is not set
Signature · 1 line
2.20.1
author
#1 lore raw

PATCH 2/2 ARM: dts: omap3/omap35 Torpedo and SOM-LV: Unify and shrink SPL dtb

None of these boards boot, but the solution appears to be the same. All the boards have SPL that is too large. With a few defconfig options removed, these corresponding options can be removed from their respective SPL dtb files.

This patch unifies the DM37/OMAP35 boards' -u-boot.dtsi files to remove gpio's, i2c, bandgap, thermal zones, unneeded uarts, and unneeded MMC nodes.

arch/arm/dts/logicpd-som-lv-35xx-devkit-u-boot.dtsi +28 -0
index 1abd9a3887..173b492cd9 100644
@@ -17,16 +17,44 @@
 	};
 };
 
+&gpio1 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&gpio2 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&gpio3 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&gpio4 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&gpio5 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&gpio6 {
+	/delete-property/ u-boot,dm-spl;
+};
+
 &i2c1 {
 	clock-frequency = <400000>;
+	/delete-property/ u-boot,dm-spl;
 };
 
 &i2c2 {
 	clock-frequency = <400000>;
+	/delete-property/ u-boot,dm-spl;
 };
 
+/delete-node/ &bandgap;
 /delete-node/ &uart2;
 /delete-node/ &uart3;
 /delete-node/ &mmc2;
 /delete-node/ &mmc3;
+/delete-node/ &thermal_zones;
 
arch/arm/dts/logicpd-som-lv-37xx-devkit-u-boot.dtsi +8 -0
index e5d9e4f1b1..173b492cd9 100644
@@ -29,6 +29,10 @@
 	/delete-property/ u-boot,dm-spl;
 };
 
+&gpio4 {
+	/delete-property/ u-boot,dm-spl;
+};
+
 &gpio5 {
 	/delete-property/ u-boot,dm-spl;
 };
@@ -39,14 +43,18 @@
 
 &i2c1 {
 	clock-frequency = <400000>;
+	/delete-property/ u-boot,dm-spl;
 };
 
 &i2c2 {
 	clock-frequency = <400000>;
+	/delete-property/ u-boot,dm-spl;
 };
 
+/delete-node/ &bandgap;
 /delete-node/ &uart2;
 /delete-node/ &uart3;
 /delete-node/ &mmc2;
 /delete-node/ &mmc3;
+/delete-node/ &thermal_zones;
 
arch/arm/dts/logicpd-torpedo-35xx-devkit-u-boot.dtsi +32 -0
index 1635e42b55..581247def0 100644
@@ -7,21 +7,53 @@
 #include "omap3-u-boot.dtsi"
 
 / {
+	chosen {
+		stdout-path = &uart1;
+	};
+
 	aliases {
 		/delete-property/ serial1;
 		/delete-property/ serial2;
 	};
 };
 
+&gpio1 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&gpio2 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&gpio3 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&gpio4 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&gpio5 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&gpio6 {
+	/delete-property/ u-boot,dm-spl;
+};
+
 &i2c1 {
 	clock-frequency = <400000>;
+	/delete-property/ u-boot,dm-spl;
 };
 
 &i2c2 {
 	clock-frequency = <400000>;
+	/delete-property/ u-boot,dm-spl;
 };
 
+/delete-node/ &bandgap;
 /delete-node/ &uart2;
 /delete-node/ &uart3;
 /delete-node/ &mmc2;
 /delete-node/ &mmc3;
+/delete-node/ &thermal_zones;
arch/arm/dts/logicpd-torpedo-37xx-devkit-u-boot.dtsi +7 -1
index 76f74326ae..9b709c147c 100644
@@ -15,6 +15,7 @@
 
 &i2c1 {
 	clock-frequency = <400000>;
+	/delete-property/ u-boot,dm-spl;
 };
 
 &i2c2 {
@@ -33,6 +34,10 @@
 	/delete-property/ u-boot,dm-spl;
 };
 
+&gpio4 {
+	/delete-property/ u-boot,dm-spl;
+};
+
 &gpio5 {
 	/delete-property/ u-boot,dm-spl;
 };
@@ -41,8 +46,9 @@
 	/delete-property/ u-boot,dm-spl;
 };
 
+/delete-node/ &bandgap;
 /delete-node/ &uart2;
 /delete-node/ &uart3;
 /delete-node/ &mmc2;
 /delete-node/ &mmc3;
-
+/delete-node/ &thermal_zones;
Signature · 1 line
2.20.1