System Details
- Device: Magolor
- OS: Linux
- Firmware Type: UEFI Full ROM
- Firmware Version: MrChromebox-2603.1
Summary of the Issue
I’m looking to compile my own build of the CrOS EC firmware that gets rid of the power-on on lid open behavior. I’m thinking of doing so with the coreboot-sdk toolchain and then flashing it to the RW slot and make sure it works before flashing to the RO slot. Is this the right approach to doing this? Also, would the EC software sync & Use EC-RW firmware options on the MrChromebox UEFI overwrite the EC firmware or something? What do these features do exactly?
absolutely NOT.
you don’t touch the RO firmware. EVER. it’s RO for a reason.
I can’t recommend what you’re trying to do. even if you only update the RW firmware, you can brick the device as dedede boards jump to RW before starting coreboot (usually).
a better (and safer) approach would be to detect the wake reason as lid opening in coreboot and simply shut down.
EC Software Sync is the process by which coreboot updates the ECRW firmware using the file included in the build. RW jump means to use the RW firmware vs the RO. I’m not even sure it’s safe to disable the latter on newer devices as it could cause them to get stuck in a boot loop. Better have a SuzyQ handy
Regarding EC software sync, does this mean that if I were to flash my own RW firmware, upon booting coreboot would detect that the hash has changed and overwrite it with the RW firmware it was packaged with?
Also why have an option on the UEFI to jump to RW firmware if the EC does this itself before coreboot loads? (well I think your message kinda implies that this depends on the board)
yes.
the early RW jump was brand new when I added the feature
Well I was able to flash my custom EC RW firmware without bricking my device in the process. Got cros_sdk working with the corresponding firmware version repo, stripped away a small, simple hook that caused this behavior (so no changes to the overall logic itself) & compiled.
I then thoroughly checked the offsets & contents of the resulting ec.bin file with a hex editor. I also did this for a dump I made of the full EC chip after flashing to the RW section before cold rebooting the EC as well, making sure that the RO section was untouched.
For flashing I used the flashrom version that came packed with the cros_sdk chroot. So uh… yay!
1 Like