[U-Boot] [PATCH v2 1/8] board: ge: bx50v3: move detect_baseboard() out of CONFIG_VIDEO_IPUV3

detect_baseboard() function doesn't depend on CONFIG_VIDEO_IPUV3. Make sure it's available when CONFIG_VIDEO_IPUV3 is off.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk --- board/ge/bx50v3/bx50v3.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/board/ge/bx50v3/bx50v3.c b/board/ge/bx50v3/bx50v3.c index ff8f4d7..e167cd5 100644 --- a/board/ge/bx50v3/bx50v3.c +++ b/board/ge/bx50v3/bx50v3.c @@ -321,6 +321,15 @@ int board_phy_config(struct phy_device *phydev) return 0; }
+static int detect_baseboard(struct display_info_t const *dev) +{ + if (IS_ENABLED(CONFIG_TARGET_GE_B450V3) || + IS_ENABLED(CONFIG_TARGET_GE_B650V3)) + return 1; + + return 0; +} + #if defined(CONFIG_VIDEO_IPUV3) static iomux_v3_cfg_t const backlight_pads[] = { /* Power for LVDS Display */ @@ -345,15 +354,6 @@ int board_cfb_skip(void) return 0; }
-static int detect_baseboard(struct display_info_t const *dev) -{ - if (IS_ENABLED(CONFIG_TARGET_GE_B450V3) || - IS_ENABLED(CONFIG_TARGET_GE_B650V3)) - return 1; - - return 0; -} - struct display_info_t const displays[] = {{ .bus = -1, .addr = -1,

Don't try to configure the backlight when CONFIG_VIDEO_IPUV3 isn't set.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk --- board/ge/bx50v3/bx50v3.c | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/board/ge/bx50v3/bx50v3.c b/board/ge/bx50v3/bx50v3.c index e167cd5..fb112ee 100644 --- a/board/ge/bx50v3/bx50v3.c +++ b/board/ge/bx50v3/bx50v3.c @@ -601,6 +601,8 @@ int board_late_init(void) #ifdef CONFIG_CMD_BMODE add_board_boot_modes(board_boot_modes); #endif + +#ifdef CONFIG_VIDEO_IPUV3 /* We need at least 200ms between power on and backlight on * as per specifications from CHI MEI */ mdelay(250); @@ -615,6 +617,7 @@ int board_late_init(void) gpio_direction_output(LVDS_BACKLIGHT_GP, 1);
pwm_enable(0); +#endif
return 0; }

On Mon, May 30, 2016 at 01:37:02PM +0200, Andrew Shadura wrote:
Don't try to configure the backlight when CONFIG_VIDEO_IPUV3 isn't set.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk
Acked-by: Martin Donnelly martin.donnelly@ge.com
board/ge/bx50v3/bx50v3.c | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/board/ge/bx50v3/bx50v3.c b/board/ge/bx50v3/bx50v3.c index e167cd5..fb112ee 100644 --- a/board/ge/bx50v3/bx50v3.c +++ b/board/ge/bx50v3/bx50v3.c @@ -601,6 +601,8 @@ int board_late_init(void) #ifdef CONFIG_CMD_BMODE add_board_boot_modes(board_boot_modes); #endif
+#ifdef CONFIG_VIDEO_IPUV3 /* We need at least 200ms between power on and backlight on * as per specifications from CHI MEI */ mdelay(250); @@ -615,6 +617,7 @@ int board_late_init(void) gpio_direction_output(LVDS_BACKLIGHT_GP, 1);
pwm_enable(0); +#endif
return 0; } -- 2.7.4

