On Mon, Mar 23, 2009 at 04:44:20PM +0530, Manikandan Pillai wrote: > diff --git a/cpu/arm_cortexa8/omap3/mem.c b/cpu/arm_cortexa8/omap3/mem.c > index 3cc22c4..6808eea 100644 > --- a/cpu/arm_cortexa8/omap3/mem.c > +++ b/cpu/arm_cortexa8/omap3/mem.c [snip] > +#if defined(CONFIG_ENV_IS_RUNTIME_SEL) > +extern env_t *env_ptr; > +extern char *nand_env_name_spec; > +extern char *onenand_env_name_spec; > +extern env_t *nand_env_ptr; > +extern env_t *onenand_env_ptr; > + > +extern void onenand_init(void); > +extern int nand_scan_ident(struct mtd_info *mtd, int maxchips);
Platform code should not have this level of knowledge of common internals. There should be one function call that platform code can make to tell the rest of u-boot where the flash is. > #if defined(CONFIG_CMD_NAND) > +u32 is_nand; This is not an acceptable global variable name. > +extern nand_info_t nand_info[2]; And what if that is not the size of nand_info? At least use CONFIG_SYS_MAX_NAND_DEVICE. > +#if defined(CONFIG_ENV_IS_RUNTIME_SEL) > +char *env_name_spec; > +env_get_char_spec_p env_get_char_spec; > +env_init_p env_init; > +saveenv_p saveenv; > +env_relocate_spec_p env_relocate_spec; So now the common internals are not just referenced in platform code, but they reside there? -Scott _______________________________________________ U-Boot mailing list [email protected] http://lists.denx.de/mailman/listinfo/u-boot

