[U-Boot] [PATCH 7/9] imx: esdhc: Needed to use in imx-regs.h defined address

Stefano Babic sbabic at denx.de
Wed Apr 18 12:30:55 CEST 2012


On 18/04/2012 11:11, Timo Ketola wrote:

> 
> Ok, I was afraid about something like that and tried first to include it
> in board configuration but that broke something else (at least arm926ejs
> didn't compile any more).
> 
>> By the way, why do you need it if you do not use that macro ?
> 
> I use it in my board (support of which I'm preparing to send)
> configuration file and I think it is annoying to write a literal
> constant there which is already defined in imx-regs.h.

fsl_esdhc.c includes config.h. If your board configuration file includes
imx-regs.h, as most i.MX boards do, the file is automatically included,
I suppose.

> 
> PPC seems to use a predefined macro from asm/immap_8xxx.h files. Where
> is that file included?

It is a different way. The board configuration file includes the
register description file, so for example immap_86xx.h, immap_85xx.h, or
imx-regs.h, and defines CONFIG_SYS_FSL_ESDHC_ADDR using its own specific
macro, if any, for example:

#define CONFIG_SYS_FSL_ESDHC_ADDR       CONFIG_SYS_MPC85xx_ESDHC_ADDR

Why is it not enough for you to set in your board configuration file:

#define CONFIG_SYS_FSL_ESDHC_ADDR       IMX_MMC_SDHC1_BASE

Best regards,
Stefano Babic

-- 
=====================================================================
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
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
=====================================================================


More information about the U-Boot mailing list