Hi Pratik,
On 10.03.23 02:19, Prajapati, Pratikkumar V wrote:
For my patch https://review.coreboot.org/c/coreboot/+/71120, the Jenkins build fails with following error:
"Check Kconfig files for errors (lint-stable-008-kconfig): #!!!!! Error: 'CONFIG_SOC_INTEL_COMMON_BLOCK_PRMRR_SIZE_2MB' selected at src/soc/intel/meteorlake/Kconfig:101. Symbols created in a choice cannot be selected"
What is the rationale behind enforcing this? As of now, PRMRR Kconfig settings are in common code and i wanted to set the right size from SOC specific code. e.g. the patch i mentioned earlier.
Quite simple: It doesn't work. Even if the linter didn't complain, a `select` on a choice config wouldn't do anything.
That's actually a good thing, IMO, because it helps us to keep Kconfig prompts sane. A choice always has a prompt, e.g. is visible to the integrator in menuconfig. If you could enforce a single option of a choice, it would show a prompt without meaning.
One option i think is to simplify PRMRR Kconfig options (get rid of choice menu) and define PRMRR_SIZE config option in SOC specific code.
That's the big question. Either it's wrong to have a choice and thereby a prompt or it's wrong to enforce a specific selection. I can't tell what it is in your case. Does it really have to be 2MiB? Why would a bigger PRMRR not work for Keylocker?
The `select INTEL_KEYLOCKER` also looks odd as that config option also has a prompt. Why would the SoC code make that choice if it was already decided that it should have a prompt? Or was that prompt added by accident?
But then all SOC specific code would have to define this Kconfig option.
Not really, we can always set sane defaults at the common/ level.
Nico