I use gentoo-sources, and run "make xconfig" before invoking genkernel, which is configured not to run any of the "make something-config" options. I have CPU_SUP_AMD=y and CPU_SUP_INTEL not set, and MICROCODE_AMD=y and MICROCODE_INTEL not set. Between 5.18.2 and 5.18.3, kernel commit 9c55d99e099bd7aa6b91fce8718505c35d5dfc65 changed the depends for the two MICROCODE_vendor from just MICROCODE to CPU_SUP_vendor && MICROCODE. First, although I never noticed, genkernel adds MICROCODE_INTEL=y to .config, runs "make olddefconfig", and then compiles the kernel. This seems wrong, since I explicitly set it to N. Second, with 5.18.3, that make olddefconfig removes the MICROCODE_INTEL line from .config (instead of either leaving it as "... is not set" or "...=y" and when genkernel checks .config and doesn't find that line, it errors out. So - why would genkernel try to set MICROCODE_INTEL to y when I explicitly set it to n? With 5.18.2 and earlier, it simply includes intel microcode patch loading, making the kernel a bit larger, but for 5.18.3 and later, it just fails. Reproducible: Always Steps to Reproduce: 1) With 5.18.2, set MICROCODE_INTEL=N and run genkernel 2) With 5.18.3, set CPU_SUP_INTEL=N (MICROCODE_INTEL can't be set) and run genkernel Actual Results: 1) Kernel gets compiled, but with MICROCODE_INTEL=y 2) genkernel fails Expected Results: In both case, a compiled kernel without Intel microcode loading support. I assume, but have not tested, that the same would occur switching the AMD and INTEL settings. I can only assume nobody else has seen this because they set Y for both INTEL and AMD MICROCODE loading support. I will attach genkernl.conf and genkernel.log
Created attachment 785765 [details] genkernel.conf
Created attachment 785768 [details] genkernel.log for gentoo-sources-5.18.3
apologies for not directly assigning to genkerne@gentoo.org per the error message.
Still happens with genkernel-4.3.2-r1 and gentoo-sources-6.4.2
I believe the problem is that genkernel defaults to MICROCODE="all" (this is a genkernel.conf option, not kernel config) so it will require CPU_SUP_INTEL. CPU_SUP_INTEL is only able to be *disabled* if you enable CONFIG_EXPERT=y in the kernel. You have enabled expert mode, which allows you to disable otherwise "standard" features. So for now, you'll need to configure genkernel with MICROCODE=amd or MICROCODE=no, to account for the missing standard features. We could patch genkernel to enforce CPU_SUP_INTEL and CPU_SUP_AMD when MICROCODE=all is set, but I suspect that would still go against your goals. Any suggestions?
Apologies, I see you are setting MICROCODE="amd" in genkernel.conf. It's still enforcing CONFIG_MICROCODE_INTEL for that case for some reason. I'm not able to reproduce this failure, can you double-check your genkernel.conf still has MICROCODE="amd", and also attach your kernel config?
Created attachment 865320 [details] updated genkernel.conf
Created attachment 865321 [details] Kernel config for 6.4.2
What genkernel command are you using? Your genkernel.log says '* MICROCODE overridden on command line to "all".'
Bingo, and mea culpa. I call genkernel with a script, which included '--microcode' and not '--microcode=amd'. Changing that and it seems to be running fine. Question: if I do have the proper setting in genkernel.conf, do I even need to mention --microcode on the invokation at all? (I know i can just test it.) I don't know if there is anything you can do in the code to prevent this form of shooting myself in the foot, so feel free to close as NOTABUG. Thanks for the eventual clue.
Pretty much all of the genkernel command line options (including microcode) can be toggled in genkernel.conf, there is no need to do both (and as you found out, cmdline overrides genkernel.conf)