diff mbox series

[U-Boot,3/3] ARM: imx6q_logic: With SPL_OF_CONTROL enabled, remove MMC init

Message ID 20190523191132.17439-3-aford173@gmail.com
State Accepted
Commit 8f4691e31a18254d225524a4b018b8cbcddc70b1
Delegated to: Stefano Babic
Headers show
Series [U-Boot,1/3] spl: imx6: Let spl_boot_device return USDHC1 or USDHC2 | expand

Commit Message

Adam Ford May 23, 2019, 7:11 p.m. UTC
Since the board uses SPL_OF_CONTROL now, we don't need to
explicitly initialize the MMC driver, but we still need to
pinmux the corresponding pins.  This patch removes the
initialization code and leave just the muxing behind.

Signed-off-by: Adam Ford <aford173@gmail.com>

Comments

Stefano Babic July 20, 2019, 9:06 a.m. UTC | #1
> Since the board uses SPL_OF_CONTROL now, we don't need to
> explicitly initialize the MMC driver, but we still need to
> pinmux the corresponding pins.  This patch removes the
> initialization code and leave just the muxing behind.
> Signed-off-by: Adam Ford <aford173@gmail.com>
> diff --git a/board/logicpd/imx6/imx6logic.c b/board/logicpd/imx6/imx6logic.c
> index b17a3b1d39..ab1c7f266e 100644
> --- a/board/logicpd/imx6/imx6logic.c
> +++ b/board/logicpd/imx6/imx6logic.c
> @@ -222,25 +222,15 @@ int board_mmc_init(bd_t *bis)
>  	switch (reg) {
>  	case 0:
>  		SETUP_IOMUX_PADS(usdhc1_pads);
> -		usdhc_cfg[0].esdhc_base = USDHC1_BASE_ADDR;
> -		usdhc_cfg[0].sdhc_clk = mxc_get_clock(MXC_ESDHC_CLK);
> -		gd->arch.sdhc_clk = usdhc_cfg[0].sdhc_clk;
>  		break;
>  	case 1:
>  		SETUP_IOMUX_PADS(usdhc2_pads);
> -		usdhc_cfg[1].esdhc_base = USDHC2_BASE_ADDR;
> -		usdhc_cfg[1].sdhc_clk = mxc_get_clock(MXC_ESDHC2_CLK);
> -		gd->arch.sdhc_clk = usdhc_cfg[1].sdhc_clk;
>  		break;
>  	}
>  
> -	return fsl_esdhc_initialize(bis, &usdhc_cfg[reg]);
> +	return 0;
>  }
>  
> -int board_mmc_getcd(struct mmc *mmc)
> -{
> -	return 1;
> -}
>  #endif
>  
>  static void ccgr_init(void)

Applied to u-boot-imx, master, thanks !

Best regards,
Stefano Babic
diff mbox series

Patch

diff --git a/board/logicpd/imx6/imx6logic.c b/board/logicpd/imx6/imx6logic.c
index b17a3b1d39..ab1c7f266e 100644
--- a/board/logicpd/imx6/imx6logic.c
+++ b/board/logicpd/imx6/imx6logic.c
@@ -222,25 +222,15 @@  int board_mmc_init(bd_t *bis)
 	switch (reg) {
 	case 0:
 		SETUP_IOMUX_PADS(usdhc1_pads);
-		usdhc_cfg[0].esdhc_base = USDHC1_BASE_ADDR;
-		usdhc_cfg[0].sdhc_clk = mxc_get_clock(MXC_ESDHC_CLK);
-		gd->arch.sdhc_clk = usdhc_cfg[0].sdhc_clk;
 		break;
 	case 1:
 		SETUP_IOMUX_PADS(usdhc2_pads);
-		usdhc_cfg[1].esdhc_base = USDHC2_BASE_ADDR;
-		usdhc_cfg[1].sdhc_clk = mxc_get_clock(MXC_ESDHC2_CLK);
-		gd->arch.sdhc_clk = usdhc_cfg[1].sdhc_clk;
 		break;
 	}
 
-	return fsl_esdhc_initialize(bis, &usdhc_cfg[reg]);
+	return 0;
 }
 
-int board_mmc_getcd(struct mmc *mmc)
-{
-	return 1;
-}
 #endif
 
 static void ccgr_init(void)