Patrick Rudolph has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/35400 )
Change subject: mb/emulation/qemu: Add VBOOT support ......................................................................
mb/emulation/qemu: Add VBOOT support
Add VBOOT support for testing purposes. Add a 16 MiB FMAP containing RO + RW_A.
Tested on qemu.
Change-Id: I4039d77de44ade68c7bc1f8b4b0aa21387c50f8a Signed-off-by: Patrick Rudolph patrick.rudolph@9elements.com --- M src/mainboard/emulation/qemu-i440fx/Kconfig M src/mainboard/emulation/qemu-i440fx/cmos.layout A src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd M src/mainboard/emulation/qemu-q35/Kconfig M src/mainboard/emulation/qemu-q35/cmos.layout A src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd 6 files changed, 81 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/00/35400/1
diff --git a/src/mainboard/emulation/qemu-i440fx/Kconfig b/src/mainboard/emulation/qemu-i440fx/Kconfig index 3c5e325..4074fef 100644 --- a/src/mainboard/emulation/qemu-i440fx/Kconfig +++ b/src/mainboard/emulation/qemu-i440fx/Kconfig @@ -12,6 +12,22 @@ select BOARD_ROMSIZE_KB_256 select MAINBOARD_HAS_NATIVE_VGA_INIT select MAINBOARD_FORCE_NATIVE_VGA_INIT + select VBOOT_STARTS_IN_BOOTBLOCK + select VBOOT_SEPARATE_VERSTAGE + select VBOOT_NO_BOARD_SUPPORT + select VBOOT_VBNV_CMOS + + +config VBOOT_SLOTS_RW_A + default y + +config FMDFILE + string + default "src/mainboard/$(CONFIG_MAINBOARD_DIR)/vboot-roa-16M.fmd" if VBOOT_SLOTS_RW_A + +config VBOOT_VBNV_OFFSET + hex + default 0x2c
config MAINBOARD_DIR string diff --git a/src/mainboard/emulation/qemu-i440fx/cmos.layout b/src/mainboard/emulation/qemu-i440fx/cmos.layout index b238a37..247a6a0 100644 --- a/src/mainboard/emulation/qemu-i440fx/cmos.layout +++ b/src/mainboard/emulation/qemu-i440fx/cmos.layout @@ -7,6 +7,10 @@ 400 1 e 1 power_on_after_fail 412 4 e 6 debug_level 456 1 e 1 ECC_memory + +# VBOOT +464 128 r 0 vbnv + 1008 16 h 0 check_sum
enumerations @@ -25,4 +29,4 @@
checksums
-checksum 392 1007 1008 +checksum 392 463 1008 diff --git a/src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd b/src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd new file mode 100644 index 0000000..aa081b2 --- /dev/null +++ b/src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd @@ -0,0 +1,20 @@ +FLASH@0xff000000 0x1000000 { + SI_BIOS 0x1000000 { + RW_SECTION_A 0x7c0000 { + VBLOCK_A 0x10000 + FW_MAIN_A(CBFS) 0x74ffc0 + RW_FWID_A 0x40 + } + RW_VPD(PRESERVE) 0x1000 + SMMSTORE(PRESERVE) 0x40000 + + WP_RO 0x7ff000 { + FMAP 0x800 + RO_FRID 0x40 + RO_PADDING 0x7c0 + RO_VPD(PRESERVE) 0x1000 + GBB 0x1e000 + COREBOOT(CBFS)@0x20000 0x7df000 + } + } +} diff --git a/src/mainboard/emulation/qemu-q35/Kconfig b/src/mainboard/emulation/qemu-q35/Kconfig index bfa38ed..811630c 100644 --- a/src/mainboard/emulation/qemu-q35/Kconfig +++ b/src/mainboard/emulation/qemu-q35/Kconfig @@ -11,6 +11,21 @@ select BOARD_ROMSIZE_KB_2048 select MAINBOARD_HAS_NATIVE_VGA_INIT select MAINBOARD_FORCE_NATIVE_VGA_INIT + select VBOOT_STARTS_IN_BOOTBLOCK + select VBOOT_SEPARATE_VERSTAGE + select VBOOT_NO_BOARD_SUPPORT + select VBOOT_VBNV_CMOS + +config FMDFILE + string + default "src/mainboard/$(CONFIG_MAINBOARD_DIR)/vboot-roa-16M.fmd" if VBOOT_SLOTS_RW_A + +config VBOOT_SLOTS_RW_A + default y + +config VBOOT_VBNV_OFFSET + hex + default 0x2c
config MAINBOARD_DIR string diff --git a/src/mainboard/emulation/qemu-q35/cmos.layout b/src/mainboard/emulation/qemu-q35/cmos.layout index b238a37..247a6a0 100644 --- a/src/mainboard/emulation/qemu-q35/cmos.layout +++ b/src/mainboard/emulation/qemu-q35/cmos.layout @@ -7,6 +7,10 @@ 400 1 e 1 power_on_after_fail 412 4 e 6 debug_level 456 1 e 1 ECC_memory + +# VBOOT +464 128 r 0 vbnv + 1008 16 h 0 check_sum
enumerations @@ -25,4 +29,4 @@
checksums
-checksum 392 1007 1008 +checksum 392 463 1008 diff --git a/src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd b/src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd new file mode 100644 index 0000000..aa081b2 --- /dev/null +++ b/src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd @@ -0,0 +1,20 @@ +FLASH@0xff000000 0x1000000 { + SI_BIOS 0x1000000 { + RW_SECTION_A 0x7c0000 { + VBLOCK_A 0x10000 + FW_MAIN_A(CBFS) 0x74ffc0 + RW_FWID_A 0x40 + } + RW_VPD(PRESERVE) 0x1000 + SMMSTORE(PRESERVE) 0x40000 + + WP_RO 0x7ff000 { + FMAP 0x800 + RO_FRID 0x40 + RO_PADDING 0x7c0 + RO_VPD(PRESERVE) 0x1000 + GBB 0x1e000 + COREBOOT(CBFS)@0x20000 0x7df000 + } + } +}
Hello build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/35400
to look at the new patch set (#2).
Change subject: mb/emulation/qemu: Add VBOOT support ......................................................................
mb/emulation/qemu: Add VBOOT support
Add VBOOT support for testing purposes. Add a 16 MiB FMAP containing RO + RW_A.
Tested on qemu.
Change-Id: I4039d77de44ade68c7bc1f8b4b0aa21387c50f8a Signed-off-by: Patrick Rudolph patrick.rudolph@9elements.com --- M src/mainboard/emulation/qemu-i440fx/Kconfig M src/mainboard/emulation/qemu-i440fx/cmos.layout A src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd M src/mainboard/emulation/qemu-q35/Kconfig M src/mainboard/emulation/qemu-q35/cmos.layout A src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd 6 files changed, 81 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/00/35400/2
Hello build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/35400
to look at the new patch set (#3).
Change subject: mb/emulation/qemu: Add VBOOT support ......................................................................
mb/emulation/qemu: Add VBOOT support
Add VBOOT support for testing purposes. Add a 16 MiB FMAP containing RO + RW_A.
Tested on qemu.
Change-Id: I4039d77de44ade68c7bc1f8b4b0aa21387c50f8a Signed-off-by: Patrick Rudolph patrick.rudolph@9elements.com --- M src/mainboard/emulation/qemu-i440fx/Kconfig M src/mainboard/emulation/qemu-i440fx/cmos.layout A src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd M src/mainboard/emulation/qemu-q35/Kconfig M src/mainboard/emulation/qemu-q35/cmos.layout A src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd 6 files changed, 94 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/00/35400/3
Hello build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/35400
to look at the new patch set (#4).
Change subject: mb/emulation/qemu: Add VBOOT support ......................................................................
mb/emulation/qemu: Add VBOOT support
Add VBOOT support for testing purposes. Add a 16 MiB FMAP containing RO + RW_A.
Tested on qemu.
Change-Id: I4039d77de44ade68c7bc1f8b4b0aa21387c50f8a Signed-off-by: Patrick Rudolph patrick.rudolph@9elements.com --- M src/mainboard/emulation/qemu-i440fx/Kconfig M src/mainboard/emulation/qemu-i440fx/cmos.layout A src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd M src/mainboard/emulation/qemu-q35/Kconfig M src/mainboard/emulation/qemu-q35/cmos.layout A src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd 6 files changed, 94 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/00/35400/4
Philipp Deppenwiese has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/35400 )
Change subject: mb/emulation/qemu: Add VBOOT support ......................................................................
Patch Set 4: Code-Review+2
Arthur Heymans has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/35400 )
Change subject: mb/emulation/qemu: Add VBOOT support ......................................................................
Patch Set 4:
(2 comments)
https://review.coreboot.org/c/coreboot/+/35400/4/src/mainboard/emulation/qem... File src/mainboard/emulation/qemu-q35/Kconfig:
https://review.coreboot.org/c/coreboot/+/35400/4/src/mainboard/emulation/qem... PS4, Line 11: s select BOARD_ROMSIZE_KB_2048 if !VBOOT select BOARD_ROMSIZE_KB_16384 if VBOOT
https://review.coreboot.org/c/coreboot/+/35400/4/src/mainboard/emulation/qem... PS4, Line 19: VBOOT_VBNV_CMOS How does this work?
Arthur Heymans has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/35400 )
Change subject: mb/emulation/qemu: Add VBOOT support ......................................................................
Patch Set 4:
(1 comment)
https://review.coreboot.org/c/coreboot/+/35400/4/src/mainboard/emulation/qem... File src/mainboard/emulation/qemu-q35/Kconfig:
https://review.coreboot.org/c/coreboot/+/35400/4/src/mainboard/emulation/qem... PS4, Line 19: VBOOT_VBNV_CMOS
How does this work?
Ack
Hello Philipp Deppenwiese, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/35400
to look at the new patch set (#5).
Change subject: mb/emulation/qemu: Add VBOOT support ......................................................................
mb/emulation/qemu: Add VBOOT support
Add VBOOT support for testing purposes. Add a 16 MiB FMAP containing RO + RW_A.
Tested on qemu.
Change-Id: I4039d77de44ade68c7bc1f8b4b0aa21387c50f8a Signed-off-by: Patrick Rudolph patrick.rudolph@9elements.com --- M src/mainboard/emulation/qemu-i440fx/Kconfig M src/mainboard/emulation/qemu-i440fx/cmos.layout A src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd M src/mainboard/emulation/qemu-q35/Kconfig M src/mainboard/emulation/qemu-q35/cmos.layout A src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd 6 files changed, 96 insertions(+), 4 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/00/35400/5
Patrick Rudolph has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/35400 )
Change subject: mb/emulation/qemu: Add VBOOT support ......................................................................
Patch Set 5:
(4 comments)
https://review.coreboot.org/c/coreboot/+/35400/4/src/mainboard/emulation/qem... File src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd:
https://review.coreboot.org/c/coreboot/+/35400/4/src/mainboard/emulation/qem... PS4, Line 9: SMMSTORE(PRESERVE) 0x40000
It has a RO boot medium atm and smmstore is not hooked up so I'd remove this.
Done
https://review.coreboot.org/c/coreboot/+/35400/4/src/mainboard/emulation/qem... PS4, Line 11: 0x7ff000
remove this to have it aligned at the bootom
Done
https://review.coreboot.org/c/coreboot/+/35400/4/src/mainboard/emulation/qem... PS4, Line 17: @0x20000 0x7df000
remove this to have it aligned at the bottom.
Done
https://review.coreboot.org/c/coreboot/+/35400/4/src/mainboard/emulation/qem... File src/mainboard/emulation/qemu-q35/Kconfig:
https://review.coreboot.org/c/coreboot/+/35400/4/src/mainboard/emulation/qem... PS4, Line 11: s
select BOARD_ROMSIZE_KB_2048 if !VBOOT […]
Done
Arthur Heymans has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/35400 )
Change subject: mb/emulation/qemu: Add VBOOT support ......................................................................
Patch Set 5: Code-Review+2
Patrick Georgi has submitted this change. ( https://review.coreboot.org/c/coreboot/+/35400 )
Change subject: mb/emulation/qemu: Add VBOOT support ......................................................................
mb/emulation/qemu: Add VBOOT support
Add VBOOT support for testing purposes. Add a 16 MiB FMAP containing RO + RW_A.
Tested on qemu.
Change-Id: I4039d77de44ade68c7bc1f8b4b0aa21387c50f8a Signed-off-by: Patrick Rudolph patrick.rudolph@9elements.com Reviewed-on: https://review.coreboot.org/c/coreboot/+/35400 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Arthur Heymans arthur@aheymans.xyz --- M src/mainboard/emulation/qemu-i440fx/Kconfig M src/mainboard/emulation/qemu-i440fx/cmos.layout A src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd M src/mainboard/emulation/qemu-q35/Kconfig M src/mainboard/emulation/qemu-q35/cmos.layout A src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd 6 files changed, 96 insertions(+), 4 deletions(-)
Approvals: build bot (Jenkins): Verified Arthur Heymans: Looks good to me, approved
diff --git a/src/mainboard/emulation/qemu-i440fx/Kconfig b/src/mainboard/emulation/qemu-i440fx/Kconfig index 3c5e325..05246b6 100644 --- a/src/mainboard/emulation/qemu-i440fx/Kconfig +++ b/src/mainboard/emulation/qemu-i440fx/Kconfig @@ -9,10 +9,33 @@ select HAVE_CMOS_DEFAULT select HAVE_PIRQ_TABLE select HAVE_ACPI_TABLES - select BOARD_ROMSIZE_KB_256 + select BOARD_ROMSIZE_KB_256 if !VBOOT + select BOARD_ROMSIZE_KB_16384 if VBOOT select MAINBOARD_HAS_NATIVE_VGA_INIT select MAINBOARD_FORCE_NATIVE_VGA_INIT
+config VBOOT + select VBOOT_MUST_REQUEST_DISPLAY + select VBOOT_STARTS_IN_BOOTBLOCK + select VBOOT_SEPARATE_VERSTAGE + select VBOOT_VBNV_CMOS + select VBOOT_NO_BOARD_SUPPORT + select GBB_FLAG_DISABLE_LID_SHUTDOWN + select GBB_FLAG_DISABLE_PD_SOFTWARE_SYNC + select GBB_FLAG_DISABLE_EC_SOFTWARE_SYNC + select GBB_FLAG_DISABLE_FWMP + +config VBOOT_SLOTS_RW_A + default y + +config FMDFILE + string + default "src/mainboard/$(CONFIG_MAINBOARD_DIR)/vboot-rwa-16M.fmd" if VBOOT_SLOTS_RW_A + +config VBOOT_VBNV_OFFSET + hex + default 0x2c + config MAINBOARD_DIR string default emulation/qemu-i440fx diff --git a/src/mainboard/emulation/qemu-i440fx/cmos.layout b/src/mainboard/emulation/qemu-i440fx/cmos.layout index b238a37..247a6a0 100644 --- a/src/mainboard/emulation/qemu-i440fx/cmos.layout +++ b/src/mainboard/emulation/qemu-i440fx/cmos.layout @@ -7,6 +7,10 @@ 400 1 e 1 power_on_after_fail 412 4 e 6 debug_level 456 1 e 1 ECC_memory + +# VBOOT +464 128 r 0 vbnv + 1008 16 h 0 check_sum
enumerations @@ -25,4 +29,4 @@
checksums
-checksum 392 1007 1008 +checksum 392 463 1008 diff --git a/src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd b/src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd new file mode 100644 index 0000000..0d2c9da --- /dev/null +++ b/src/mainboard/emulation/qemu-i440fx/vboot-rwa-16M.fmd @@ -0,0 +1,19 @@ +FLASH@0xff000000 0x1000000 { + SI_BIOS 0x1000000 { + RW_SECTION_A 0x7c0000 { + VBLOCK_A 0x10000 + FW_MAIN_A(CBFS) 0x74ffc0 + RW_FWID_A 0x40 + } + RW_VPD(PRESERVE) 0x1000 + + WP_RO { + FMAP 0x800 + RO_FRID 0x40 + RO_PADDING 0x7c0 + RO_VPD(PRESERVE) 0x1000 + GBB 0x1e000 + COREBOOT(CBFS) + } + } +} diff --git a/src/mainboard/emulation/qemu-q35/Kconfig b/src/mainboard/emulation/qemu-q35/Kconfig index bfa38ed..a86e844 100644 --- a/src/mainboard/emulation/qemu-q35/Kconfig +++ b/src/mainboard/emulation/qemu-q35/Kconfig @@ -8,10 +8,33 @@ select HAVE_OPTION_TABLE # select HAVE_PIRQ_TABLE select HAVE_ACPI_TABLES - select BOARD_ROMSIZE_KB_2048 + select BOARD_ROMSIZE_KB_2048 if !VBOOT + select BOARD_ROMSIZE_KB_16384 if VBOOT select MAINBOARD_HAS_NATIVE_VGA_INIT select MAINBOARD_FORCE_NATIVE_VGA_INIT
+config VBOOT + select VBOOT_MUST_REQUEST_DISPLAY + select VBOOT_STARTS_IN_BOOTBLOCK + select VBOOT_SEPARATE_VERSTAGE + select VBOOT_VBNV_CMOS + select VBOOT_NO_BOARD_SUPPORT + select GBB_FLAG_DISABLE_LID_SHUTDOWN + select GBB_FLAG_DISABLE_PD_SOFTWARE_SYNC + select GBB_FLAG_DISABLE_EC_SOFTWARE_SYNC + select GBB_FLAG_DISABLE_FWMP + +config FMDFILE + string + default "src/mainboard/$(CONFIG_MAINBOARD_DIR)/vboot-rwa-16M.fmd" if VBOOT_SLOTS_RW_A + +config VBOOT_SLOTS_RW_A + default y + +config VBOOT_VBNV_OFFSET + hex + default 0x2c + config MAINBOARD_DIR string default emulation/qemu-q35 diff --git a/src/mainboard/emulation/qemu-q35/cmos.layout b/src/mainboard/emulation/qemu-q35/cmos.layout index b238a37..247a6a0 100644 --- a/src/mainboard/emulation/qemu-q35/cmos.layout +++ b/src/mainboard/emulation/qemu-q35/cmos.layout @@ -7,6 +7,10 @@ 400 1 e 1 power_on_after_fail 412 4 e 6 debug_level 456 1 e 1 ECC_memory + +# VBOOT +464 128 r 0 vbnv + 1008 16 h 0 check_sum
enumerations @@ -25,4 +29,4 @@
checksums
-checksum 392 1007 1008 +checksum 392 463 1008 diff --git a/src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd b/src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd new file mode 100644 index 0000000..0d2c9da --- /dev/null +++ b/src/mainboard/emulation/qemu-q35/vboot-rwa-16M.fmd @@ -0,0 +1,19 @@ +FLASH@0xff000000 0x1000000 { + SI_BIOS 0x1000000 { + RW_SECTION_A 0x7c0000 { + VBLOCK_A 0x10000 + FW_MAIN_A(CBFS) 0x74ffc0 + RW_FWID_A 0x40 + } + RW_VPD(PRESERVE) 0x1000 + + WP_RO { + FMAP 0x800 + RO_FRID 0x40 + RO_PADDING 0x7c0 + RO_VPD(PRESERVE) 0x1000 + GBB 0x1e000 + COREBOOT(CBFS) + } + } +}