mx6sabresd: Do not use DM with SPL
PATCH 1/3 mx6sabresd: Do not use DM with SPL
With CONFIG_SPL_DM enabled the board does not boot:
U-Boot SPL 2019.07-rc2 (May 16 2019 - 14:28:55 -0300) Trying to boot from MMC1
spl: could not find mmc device 0. error: -19
SPL: failed to boot from all boot devices
### ERROR ### Please RESET the board ###
Remove such option, so that we can boot the board.
---
Hi,
If someone wants to fix the boot issue with CONFIG_SPL_DM=y, please submit a patch, as I don't know what is the proper fix here.
Also, there is also the need for applying Peng's fix for the framebuffer hang:
https://lists.denx.de/pipermail/u-boot/2019-April/366424.html
Thanks
configs/mx6sabresd_defconfig | 1 - 1 file changed, 1 deletion(-)
configs/mx6sabresd_defconfig +0 -1
@@ -65,7 +65,6 @@ CONFIG_SPL_MULTI_DTB_FIT=y CONFIG_SPL_OF_LIST="imx6dl-sabresd imx6q-sabresd imx6qp-sabresd" CONFIG_ENV_IS_IN_MMC=y CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y -CONFIG_SPL_DM=y CONFIG_USB_FUNCTION_FASTBOOT=y CONFIG_FASTBOOT_BUF_ADDR=0x12000000 CONFIG_FASTBOOT_BUF_SIZE=0x10000000
Signature · 1 line
2.17.1
PATCH 2/3 mx6sabresd: Select pinctrl driver
With the conversion to DM we should select the pinctrl driver.
--- configs/mx6sabresd_defconfig | 2 ++ 1 file changed, 2 insertions(+)
configs/mx6sabresd_defconfig +2 -0
@@ -81,6 +81,8 @@ CONFIG_SF_DEFAULT_SPEED=20000000 CONFIG_SPI_FLASH_STMICRO=y CONFIG_PHYLIB=y CONFIG_MII=y +CONFIG_PINCTRL=y +CONFIG_PINCTRL_IMX6=y CONFIG_PCI=y CONFIG_DM_REGULATOR=y CONFIG_SPI=y
Signature · 1 line
2.17.1
PATCH 3/3 mx6sabresd: Remove U-Boot proper mmc initialization
In reply to Fabio EstevamAfter the conversion to DM there is no need to have mmc initialization code inside U-Boot proper.
Remove the unneeded code.
--- board/freescale/mx6sabresd/mx6sabresd.c | 44 ------------------------- 1 file changed, 44 deletions(-)
board/freescale/mx6sabresd/mx6sabresd.c +0 -44
@@ -287,49 +287,6 @@ int board_mmc_getcd(struct mmc *mmc)int board_mmc_init (bd_t *bis) { -#ifndef CONFIG_SPL_BUILD -int ret; -int i; - -/* -* According to the board_mmc_init() the following map is done: -* (U-Boot device node) (Physical Port) -* mmc0 SD2 -* mmc1 SD3 -* mmc2 eMMC -*/ -for (i =0 ; i <CONFIG_SYS_FSL_USDHC_NUM ; i++) { -switch (i) { -case 0 : -SETUP_IOMUX_PADS (usdhc2_pads); -gpio_request (USDHC2_CD_GPIO ,"USDHC2 CD" ); -gpio_direction_input (USDHC2_CD_GPIO ); - usdhc_cfg[0 ].sdhc_clk =mxc_get_clock (MXC_ESDHC2_CLK ); -break ; -case 1 : -SETUP_IOMUX_PADS (usdhc3_pads); -gpio_request (USDHC3_CD_GPIO ,"USDHC3 CD" ); -gpio_direction_input (USDHC3_CD_GPIO ); - usdhc_cfg[1 ].sdhc_clk =mxc_get_clock (MXC_ESDHC3_CLK ); -break ; -case 2 : -SETUP_IOMUX_PADS (usdhc4_pads); - usdhc_cfg[2 ].sdhc_clk =mxc_get_clock (MXC_ESDHC4_CLK ); -break ; -default : -printf ("Warning: you configured more USDHC controllers" -"(%d) then supported by the board (%d)\n" , - i +1 ,CONFIG_SYS_FSL_USDHC_NUM ); -return -EINVAL ; - } - - ret =fsl_esdhc_initialize (bis, &usdhc_cfg[i]); -if (ret) -return ret; - } - -return 0 ; -#else struct src *psrc = (struct src *)SRC_BASE_ADDR ;unsigned reg =readl (&psrc->sbmr1) >>11 ;/*
@@ -363,7 +320,6 @@ int board_mmc_init(bd_t *bis) }return fsl_esdhc_initialize (bis, &usdhc_cfg[0 ]); -#endif }#endif
Signature · 1 line
2.17.1