Hi, On Wed, May 7, 2014 at 10:12 AM, Eric Nelson <eric.nelson@xxxxxxxxxxxxxxxxxxx> wrote: > Hi all, > > I suspect that this has been discussed previously, but I'm a > N00b to DT and Google hasn't helped identify a discussion > on the list. > > While getting my feet wet with DTS, I was quite surprised to > see that there's no support for making parts of DTS files > conditional on the kernel configuration. > > We often cost-optimize BOMs for our standard boards and omit > bits and pieces not needed for a particular build, and > it would be nice to surround optional components with > conditionals: > > #ifdef CONFIG_BLAH > #endif > > Please advise, The DTS is independent on what drivers the kernel is actually enabling. It should focus on what is actually there on hardware, and not what is enabled in software. I think I know where you're coming from on this -- on some board-file setups people used to not register the platform_device if the driver wasn't configured. That was also not really a good way to do it, but it made a bit more sense there, since you'd save the few bytes used by the platform_device/platform_data structures. -Olof -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html