The kernel already knows how to initialise the display, and initialising the display from U-boot is only useful for debugging and isn't necessary in production, so no need to have it enabled in U-boot by default.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk --- include/configs/ge_bx50v3.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index 1304879..53f8689 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -293,13 +293,14 @@
#define CONFIG_SYS_FSL_USDHC_NUM 3
+#define CONFIG_SYS_CONSOLE_IS_IN_ENV +#define CONFIG_SYS_CONSOLE_OVERWRITE_ROUTINE + /* Framebuffer */ -#define CONFIG_VIDEO +#ifdef CONFIG_VIDEO #define CONFIG_VIDEO_IPUV3 #define CONFIG_CFB_CONSOLE #define CONFIG_VGA_AS_SINGLE_DEVICE -#define CONFIG_SYS_CONSOLE_IS_IN_ENV -#define CONFIG_SYS_CONSOLE_OVERWRITE_ROUTINE #define CONFIG_VIDEO_BMP_RLE8 #define CONFIG_SPLASH_SCREEN #define CONFIG_SPLASH_SCREEN_ALIGN @@ -309,6 +310,7 @@ #define CONFIG_IPUV3_CLK 260000000 #define CONFIG_IMX_HDMI #define CONFIG_IMX_VIDEO_SKIP +#endif
#define CONFIG_PWM_IMX #define CONFIG_IMX6_PWM_PER_CLK 66000000

On Mon, May 30, 2016 at 01:37:03PM +0200, Andrew Shadura wrote:
The kernel already knows how to initialise the display, and initialising the display from U-boot is only useful for debugging and isn't necessary in production, so no need to have it enabled in U-boot by default.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk
Acked-by: Martin Donnelly martin.donnelly@ge.com
include/configs/ge_bx50v3.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index 1304879..53f8689 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -293,13 +293,14 @@
#define CONFIG_SYS_FSL_USDHC_NUM 3
+#define CONFIG_SYS_CONSOLE_IS_IN_ENV +#define CONFIG_SYS_CONSOLE_OVERWRITE_ROUTINE
/* Framebuffer */ -#define CONFIG_VIDEO +#ifdef CONFIG_VIDEO #define CONFIG_VIDEO_IPUV3 #define CONFIG_CFB_CONSOLE #define CONFIG_VGA_AS_SINGLE_DEVICE -#define CONFIG_SYS_CONSOLE_IS_IN_ENV -#define CONFIG_SYS_CONSOLE_OVERWRITE_ROUTINE #define CONFIG_VIDEO_BMP_RLE8 #define CONFIG_SPLASH_SCREEN #define CONFIG_SPLASH_SCREEN_ALIGN @@ -309,6 +310,7 @@ #define CONFIG_IPUV3_CLK 260000000 #define CONFIG_IMX_HDMI #define CONFIG_IMX_VIDEO_SKIP +#endif
#define CONFIG_PWM_IMX
#define CONFIG_IMX6_PWM_PER_CLK 66000000
2.7.4

The USB support is only useful for development and shouldn't be enabled in production, so it has to be disabled in U-boot by default.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk --- configs/ge_b450v3_defconfig | 2 -- configs/ge_b650v3_defconfig | 2 -- configs/ge_b850v3_defconfig | 2 -- include/configs/ge_bx50v3.h | 24 +++++++++++++++++------- 4 files changed, 17 insertions(+), 13 deletions(-)
diff --git a/configs/ge_b450v3_defconfig b/configs/ge_b450v3_defconfig index ffa0440..98bf52e 100644 --- a/configs/ge_b450v3_defconfig +++ b/configs/ge_b450v3_defconfig @@ -8,8 +8,6 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y -CONFIG_CMD_USB=y -CONFIG_CMD_USB_MASS_STORAGE=y CONFIG_CMD_GPIO=y CONFIG_CMD_DHCP=y CONFIG_CMD_MII=y diff --git a/configs/ge_b650v3_defconfig b/configs/ge_b650v3_defconfig index b039c24..b66c98b 100644 --- a/configs/ge_b650v3_defconfig +++ b/configs/ge_b650v3_defconfig @@ -8,8 +8,6 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y -CONFIG_CMD_USB=y -CONFIG_CMD_USB_MASS_STORAGE=y CONFIG_CMD_GPIO=y CONFIG_CMD_DHCP=y CONFIG_CMD_MII=y diff --git a/configs/ge_b850v3_defconfig b/configs/ge_b850v3_defconfig index d9c8acd..1cd126a 100644 --- a/configs/ge_b850v3_defconfig +++ b/configs/ge_b850v3_defconfig @@ -8,8 +8,6 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y -CONFIG_CMD_USB=y -CONFIG_CMD_USB_MASS_STORAGE=y CONFIG_CMD_GPIO=y CONFIG_CMD_DHCP=y CONFIG_CMD_MII=y diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index 53f8689..602763f 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -78,6 +78,7 @@ #define CONFIG_DOS_PARTITION
/* USB Configs */ +#ifdef CONFIG_USB #define CONFIG_USB_EHCI #define CONFIG_USB_EHCI_MX6 #define CONFIG_USB_STORAGE @@ -99,6 +100,7 @@ #define CONFIG_G_DNL_VENDOR_NUM 0x0525 #define CONFIG_G_DNL_PRODUCT_NUM 0xa4a5 #define CONFIG_G_DNL_MANUFACTURER "Advantech" +#endif
/* Networking Configs */ #define CONFIG_FEC_MXC @@ -221,13 +223,7 @@ "bootm; " \ "fi;\0" \
-#define CONFIG_BOOTCOMMAND \ - "usb start; " \ - "setenv dev usb; " \ - "setenv devnum 0; " \ - "setenv rootdev sda1; " \ - "run tryboot; " \ - \ +#define CONFIG_MMCBOOTCOMMAND \ "setenv dev mmc; " \ "setenv rootdev mmcblk0p1; " \ \ @@ -241,9 +237,23 @@ "if mmc dev ${devnum}; then " \ "run tryboot; " \ "fi; " \ + +#define CONFIG_USBBOOTCOMMAND \ + "usb start; " \ + "setenv dev usb; " \ + "setenv devnum 0; " \ + "setenv rootdev sda1; " \ + "run tryboot; " \ \ + CONFIG_MMCBOOTCOMMAND \ "bmode usb; " \
+#ifdef CONFIG_CMD_USB +#define CONFIG_BOOTCOMMAND CONFIG_USBBOOTCOMMAND +#else +#define CONFIG_BOOTCOMMAND CONFIG_MMCBOOTCOMMAND +#endif + #define CONFIG_ARP_TIMEOUT 200UL
/* Miscellaneous configurable options */

