-
-
Notifications
You must be signed in to change notification settings - Fork 187
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add ability to change CMOS values for X230 #670
Conversation
Add ability to change CMOS values by genning SMBIOS tables and using the values from stock bios, this allows for editing of SMBIOS values to change things such as VRAM allocation, FN and CTRL key swap etc
How would we measure changes ? |
I'm of the view it's not needed. There is no harmful options in NVRAM and even if there was (again, I don't see the scope of it), we can patch it easily out of coreboot anyway. Alternatively, we force load a custom SMBIOS table on every boot, which the user may customize at compile time only, this would only allow on the fly changes, so an attacker could not do anything with persistence. Attacker could edit using nvramtool on a usb via recovery shell. The most dangerous thing you could do is enable hyepr threading which isn't implemented on X230, which can be set with 'nosmt' in kernel anyway (which we should probably add as a boot argument for heads by default). |
Hyper threading is supported on i7, but deactivated by QubesOS grub config as if now. Not against having the defaults being loaded at compile time. I think this is another state we might not want collectively merged inside of a shared board config and produced resulting CI built images, though. |
what exactly do the SMBIOS tables have to do with CMOS? IIRC, they are completely unrelated |
@tlaurion I would personally say, this should be implemented on a board-by-board basis and we leave the NVRAM values at default coreboot values at compile times. @tlaurion agreed, maybe a build flag would be useful for this? @MrChromebox Forgive me, I may be using wrong terminology here, but from my understanding, CMOS chip holds the user defined NVRAM values, which is backed by the CMOS battery, so when you yank it out then in and boot you'll fallback onto the default SMBIOS tables and their default values respectively. Please correct me if I am wrong in my explanation. Perhaps I should edit original post replacing CMOS with NVRAM? |
@flawedworld the CMOS is a tiny amount of NVRAM historically part of the southbridge which coreboot uses to store configuration values. It has no direct connection to the SMBIOS tables. It's also generally not used interchangeably with NVRAM since that has a different connotation. Looking at the cmos.layout for the x230, I don't see how any CMOS values for that board would result in any changes to the SMBIOS tables. And your selecting of CONFIG_SMBIOS_PROVIDED_BY_MOBO -- what is the goal there? Edit: this also seems to already be selected by So ultimately, the question is why have you selected |
@MrChromebox Indeed you would be correct, it seems that only |
since the CMOS data is stored outside of the AP SPI flash, there's no issue with measured boot. LGTM |
@tlaurion any followup comments to this? |
#602 |
I think the best way if we are worried about the persistence aspect is that we load a table in with user defined values at compile time, I will test these options out as soon as I can. I dare say the heads master branch is ready to handle that judging from #300 . Seems overkill but I mean its no harm done. |
Tested and working on X230 |
Add ability to change CMOS values by genning SMBIOS tables and using the values from stock bios, this allows for editing of SMBIOS values to change things such as VRAM allocation, FN and CTRL key swap etc