Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33112 )
Change subject: Kconfig: Align kconfigs with correct stage configs ......................................................................
Patch Set 2:
Patch Set 2:
One thing to note is that COMPRESS_RAMSTAGE doesn't actually always *just* compress the ramstage. It sets CBFS_COMPRESS_FLAG in the Makefile which is then used to compress a variety of interesting ramstage-related things (e.g. some reference code blob in the main Makefile.inc, and DRAM configuration files loaded by a couple of Arm boards).
I think our compression configs are already in a somewhat bad state and would just be piling on to that. The problem is that most of the time you don't really care about the thing that is compressed, you care about the thing that loads it (because that's what needs to have the respective decompression library linked in). That why we generally bundle up platform-specific stuff that's loaded from the romstage together with ramstage compression and not with romstage compression. So maybe we should reorganize these options to just be called "pre-RAM compression" (or loaded-from-verstage-and-earlier, except for bootblock compression which is completely its own thing) and "post-RAM compression" (or loaded-from-romstage-and-later), because that's what it's really mostly about, and then post-RAM compression may still be interesting for a system that doesn't have a ramstage.
my only point is to make COMPRESS_RAMSTAGE depends on RAMSTAGE Kconfig and similarly other stage config also should depend on required stage. Its very weird that i'm trying to build platform without ramstage but still i have COMPRESS_RAMSTAGE config set to enable. I don't think it does any work in that case ?
I understood the argument Aaron has given for pre_ram compress where VERSTAGE can't be mandatory enable, i will fix that but ROMSTAGE should be mandatory right in case of pre_ram compress ?