On Mon, May 30, 2016 at 01:37:04PM +0200, Andrew Shadura wrote:
The USB support is only useful for development and shouldn't be enabled in production, so it has to be disabled in U-boot by default.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk
Acked-by: Martin Donnelly martin.donnelly@ge.com
configs/ge_b450v3_defconfig | 2 -- configs/ge_b650v3_defconfig | 2 -- configs/ge_b850v3_defconfig | 2 -- include/configs/ge_bx50v3.h | 24 +++++++++++++++++------- 4 files changed, 17 insertions(+), 13 deletions(-)
diff --git a/configs/ge_b450v3_defconfig b/configs/ge_b450v3_defconfig index ffa0440..98bf52e 100644 --- a/configs/ge_b450v3_defconfig +++ b/configs/ge_b450v3_defconfig @@ -8,8 +8,6 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y -CONFIG_CMD_USB=y -CONFIG_CMD_USB_MASS_STORAGE=y CONFIG_CMD_GPIO=y CONFIG_CMD_DHCP=y CONFIG_CMD_MII=y diff --git a/configs/ge_b650v3_defconfig b/configs/ge_b650v3_defconfig index b039c24..b66c98b 100644 --- a/configs/ge_b650v3_defconfig +++ b/configs/ge_b650v3_defconfig @@ -8,8 +8,6 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y -CONFIG_CMD_USB=y -CONFIG_CMD_USB_MASS_STORAGE=y CONFIG_CMD_GPIO=y CONFIG_CMD_DHCP=y CONFIG_CMD_MII=y diff --git a/configs/ge_b850v3_defconfig b/configs/ge_b850v3_defconfig index d9c8acd..1cd126a 100644 --- a/configs/ge_b850v3_defconfig +++ b/configs/ge_b850v3_defconfig @@ -8,8 +8,6 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y -CONFIG_CMD_USB=y -CONFIG_CMD_USB_MASS_STORAGE=y CONFIG_CMD_GPIO=y CONFIG_CMD_DHCP=y CONFIG_CMD_MII=y diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index 53f8689..602763f 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -78,6 +78,7 @@ #define CONFIG_DOS_PARTITION
/* USB Configs */ +#ifdef CONFIG_USB #define CONFIG_USB_EHCI #define CONFIG_USB_EHCI_MX6 #define CONFIG_USB_STORAGE @@ -99,6 +100,7 @@ #define CONFIG_G_DNL_VENDOR_NUM 0x0525 #define CONFIG_G_DNL_PRODUCT_NUM 0xa4a5 #define CONFIG_G_DNL_MANUFACTURER "Advantech" +#endif
/* Networking Configs */ #define CONFIG_FEC_MXC @@ -221,13 +223,7 @@ "bootm; " \ "fi;\0" \
-#define CONFIG_BOOTCOMMAND \
- "usb start; " \
- "setenv dev usb; " \
- "setenv devnum 0; " \
- "setenv rootdev sda1; " \
- "run tryboot; " \
- \
+#define CONFIG_MMCBOOTCOMMAND \ "setenv dev mmc; " \ "setenv rootdev mmcblk0p1; " \ \ @@ -241,9 +237,23 @@ "if mmc dev ${devnum}; then " \ "run tryboot; " \ "fi; " \
+#define CONFIG_USBBOOTCOMMAND \
- "usb start; " \
- "setenv dev usb; " \
- "setenv devnum 0; " \
- "setenv rootdev sda1; " \
- "run tryboot; " \ \
- CONFIG_MMCBOOTCOMMAND \ "bmode usb; " \
+#ifdef CONFIG_CMD_USB +#define CONFIG_BOOTCOMMAND CONFIG_USBBOOTCOMMAND +#else +#define CONFIG_BOOTCOMMAND CONFIG_MMCBOOTCOMMAND +#endif
#define CONFIG_ARP_TIMEOUT 200UL
/* Miscellaneous configurable options */
2.7.4

