imx: imx8qm_rom7720: added missing USDHC Base address defines
Subsystems (2)
PATCH 1/2 imx: imx8qm_rom7720: added missing USDHC Base address defines
Added missing USDHC Base address defines
--- include/configs/imx8qm_rom7720.h | 4 ++++ 1 file changed, 4 insertions(+)
include/configs/imx8qm_rom7720.h +4 -0
@@ -18,6 +18,10 @@#define CONFIG_FSL_USDHC #define CONFIG_SYS_FSL_ESDHC_ADDR 0 +#define USDHC1_BASE_ADDR 0x5B010000 +#define USDHC2_BASE_ADDR 0x5B020000 +#define USDHC3_BASE_ADDR 0x5B030000 +#define CONFIG_SUPPORT_EMMC_BOOT /* eMMC specific */ #define CONFIG_ENV_OVERWRITE
Signature · 1 line
2.17.1
PATCH 2/2 imx: imx8qm_rom7720_a1: fix broken fsl_esdhc_imx conversion
Fix broken fsl_esdhc_imx conversion
--- board/advantech/imx8qm_rom7720_a1/spl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
board/advantech/imx8qm_rom7720_a1/spl.c +2 -2
@@ -55,7 +55,7 @@ DECLARE_GLOBAL_DATA_PTR; (SC_PAD_ISO_OFF << PADRING_LPCONFIG_SHIFT) | \ (SC_PAD_28FDSOI_DSE_DV_HIGH << PADRING_DSE_SHIFT) | \ (SC_PAD_28FDSOI_PS_PU << PADRING_PULL_SHIFT)) -#ifdef CONFIG_FSL_ESDHC +#ifdef CONFIG_FSL_ESDHC_IMX #define USDHC1_CD_GPIO IMX_GPIO_NR(5, 22)#define USDHC2_CD_GPIO IMX_GPIO_NR(4, 12)
@@ -164,7 +164,7 @@ int board_mmc_getcd(struct mmc *mmc) return ret; } -#endif /* CONFIG_FSL_ESDHC */ +#endif /* CONFIG_FSL_ESDHC_IMX */ void spl_board_init (void ) {
Signature · 1 line
2.17.1
Fabio Estevam
reviewerPATCH 2/2 imx: imx8qm_rom7720_a1: fix broken fsl_esdhc_imx conversion
Quoted 4 lines · Oliver Graute
Fix broken
fsl_esdhc_imxconversionSigned-off-by Oliver Graute <[email protected]>
PATCH 2/2 imx: imx8qm_rom7720_a1: fix broken fsl_esdhc_imx conversion
In reply to Oliver GrauteQuoted 28 lines · Oliver Graute
Fix broken
fsl_esdhc_imxconversionSigned-off-by Oliver Graute <[email protected]>Cc Stefano Babic <[email protected]>Cc Fabio Estevam <[email protected]>Cc Peng Fan <[email protected]>Cc Simon Glass <[email protected]>Cc Ye Li <[email protected]>Cc uboot-imx <[email protected]>--- board/advantech/imx8qm_rom7720_a1/spl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)board/advantech/imx8qm_rom7720_a1/spl.c +1
-1@@ -55,7 +55,7 @@ DECLARE_GLOBAL_DATA_PTR; (SC_PAD_ISO_OFF << PADRING_LPCONFIG_SHIFT) | \ (SC_PAD_28FDSOI_DSE_DV_HIGH << PADRING_DSE_SHIFT) | \ (SC_PAD_28FDSOI_PS_PU << PADRING_PULL_SHIFT)) -#ifdef CONFIG_FSL_ESDHC +#ifdef CONFIG_FSL_ESDHC_IMX #define USDHC1_CD_GPIO IMX_GPIO_NR(5, 22)#define USDHC2_CD_GPIO IMX_GPIO_NR(4, 12)
board/advantech/imx8qm_rom7720_a1/spl.c int board_mmc_getcd(struct mmc *mmc) · line 170
Quoted 8 lines
board/advantech/imx8qm_rom7720_a1/spl.c +1
-1@@ -164,7 +164,7 @@ int board_mmc_getcd(struct mmc *mmc) return ret; } -#endif /* CONFIG_FSL_ESDHC */ +#endif /* CONFIG_FSL_ESDHC_IMX */ void spl_board_init (void ) {
I agree to merge this, now it is enabled, code is compiled and I get a warning:
aarch64: w+ imx8qm_rom7720_a1_4G
functional
+ 115 | init_clk_usdhc(0); + | ^~~~~~~~~~~~~~
w+board/advantech/imx8qm_rom7720_a1/spl.c:115:4: warning: implicit declaration of function 'init_clk_usdhc' [-Wimplicit-function-declaration] w+board/advantech/imx8qm_rom7720_a1/spl.c:137:9: warning: implicit declaration of function 'fsl_esdhc_initialize'; did you mean 'eth_initialize'? [-Wimplicit-function-declaration]
Can you check and repost ? Thanks !
Best regards,
Stefano Babic
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de =====================================================================
PATCH 2/2 imx: imx8qm_rom7720_a1: fix broken fsl_esdhc_imx conversion
Quoted 46 lines · Stefano Babic
Quoted 28 lines · Oliver Graute
Fix broken
fsl_esdhc_imxconversionSigned-off-by Oliver Graute <[email protected]>Cc Stefano Babic <[email protected]>Cc Fabio Estevam <[email protected]>Cc Peng Fan <[email protected]>Cc Simon Glass <[email protected]>Cc Ye Li <[email protected]>Cc uboot-imx <[email protected]>--- board/advantech/imx8qm_rom7720_a1/spl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)board/advantech/imx8qm_rom7720_a1/spl.c +1
-1@@ -55,7 +55,7 @@ DECLARE_GLOBAL_DATA_PTR; (SC_PAD_ISO_OFF << PADRING_LPCONFIG_SHIFT) | \ (SC_PAD_28FDSOI_DSE_DV_HIGH << PADRING_DSE_SHIFT) | \ (SC_PAD_28FDSOI_PS_PU << PADRING_PULL_SHIFT)) -#ifdef CONFIG_FSL_ESDHC +#ifdef CONFIG_FSL_ESDHC_IMX #define USDHC1_CD_GPIO IMX_GPIO_NR(5, 22)#define USDHC2_CD_GPIO IMX_GPIO_NR(4, 12)board/advantech/imx8qm_rom7720_a1/spl.c int board_mmc_getcd(struct mmc *mmc) · line 170
Quoted 8 lines
board/advantech/imx8qm_rom7720_a1/spl.c +1
-1@@ -164,7 +164,7 @@ int board_mmc_getcd(struct mmc *mmc) return ret; } -#endif /* CONFIG_FSL_ESDHC */ +#endif /* CONFIG_FSL_ESDHC_IMX */ void spl_board_init (void ) {I agree to merge this, now it is enabled, code is compiled and I get a warning:
aarch64: w+ imx8qm_rom7720_a1_4Gfunctional
(quoted diff) +2
-0+ 115 | init_clk_usdhc(0); + | ^~~~~~~~~~~~~~
Quoted 2 lines
w+board/advantech/imx8qm_rom7720_a1/spl.c:115:4: warning: implicit declaration of function 'init_clk_usdhc' [-Wimplicit-function-declaration]
is this the right place to fix this warning?
arch/arm/include/asm/arch-imx8/clock.h +1 -0
@@ -23,5 +23,6 @@ enum mxc_clock { };u32 mxc_get_clock (enum mxc_clock clk); +void init_clk_usdhc (u32 index);
Quoted 3 lines
w+board/advantech/imx8qm_rom7720_a1/spl.c:137:9: warning: implicit declaration of function 'fsl_esdhc_initialize'; did you mean 'eth_initialize'? [-Wimplicit-function-declaration]
I`ll replace this to fix this warning
+++ b/board/advantech/imx8qm_rom7720_a1/spl.c
@@ -8,7 +8,7 @@
#include <init.h>
#include <log.h>
#include <spl.h>
-#include <fsl_esdhc.h>
+#include <fsl_esdhc_imx.h>
Best regards,
Oliver
PATCH 2/2 imx: imx8qm_rom7720_a1: fix broken fsl_esdhc_imx conversion
Hi Oliver,
sorry, lost your mail, and I see your question is still open:
Quoted 55 lines · Oliver Graute
Quoted 46 lines · Stefano Babic
Quoted 28 lines · Oliver Graute
Fix broken
fsl_esdhc_imxconversionSigned-off-by Oliver Graute <[email protected]>Cc Stefano Babic <[email protected]>Cc Fabio Estevam <[email protected]>Cc Peng Fan <[email protected]>Cc Simon Glass <[email protected]>Cc Ye Li <[email protected]>Cc uboot-imx <[email protected]>--- board/advantech/imx8qm_rom7720_a1/spl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)board/advantech/imx8qm_rom7720_a1/spl.c +1
-1@@ -55,7 +55,7 @@ DECLARE_GLOBAL_DATA_PTR; (SC_PAD_ISO_OFF << PADRING_LPCONFIG_SHIFT) | \ (SC_PAD_28FDSOI_DSE_DV_HIGH << PADRING_DSE_SHIFT) | \ (SC_PAD_28FDSOI_PS_PU << PADRING_PULL_SHIFT)) -#ifdef CONFIG_FSL_ESDHC +#ifdef CONFIG_FSL_ESDHC_IMX #define USDHC1_CD_GPIO IMX_GPIO_NR(5, 22)#define USDHC2_CD_GPIO IMX_GPIO_NR(4, 12)board/advantech/imx8qm_rom7720_a1/spl.c int board_mmc_getcd(struct mmc *mmc) · line 170
Quoted 8 lines
board/advantech/imx8qm_rom7720_a1/spl.c +1
-1@@ -164,7 +164,7 @@ int board_mmc_getcd(struct mmc *mmc) return ret; } -#endif /* CONFIG_FSL_ESDHC */ +#endif /* CONFIG_FSL_ESDHC_IMX */ void spl_board_init (void ) {I agree to merge this, now it is enabled, code is compiled and I get a warning:
aarch64: w+ imx8qm_rom7720_a1_4Gfunctional
(quoted diff) +2
-0+ 115 | init_clk_usdhc(0); + | ^~~~~~~~~~~~~~Quoted 2 lines
w+board/advantech/imx8qm_rom7720_a1/spl.c:115:4: warning: implicit declaration of function 'init_clk_usdhc' [-Wimplicit-function-declaration]is this the right place to fix this warning?
arch/arm/include/asm/arch-imx8/clock.h enum mxc_clock { · line 27
Quoted 5 lines
arch/arm/include/asm/arch-imx8/clock.h +1
-0@@ -23,5 +23,6 @@ enum mxc_clock { };u32 mxc_get_clock (enum mxc_clock clk); +void init_clk_usdhc (u32 index);
I think yes, we have the same for imx8m.
Quoted 17 lines
Quoted 4 lines
w+board/advantech/imx8qm_rom7720_a1/spl.c:137:9: warning: implicit declaration of function 'fsl_esdhc_initialize'; did you mean 'eth_initialize'? [-Wimplicit-function-declaration]I`ll replace this to fix this warning
+++
b/board/advantech/imx8qm_rom7720_a1/spl.carch/arm/include/asm/arch-imx8/clock.h +1
-1@@ -8,7 +8,7 @@#include <init.h> #include <log.h> #include <spl.h> -#include <fsl_esdhc.h> +#include <fsl_esdhc_imx.h> Best regards,
Quoted 2 lines
Oliver
Regards,
Stefano
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de =====================================================================
Fabio Estevam
reviewerPATCH 1/2 imx: imx8qm_rom7720: added missing USDHC Base address defines
In reply to Oliver GrauteHi Oliver,
include/configs/imx8qm_rom7720.h line 23
Quoted 3 lines · Oliver Graute
include/configs/imx8qm_rom7720.h +3
-0+#define USDHC1_BASE_ADDR 0x5B010000 +#define USDHC2_BASE_ADDR 0x5B020000 +#define USDHC3_BASE_ADDR 0x5B030000
These defines would be better placed in a common SoC header file instead of in the board file.
It is OK for now to do like this and we can do a cleanup later: