r/coreboot • u/kenkitt • 10h ago
Dual-Slot Coreboot (`4.20` RO + `26.09` RW_A) with EDK2 `uefipayload_2608`, Secure Boot, and Auto-Fallback Beeps on HP ProBook 640 G1 (i7-4810MQ)
Earlier I posted I managed to get coreboot 4.2 onto hp probook 640g1
Now I managed to move the changes onto coreboot 26.09 , the changes on both 4.2 and 26.09
Dual-Slot Coreboot (4.20 RO + 26.09 RW_A) with EDK2 uefipayload_2608, Secure Boot, and Auto-Fallback Beeps on HP ProBook 640 G1 (i7-4810MQ)
I finally got a dual-slot vboot (RO + RW_A) Coreboot setup running on my HP ProBook 640 G1, keeping a known-good Coreboot 4.20 (uefipayload_202304) safety net in WP_RO while running Coreboot 26.09 (main) + EDK2 uefipayload_2608 out of RW_SECTION_A — pure UEFI (no SeaBIOS), with Secure Boot enabled, Win+A manual recovery, CMOS watchdog auto-fallback, and a 2-beep PC speaker alert when booting the RO fallback.
Hardware Specs
- Laptop: HP ProBook 640 G1
- CPU: Intel Core i7-4810MQ @ 2.80 GHz (Haswell C0, CPUID
0x306c3, microcode0x28) - Chipset: Intel QM87 PCH (
8086:8c4f) - Memory: 8 GiB DDR3-1600
- TPM: Infineon SLB9635 TT 1.2
- EC / Super I/O: SMSC KBC1126 + MEC1322 + LPC47N217
- SPI Flash: 16 MiB (
0x1000000bytes) - Payload: Pure UEFI via EDK2 (
uefipayload_2608inRW_A,uefipayload_202304inWP_RO; no SeaBIOS)
Flash Layout (vboot-rwa.fmd / FMAP Regions)
The 16 MiB flash is partitioned so that the Intel descriptor/ME (SI_ALL), the updatable RW_SECTION_A (26.09), the shared MRC/UEFI variable stores, and the read-only fallback WP_RO (4.20) never step on each other. Because RO and RW_A have separate MRC cache regions (RECOVERY_MRC_CACHE vs RW_MRC_CACHE) and SMMSTORE is marked PRESERVE, switching between 26.09 and 4.20 keeps UEFI variables/Secure Boot state intact and avoids MRC cache thrashing.
| Region | Offset Range | Size | Purpose |
|---|---|---|---|
| SI_ALL | 0x000000 - 0x9fffff | 10 MiB | Intel Flash Descriptor, GbE, and Management Engine |
- SI_DESC | 0x000000 - 0x000fff | 4 KiB | Flash Descriptor |
- SI_GBE | 0x001000 - 0x002fff | 8 KiB | Intel Gigabit Ethernet NVM |
- SI_ME | 0x003000 - 0x9fffff | 10,473,472 B | Intel ME region |
| SI_BIOS | 0xa00000 - 0xffffff | 6 MiB (6,291,456 B) | BIOS / Coreboot region |
| RW_SECTION_A | 0xa00000 - 0xcbffff | 2,883,584 B | Active RW slot (coreboot-26.09 + uefipayload_2608) |
- VBLOCK_A | 0xa00000 - 0xa0ffff | 64 KiB | vboot verification block for RW_A |
- FW_MAIN_A (CBFS) | 0xa10000 - 0xcbffbf | 2,817,984 B | coreboot-26.09 stages + EDK2 uefipayload_2608 |
- RW_FWID_A | 0xcbffc0 - 0xcbffff | 64 B | RW firmware ID string |
| UNIFIED_MRC_CACHE | 0xcc0000 - 0xcdffff | 128 KiB | Split MRC cache so RO and RW_A stay isolated |
- RECOVERY_MRC_CACHE | 0xcc0000 - 0xccffff | 64 KiB | MRC cache used by WP_RO (4.20) |
- RW_MRC_CACHE | 0xcd0000 - 0xcdffff | 64 KiB | MRC cache used by RW_SECTION_A (26.09) |
RW_NVRAM (PRESERVE) | 0xce0000 - 0xce1fff | 8 KiB | Preserved RW NVRAM |
RW_VPD (PRESERVE) | 0xce2000 - 0xce2fff | 4 KiB | Preserved RW Vital Product Data |
SMMSTORE (PRESERVE) | 0xcf0000 - 0xd2ffff | 256 KiB | UEFI NVRAM variables & Secure Boot keys |
| WP_RO | 0xd30000 - 0xffffff | 2,949,120 B | Read-only recovery slot (coreboot-4.20 + uefipayload_202304) |
- FMAP | 0xd30000 - 0xd307ff | 2 KiB | Flash Map table |
- RO_FRID | 0xd30800 - 0xd3083f | 64 B | RO firmware ID string |
- RO_PADDING | 0xd30840 - 0xd30fff | 1,984 B | Alignment padding |
- RO_VPD (PRESERVE) | 0xd31000 - 0xd31fff | 4 KiB | Preserved RO Vital Product Data |
- GBB | 0xd32000 - 0xd4ffff | 120 KiB | Google Binary Block (vboot keys, flags, BMPs) |
- COREBOOT (CBFS) | 0xd50000 - 0xffffff | 2,818,048 B | coreboot-4.20 stages + EDK2 uefipayload_202304 |
Features & Architecture
Dual-Slot
vboot(WP_RO+RW_SECTION_A)WP_RO(4.20branchhp-640g1-edk2): Runsbootblock+verstage, verifiesVBLOCK_A/FW_MAIN_A, and either jumps intoRW_SECTION_A(FW_MAIN_A @ 0xa10000) or falls back toCOREBOOT @ 0xd50000.RW_SECTION_A(26.09branchmain-640g1-edk2): Runscoreboot-26.09+ EDK2uefipayload_2608, allowing fast updates toRW_SECTION_Awithout risking a brick.
CMOS
0x3AAuto-Fallback Watchdog- Before jumping to
RW_SECTION_A,ROwrites0xA5to CMOS offset0x3A. - Once
RW_SECTION_AreachesBS_PAYLOAD_LOAD, it clears CMOS0x3A. - If a bad
RW_Abuild hangs or crashes before reaching the payload, the next boot sees0x3A == 0xA5and automatically falls back toWP_RO(4.20). - Uses
CONFIG_VBOOT_MOCK_SECDATA=ysovbootdoesn't lock out across test builds.
- Before jumping to
2-Beep PC Speaker Fallback Alert
- Whenever the system enters
WP_ROrecovery/fallback mode (4.20), it plays two 880 Hz beeps (beep(880, 120)x2 viapc80/i8254.h) so you immediately know it booted theROfallback even without display/serial output.
- Whenever the system enters
Win+AManual Recovery Override- Added an i8042 keyboard scan in
src/mainboard/hp/probook_640_g1/vboot.c: holdingWin+Aduring early boot forcesvbootrecovery mode and drops straight intoWP_RO(4.20).
- Added an i8042 keyboard scan in
Secure Boot Enabled
- EDK2
uefipayload_2608boots with Secure Boot active (sbctl status:Secure Boot: ✓ Enabled,Vendor Keys: microsoft builtin-db).
- EDK2
Key Fixes Needed for Coreboot 26.09 (main)
- Memory SPD addresses: Added
spd_addresses = "{0x50, 0, 0x52, 0}"indevicetree.cbso Haswell MRC detects both SO-DIMM slots onmain. - LynxPoint PCIe teardown guard: Guarded registers
0x338/0x328/0x408inpcie.cduring teardown. - CBFS size fit: Enabled
CONFIG_COMPRESS_RAMSTAGE_LZ4=ysocoreboot-26.09+uefipayload_2608fits cleanly insideFW_MAIN_A(2,817,984bytes). RO->RW_ACompatibility Shims: Handled theRO(4.20) toRW_A(26.09)vbootABI mismatch (vboot_get_context: RO/RW vboot ABI mismatch, reinitializing RW context) and CAR_fmap_cache/_cbfs_mcachehandoff so26.09romstage/postcar/ramstageboot cleanly from4.20'sverstage.- Helper Tooling: Added
bootlog_probook640g1.sh --spifor reading/summarizing CBMEM/SPI boot logs directly.
Boot Logs
Current coreboot-26.09 (RW_SECTION_A / FW_MAIN_A) Boot Summary
=== Boot Summary ===
[DEBUG] TPM: command 0x14 returned 0x0
[DEBUG] FMAP: area FW_MAIN_A found @ a10000 (2817984 bytes)
[DEBUG] FMAP: area COREBOOT found @ d50000 (2818048 bytes)
[NOTE ] coreboot-26.09-846-g07684235aaaf-dirty Sun Nov 29 21:53:35 UTC 2026 x86_32 romstage starting (log level: 7)...
[WARN ] vboot_get_context: RO/RW vboot ABI mismatch, reinitializing RW context
[DEBUG] FMAP: area RW_MRC_CACHE found @ cd0000 (65536 bytes)
[INFO ] MRC: version mismatch: 2 vs 1
[DEBUG] FMAP: area COREBOOT found @ d50000 (2818048 bytes)
[DEBUG] FMAP: area FW_MAIN_A found @ a10000 (2817984 bytes)
[DEBUG] FMAP: area RW_MRC_CACHE found @ cd0000 (65536 bytes)
[DEBUG] MRC: Checking cached data update for 'RW_MRC_CACHE'.
[DEBUG] MRC: cache data 'RW_MRC_CACHE' needs update.
[DEBUG] MRC: updated 'RW_MRC_CACHE'.
[NOTE ] coreboot-26.09-846-g07684235aaaf-dirty Sun Nov 29 21:53:35 UTC 2026 x86_32 postcar starting (log level: 7)...
[DEBUG] FMAP: area FW_MAIN_A found @ a10000 (2817984 bytes)
[NOTE ] coreboot-26.09-846-g07684235aaaf-dirty Sun Nov 29 21:53:35 UTC 2026 x86_32 ramstage starting (log level: 7)...
[ERROR] PNP: 004e.3 74 not allocated
[DEBUG] FMAP: area FW_MAIN_A found @ a10000 (2817984 bytes)
[ERROR] ME MBP: unknown item 0x20104 @ dw offset 0x6
[WARN ] CBFS: 'fallback/slic' not found.
====================coreboot-4.20 (WP_RO / COREBOOT) Fallback Boot Summary (via Win+A / Recovery + 2 Beeps)
=== Boot Summary ===
[INFO ] VB2:vb2_check_recovery() Recovery reason from previous boot: 0x0 / 0x0
[INFO ] VB2:vb2_check_recovery() Recovery was requested manually
[INFO ] VB2:vb2_check_recovery() We have a recovery request: 0x2 / 0x0
[INFO ] Recovery requested (1009000e)
[DEBUG] TPM: command 0x14 returned 0x0
[DEBUG] TPM: command 0x14 returned 0x0
[DEBUG] FMAP: area COREBOOT found @ d50000 (2818048 bytes)
[NOTE ] coreboot-4.20-73-g63bbf0fe23 Sun Nov 29 21:59:03 UTC 2026 x86_32 romstage starting (log level: 7)...
[DEBUG] FMAP: area RECOVERY_MRC_CACHE found @ cc0000 (65536 bytes)
[DEBUG] FMAP: area COREBOOT found @ d50000 (2818048 bytes)
[DEBUG] FMAP: area RECOVERY_MRC_CACHE found @ cc0000 (65536 bytes)
[DEBUG] MRC: Checking cached data update for 'RECOVERY_MRC_CACHE'.
[DEBUG] MRC: 'RECOVERY_MRC_CACHE' does not need update.
[NOTE ] coreboot-4.20-73-g63bbf0fe23 Sun Nov 29 21:59:03 UTC 2026 x86_32 ramstage starting (log level: 7)...
[WARN ] PCI: Leftover static devices:
[WARN ] PCI: 00:1f.5
[WARN ] PCI: Check your devicetree.cb.
[ERROR] PNP: 004e.3 74 not allocated
[DEBUG] FMAP: area COREBOOT found @ d50000 (2818048 bytes)
[WARN ] ELOG: Unable to find RW_ELOG in FMAP
[ERROR] ME MBP: unknown item 0x20104 @ dw offset 0x6
[WARN ] CBFS: 'fallback/slic' not found.
[WARN ] SMBIOS type 15 log address invalid.
====================