The network support is only useful for development and shouldn't be enabled in production, so it has to be disabled in U-boot by default.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk --- configs/ge_b450v3_defconfig | 4 +--- configs/ge_b650v3_defconfig | 4 +--- configs/ge_b850v3_defconfig | 4 +--- include/configs/ge_bx50v3.h | 2 ++ 4 files changed, 5 insertions(+), 9 deletions(-)
diff --git a/configs/ge_b450v3_defconfig b/configs/ge_b450v3_defconfig index 98bf52e..a8628d2 100644 --- a/configs/ge_b450v3_defconfig +++ b/configs/ge_b450v3_defconfig @@ -9,9 +9,7 @@ CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y CONFIG_CMD_GPIO=y -CONFIG_CMD_DHCP=y -CONFIG_CMD_MII=y -CONFIG_CMD_PING=y +CONFIG_CMD_NET=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y diff --git a/configs/ge_b650v3_defconfig b/configs/ge_b650v3_defconfig index b66c98b..ce39521 100644 --- a/configs/ge_b650v3_defconfig +++ b/configs/ge_b650v3_defconfig @@ -9,9 +9,7 @@ CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y CONFIG_CMD_GPIO=y -CONFIG_CMD_DHCP=y -CONFIG_CMD_MII=y -CONFIG_CMD_PING=y +CONFIG_CMD_NET=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y diff --git a/configs/ge_b850v3_defconfig b/configs/ge_b850v3_defconfig index 1cd126a..d2f6f86 100644 --- a/configs/ge_b850v3_defconfig +++ b/configs/ge_b850v3_defconfig @@ -9,9 +9,7 @@ CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y CONFIG_CMD_GPIO=y -CONFIG_CMD_DHCP=y -CONFIG_CMD_MII=y -CONFIG_CMD_PING=y +CONFIG_CMD_NET=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index 602763f..ccaa2b4 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -103,6 +103,7 @@ #endif
/* Networking Configs */ +#ifdef CONFIG_NET #define CONFIG_FEC_MXC #define CONFIG_MII #define IMX_FEC_BASE ENET_BASE_ADDR @@ -111,6 +112,7 @@ #define CONFIG_FEC_MXC_PHYADDR 4 #define CONFIG_PHYLIB #define CONFIG_PHY_ATHEROS +#endif
/* Serial Flash */ #ifdef CONFIG_CMD_SF

