On Thu, May 17, 2012 at 12:13:20PM +1200, Charles Manning wrote: > Hi All > > My understanding of the way SPL is intended to be configured is: > > (a) You have one config file for both SPL and u-boot.
Yes. > (b) SPL features are selected via SPL-specific options. For some parts, yes. Note that SPL does use -ffunction-sections/-fdata-sections/--gc-sections. > I have a need to build SPL with MMC/FAT support, but I don't want > u-boot to have MMC/FAT support. This is a new challenge, yes. > I do however see that quite a few SPL feature selections don't use SPL > config definitions though which would seem to violate (b) above. > > eg.drivers/mmc/Makefile contains > COBJS-$(CONFIG_GENERIC_MMC) += mmc.o > > It seems to me there are three ways to address this: > > A) Change all those Makefiles to something like: > > ifdef CONFIG_SPL_BUILD > COBJS-$(CONFIG_SPL_MMC_SUPPORT) += mmc.o > else > COBJS-$(CONFIG_GENERIC_MMC) += mmc.o > endif > > > B) Modifying the config file with something like > > #ifdef CONFIG_SPL_BUILD > #define CONFIG_GENERIC_MMC > ... > #endif > > C) Separate config files. One for SPL and the other for u-boot. > > Which is the best way to do this? I think (B) is the method to go with. We already do this with certain things like CONFIG_SKIP_LOW_LEVEL_INIT. -- Tom _______________________________________________ U-Boot mailing list [email protected] http://lists.denx.de/mailman/listinfo/u-boot

