Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33142 )
Change subject: Kconfig: Create coreboot separate stage kconfigs ......................................................................
Patch Set 2:
Patch Set 2:
Do you have a proposal for handling all the various stages and a way to select them in the positive as well as handling the user-configurable options? Just add kconfigs?
- assert in positive *no* <STAGE> needed
For the ramstage, use if (CONFIG(RAMPAYLOAD) and for the verstage if (!CONFIG(SEPARATE_VERSTAGE))? I'm not sure I understand the question.
- assert in positive *yes* <STAGE> needed, but it depends on !*no* <STAGE>? And default of y?
And this would assert the opposite (!RAMPAYLOAD or SEPARATE_VERSTAGE)? Not sure what you mean by "depends on !*no* <STAGE>".
If we want explicit options, we could add them like this:
config BOOTBLOCK_ENABLED default y #always 'y' in current coreboot
config VERSTAGE_ENABLED default y if SEPARATE_VERSTAGE default n
config ROMSTAGE_ENABLED default y #always 'y' in current coreboot
config POSTCAR_ENABLED default y if POSTCAR_STAGE default n
config RAMSTAGE_ENABLED default n if RAMPAYLOAD default y
But I don't think it's really worth adding those until we have a case where two orthogonal features would both disable the same default stage, since it does not come up very often. We can just use the respective options as a stand-in for now.)
This is my point about the requirements. We need to be able to select which stages get put into the build itself. And we should be able to do that from platform or mainboard code. What you put up doesn't allow one to mix and match the stages selected. i.e. the 'current coreboot' doesn't meet the new requirements.