On Mon, May 30, 2016 at 01:37:05PM +0200, Andrew Shadura wrote:
The network support is only useful for development and shouldn't be enabled in production, so it has to be disabled in U-boot by default.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk
Acked-by: Martin Donnelly martin.donnelly@ge.com
configs/ge_b450v3_defconfig | 4 +--- configs/ge_b650v3_defconfig | 4 +--- configs/ge_b850v3_defconfig | 4 +--- include/configs/ge_bx50v3.h | 2 ++ 4 files changed, 5 insertions(+), 9 deletions(-)
diff --git a/configs/ge_b450v3_defconfig b/configs/ge_b450v3_defconfig index 98bf52e..a8628d2 100644 --- a/configs/ge_b450v3_defconfig +++ b/configs/ge_b450v3_defconfig @@ -9,9 +9,7 @@ CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y CONFIG_CMD_GPIO=y -CONFIG_CMD_DHCP=y -CONFIG_CMD_MII=y -CONFIG_CMD_PING=y +CONFIG_CMD_NET=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y diff --git a/configs/ge_b650v3_defconfig b/configs/ge_b650v3_defconfig index b66c98b..ce39521 100644 --- a/configs/ge_b650v3_defconfig +++ b/configs/ge_b650v3_defconfig @@ -9,9 +9,7 @@ CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y CONFIG_CMD_GPIO=y -CONFIG_CMD_DHCP=y -CONFIG_CMD_MII=y -CONFIG_CMD_PING=y +CONFIG_CMD_NET=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y diff --git a/configs/ge_b850v3_defconfig b/configs/ge_b850v3_defconfig index 1cd126a..d2f6f86 100644 --- a/configs/ge_b850v3_defconfig +++ b/configs/ge_b850v3_defconfig @@ -9,9 +9,7 @@ CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y CONFIG_CMD_GPIO=y -CONFIG_CMD_DHCP=y -CONFIG_CMD_MII=y -CONFIG_CMD_PING=y +CONFIG_CMD_NET=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index 602763f..ccaa2b4 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -103,6 +103,7 @@ #endif
/* Networking Configs */ +#ifdef CONFIG_NET #define CONFIG_FEC_MXC #define CONFIG_MII #define IMX_FEC_BASE ENET_BASE_ADDR @@ -111,6 +112,7 @@ #define CONFIG_FEC_MXC_PHYADDR 4 #define CONFIG_PHYLIB #define CONFIG_PHY_ATHEROS +#endif
/* Serial Flash */
#ifdef CONFIG_CMD_SF
2.7.4

The SATA support is only useful for development and shouldn't be enabled in production, so it has to be disabled in U-boot by default.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk --- include/configs/ge_bx50v3.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index ccaa2b4..98f20c6 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -60,13 +60,14 @@ #define CONFIG_MXC_OCOTP
/* SATA Configs */ -#define CONFIG_CMD_SATA +#ifdef CONFIG_CMD_SATA #define CONFIG_DWC_AHSATA #define CONFIG_SYS_SATA_MAX_DEVICE 1 #define CONFIG_DWC_AHSATA_PORT_ID 0 #define CONFIG_DWC_AHSATA_BASE_ADDR SATA_ARB_BASE_ADDR #define CONFIG_LBA48 #define CONFIG_LIBATA +#endif
/* MMC Configs */ #define CONFIG_FSL_ESDHC

On Mon, May 30, 2016 at 01:37:06PM +0200, Andrew Shadura wrote:
The SATA support is only useful for development and shouldn't be enabled in production, so it has to be disabled in U-boot by default.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk
Acked-by: Martin Donnelly martin.donnelly@ge.com
include/configs/ge_bx50v3.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index ccaa2b4..98f20c6 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -60,13 +60,14 @@ #define CONFIG_MXC_OCOTP
/* SATA Configs */ -#define CONFIG_CMD_SATA +#ifdef CONFIG_CMD_SATA #define CONFIG_DWC_AHSATA #define CONFIG_SYS_SATA_MAX_DEVICE 1 #define CONFIG_DWC_AHSATA_PORT_ID 0 #define CONFIG_DWC_AHSATA_BASE_ADDR SATA_ARB_BASE_ADDR #define CONFIG_LBA48 #define CONFIG_LIBATA +#endif
/* MMC Configs */
#define CONFIG_FSL_ESDHC
2.7.4

Disable unused FPGA, NFS, FAT and EFI support to reduce the bootloader size.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk --- configs/ge_b450v3_defconfig | 5 ++++- configs/ge_b650v3_defconfig | 5 ++++- configs/ge_b850v3_defconfig | 5 ++++- 3 files changed, 12 insertions(+), 3 deletions(-)
diff --git a/configs/ge_b450v3_defconfig b/configs/ge_b450v3_defconfig index a8628d2..d41a143 100644 --- a/configs/ge_b450v3_defconfig +++ b/configs/ge_b450v3_defconfig @@ -8,14 +8,17 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y +CONFIG_CMD_FPGA=n CONFIG_CMD_GPIO=y CONFIG_CMD_NET=n +CONFIG_CMD_NFS=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_CMD_FAT=y +CONFIG_CMD_FAT=n CONFIG_CMD_FS_GENERIC=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y CONFIG_OF_LIBFDT=y +CONFIG_EFI_LOADER=n diff --git a/configs/ge_b650v3_defconfig b/configs/ge_b650v3_defconfig index ce39521..05894fd 100644 --- a/configs/ge_b650v3_defconfig +++ b/configs/ge_b650v3_defconfig @@ -8,14 +8,17 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y +CONFIG_CMD_FPGA=n CONFIG_CMD_GPIO=y CONFIG_CMD_NET=n +CONFIG_CMD_NFS=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_CMD_FAT=y +CONFIG_CMD_FAT=n CONFIG_CMD_FS_GENERIC=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y CONFIG_OF_LIBFDT=y +CONFIG_EFI_LOADER=n diff --git a/configs/ge_b850v3_defconfig b/configs/ge_b850v3_defconfig index d2f6f86..e5521bf 100644 --- a/configs/ge_b850v3_defconfig +++ b/configs/ge_b850v3_defconfig @@ -8,14 +8,17 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y +CONFIG_CMD_FPGA=n CONFIG_CMD_GPIO=y CONFIG_CMD_NET=n +CONFIG_CMD_NFS=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_CMD_FAT=y +CONFIG_CMD_FAT=n CONFIG_CMD_FS_GENERIC=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y CONFIG_OF_LIBFDT=y +CONFIG_EFI_LOADER=n

On Mon, May 30, 2016 at 01:37:07PM +0200, Andrew Shadura wrote:
Disable unused FPGA, NFS, FAT and EFI support to reduce the bootloader size.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk
Acked-by: Martin Donnelly martin.donnelly@ge.com
configs/ge_b450v3_defconfig | 5 ++++- configs/ge_b650v3_defconfig | 5 ++++- configs/ge_b850v3_defconfig | 5 ++++- 3 files changed, 12 insertions(+), 3 deletions(-)
diff --git a/configs/ge_b450v3_defconfig b/configs/ge_b450v3_defconfig index a8628d2..d41a143 100644 --- a/configs/ge_b450v3_defconfig +++ b/configs/ge_b450v3_defconfig @@ -8,14 +8,17 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y +CONFIG_CMD_FPGA=n CONFIG_CMD_GPIO=y CONFIG_CMD_NET=n +CONFIG_CMD_NFS=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_CMD_FAT=y +CONFIG_CMD_FAT=n CONFIG_CMD_FS_GENERIC=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y CONFIG_OF_LIBFDT=y +CONFIG_EFI_LOADER=n diff --git a/configs/ge_b650v3_defconfig b/configs/ge_b650v3_defconfig index ce39521..05894fd 100644 --- a/configs/ge_b650v3_defconfig +++ b/configs/ge_b650v3_defconfig @@ -8,14 +8,17 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y +CONFIG_CMD_FPGA=n CONFIG_CMD_GPIO=y CONFIG_CMD_NET=n +CONFIG_CMD_NFS=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_CMD_FAT=y +CONFIG_CMD_FAT=n CONFIG_CMD_FS_GENERIC=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y CONFIG_OF_LIBFDT=y +CONFIG_EFI_LOADER=n diff --git a/configs/ge_b850v3_defconfig b/configs/ge_b850v3_defconfig index d2f6f86..e5521bf 100644 --- a/configs/ge_b850v3_defconfig +++ b/configs/ge_b850v3_defconfig @@ -8,14 +8,17 @@ CONFIG_CMD_BOOTZ=y CONFIG_CMD_MMC=y CONFIG_CMD_SF=y CONFIG_CMD_I2C=y +CONFIG_CMD_FPGA=n CONFIG_CMD_GPIO=y CONFIG_CMD_NET=n +CONFIG_CMD_NFS=n CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_CMD_FAT=y +CONFIG_CMD_FAT=n CONFIG_CMD_FS_GENERIC=y CONFIG_SPI_FLASH=y CONFIG_SPI_FLASH_STMICRO=y CONFIG_OF_LIBFDT=y
+CONFIG_EFI_LOADER=n
2.7.4

From: Kimmo Surakka kimmo.surakka@ge.com
Add missing ${partnum} to set rootdev correctly when booting from USB or MMC.
Signed-off-by: Kimmo Surakka kimmo.surakka@ge.com [Rebased against v2016.05 and adjusted the variable name] Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk --- include/configs/ge_bx50v3.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index 98f20c6..4033460 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -228,12 +228,12 @@
#define CONFIG_MMCBOOTCOMMAND \ "setenv dev mmc; " \ - "setenv rootdev mmcblk0p1; " \ + "setenv rootdev mmcblk0p${partnum}; " \ \ "setenv devnum ${sddev}; " \ "if mmc dev ${devnum}; then " \ "run tryboot; " \ - "setenv rootdev mmcblk1p1; " \ + "setenv rootdev mmcblk1p${partnum}; " \ "fi; " \ \ "setenv devnum ${emmcdev}; " \ @@ -245,7 +245,7 @@ "usb start; " \ "setenv dev usb; " \ "setenv devnum 0; " \ - "setenv rootdev sda1; " \ + "setenv rootdev sda${partnum}; " \ "run tryboot; " \ \ CONFIG_MMCBOOTCOMMAND \

On Mon, May 30, 2016 at 01:37:08PM +0200, Andrew Shadura wrote:
From: Kimmo Surakka kimmo.surakka@ge.com
Add missing ${partnum} to set rootdev correctly when booting from USB or MMC.
Signed-off-by: Kimmo Surakka kimmo.surakka@ge.com [Rebased against v2016.05 and adjusted the variable name] Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk
Acked-by: Martin Donnelly martin.donnelly@ge.com
include/configs/ge_bx50v3.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/include/configs/ge_bx50v3.h b/include/configs/ge_bx50v3.h index 98f20c6..4033460 100644 --- a/include/configs/ge_bx50v3.h +++ b/include/configs/ge_bx50v3.h @@ -228,12 +228,12 @@
#define CONFIG_MMCBOOTCOMMAND \ "setenv dev mmc; " \
- "setenv rootdev mmcblk0p1; " \
- "setenv rootdev mmcblk0p${partnum}; " \ \ "setenv devnum ${sddev}; " \ "if mmc dev ${devnum}; then " \ "run tryboot; " \
"setenv rootdev mmcblk1p1; " \
"fi; " \ \ "setenv devnum ${emmcdev}; " \"setenv rootdev mmcblk1p${partnum}; " \
@@ -245,7 +245,7 @@ "usb start; " \ "setenv dev usb; " \ "setenv devnum 0; " \
- "setenv rootdev sda1; " \
- "setenv rootdev sda${partnum}; " \ "run tryboot; " \ \ CONFIG_MMCBOOTCOMMAND \
-- 2.7.4

On Mon, May 30, 2016 at 01:37:01PM +0200, Andrew Shadura wrote:
detect_baseboard() function doesn't depend on CONFIG_VIDEO_IPUV3. Make sure it's available when CONFIG_VIDEO_IPUV3 is off.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk
Acked-by: Martin Donnelly <martin.donnelly@.ge.com>
board/ge/bx50v3/bx50v3.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/board/ge/bx50v3/bx50v3.c b/board/ge/bx50v3/bx50v3.c index ff8f4d7..e167cd5 100644 --- a/board/ge/bx50v3/bx50v3.c +++ b/board/ge/bx50v3/bx50v3.c @@ -321,6 +321,15 @@ int board_phy_config(struct phy_device *phydev) return 0; }
+static int detect_baseboard(struct display_info_t const *dev) +{
- if (IS_ENABLED(CONFIG_TARGET_GE_B450V3) ||
IS_ENABLED(CONFIG_TARGET_GE_B650V3))
return 1;
- return 0;
+}
#if defined(CONFIG_VIDEO_IPUV3) static iomux_v3_cfg_t const backlight_pads[] = { /* Power for LVDS Display */ @@ -345,15 +354,6 @@ int board_cfb_skip(void) return 0; }
-static int detect_baseboard(struct display_info_t const *dev) -{
- if (IS_ENABLED(CONFIG_TARGET_GE_B450V3) ||
IS_ENABLED(CONFIG_TARGET_GE_B650V3))
return 1;
- return 0;
-}
struct display_info_t const displays[] = {{ .bus = -1, .addr = -1, -- 2.7.4

Hi Andrew,
On 30/05/2016 13:37, Andrew Shadura wrote:
detect_baseboard() function doesn't depend on CONFIG_VIDEO_IPUV3. Make sure it's available when CONFIG_VIDEO_IPUV3 is off.
Signed-off-by: Andrew Shadura andrew.shadura@collabora.co.uk
board/ge/bx50v3/bx50v3.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/board/ge/bx50v3/bx50v3.c b/board/ge/bx50v3/bx50v3.c index ff8f4d7..e167cd5 100644 --- a/board/ge/bx50v3/bx50v3.c +++ b/board/ge/bx50v3/bx50v3.c @@ -321,6 +321,15 @@ int board_phy_config(struct phy_device *phydev) return 0; }
+static int detect_baseboard(struct display_info_t const *dev) +{
- if (IS_ENABLED(CONFIG_TARGET_GE_B450V3) ||
IS_ENABLED(CONFIG_TARGET_GE_B650V3))
return 1;
- return 0;
+}
#if defined(CONFIG_VIDEO_IPUV3) static iomux_v3_cfg_t const backlight_pads[] = { /* Power for LVDS Display */ @@ -345,15 +354,6 @@ int board_cfb_skip(void) return 0; }
-static int detect_baseboard(struct display_info_t const *dev) -{
- if (IS_ENABLED(CONFIG_TARGET_GE_B450V3) ||
IS_ENABLED(CONFIG_TARGET_GE_B650V3))
return 1;
- return 0;
-}
struct display_info_t const displays[] = {{ .bus = -1, .addr = -1,
But this generates a warning:
w+board/ge/bx50v3/bx50v3.c:324:12: warning: 'detect_baseboard' defined but not used [-Wunused-function]
Why do you export it if you do not need it ? It is used only in the hdmi detection, that means just if IPU is set.
Best regards, Stefano Babic

On 31/05/16 17:35, Stefano Babic wrote:
But this generates a warning:
w+board/ge/bx50v3/bx50v3.c:324:12: warning: 'detect_baseboard' defined but not used [-Wunused-function]
Why do you export it if you do not need it ? It is used only in the hdmi detection, that means just if IPU is set.
Strange, it wouldn't compile here unless I did this. Apparently it *was* used from somewhere else, but maybe it's no longer. Let me double check.

On 31/05/16 17:55, Andrew Shadura wrote:
On 31/05/16 17:35, Stefano Babic wrote:
But this generates a warning:
w+board/ge/bx50v3/bx50v3.c:324:12: warning: 'detect_baseboard' defined but not used [-Wunused-function]
Why do you export it if you do not need it ? It is used only in the hdmi detection, that means just if IPU is set.
Strange, it wouldn't compile here unless I did this. Apparently it *was* used from somewhere else, but maybe it's no longer. Let me double check.
It seems it was a mistake and this patch may indeed not be needed.
Stefano, are there any comments on other patches?

On 07/06/2016 10:27, Andrew Shadura wrote:
On 31/05/16 17:55, Andrew Shadura wrote:
On 31/05/16 17:35, Stefano Babic wrote:
But this generates a warning:
w+board/ge/bx50v3/bx50v3.c:324:12: warning: 'detect_baseboard' defined but not used [-Wunused-function]
Why do you export it if you do not need it ? It is used only in the hdmi detection, that means just if IPU is set.
Strange, it wouldn't compile here unless I did this. Apparently it *was* used from somewhere else, but maybe it's no longer. Let me double check.
It seems it was a mistake and this patch may indeed not be needed.
Stefano, are there any comments on other patches?
Other patches are fine. Then we agree to apply patches 2-8, and I drop 1/8.
Regards, Stefano
participants (3)
-
Andrew Shadura
-
Martin Donnelly
-
Stefano Babic