Joel Kitching has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/32664
Change subject: vboot: remove use of VbInitParams ......................................................................
vboot: remove use of VbInitParams
The VbInitParams struct will be deprecated. Remove its use in preparation.
BUG=b:124141368, b:124192753 TEST=make clean && make test-abuild BRANCH=none
Change-Id: Ibe02cb6ba639de0d7cbdf79fc4dbf49044c92278 Signed-off-by: Joel Kitching kitching@google.com Cq-Depend: chromium:TODO --- M src/security/vboot/vboot_common.c M src/security/vboot/vboot_common.h M src/security/vboot/vboot_handoff.c 3 files changed, 3 insertions(+), 3 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/64/32664/1
diff --git a/src/security/vboot/vboot_common.c b/src/security/vboot/vboot_common.c index b434f8d..b2582f1 100644 --- a/src/security/vboot/vboot_common.c +++ b/src/security/vboot/vboot_common.c @@ -85,7 +85,7 @@ if (vboot_get_handoff_info((void **)&vbho, NULL)) return 0;
- return !!(vbho->init_params.out_flags & flag); + return !!(vbho->out_flags & flag); }
int vboot_handoff_skip_display_init(void) diff --git a/src/security/vboot/vboot_common.h b/src/security/vboot/vboot_common.h index 8c92437..119e871 100644 --- a/src/security/vboot/vboot_common.h +++ b/src/security/vboot/vboot_common.h @@ -39,7 +39,7 @@ * vboot shared data as well as the flags from VbInit. */ struct vboot_handoff { - VbInitParams init_params; + uint32_t out_flags; uint32_t selected_firmware; char shared_data[VB_SHARED_DATA_MIN_SIZE]; } __packed; diff --git a/src/security/vboot/vboot_handoff.c b/src/security/vboot/vboot_handoff.c index ff938e1..491e1f2 100644 --- a/src/security/vboot/vboot_handoff.c +++ b/src/security/vboot/vboot_handoff.c @@ -40,7 +40,7 @@ { VbSharedDataHeader *vb_sd = (VbSharedDataHeader *)vboot_handoff->shared_data; - uint32_t *oflags = &vboot_handoff->init_params.out_flags; + uint32_t *oflags = &vboot_handoff->out_flags;
vb_sd->flags |= VBSD_BOOT_FIRMWARE_VBOOT2;
Hello Aaron Durbin, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/32664
to look at the new patch set (#2).
Change subject: vboot: remove use of VbInitParams ......................................................................
vboot: remove use of VbInitParams
The VbInitParams struct will be deprecated. Remove its use in preparation.
BUG=b:124141368, b:124192753 TEST=make clean && make test-abuild BRANCH=none
Change-Id: Ibe02cb6ba639de0d7cbdf79fc4dbf49044c92278 Signed-off-by: Joel Kitching kitching@google.com Cq-Depend: chromium:1583943 --- M src/security/vboot/vboot_common.c M src/security/vboot/vboot_common.h M src/security/vboot/vboot_handoff.c 3 files changed, 3 insertions(+), 3 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/64/32664/2
Hello Aaron Durbin, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/32664
to look at the new patch set (#3).
Change subject: vboot: remove use of VbInitParams ......................................................................
vboot: remove use of VbInitParams
The VbInitParams struct will be deprecated. Remove its use in preparation.
BUG=b:124141368, chromium:960226 TEST=make clean && make test-abuild BRANCH=none
Change-Id: Ibe02cb6ba639de0d7cbdf79fc4dbf49044c92278 Signed-off-by: Joel Kitching kitching@google.com Cq-Depend: chromium:1583943 --- M src/security/vboot/vboot_common.c M src/security/vboot/vboot_common.h M src/security/vboot/vboot_handoff.c 3 files changed, 3 insertions(+), 3 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/64/32664/3
Hello Aaron Durbin, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/32664
to look at the new patch set (#4).
Change subject: vboot: remove use of VbInitParams ......................................................................
vboot: remove use of VbInitParams
The VbInitParams struct will be deprecated. Remove its use in preparation.
Additionally, remove use of the flag VB_INIT_OUT_ENABLE_USB_STORAGE, which is no longer used downstream since vboot_reference CL:347257.
BUG=b:124141368, chromium:960226 TEST=make clean && make test-abuild BRANCH=none
Change-Id: Ibe02cb6ba639de0d7cbdf79fc4dbf49044c92278 Signed-off-by: Joel Kitching kitching@google.com Cq-Depend: chromium:1583943 --- M src/security/vboot/vboot_common.c M src/security/vboot/vboot_common.h M src/security/vboot/vboot_handoff.c 3 files changed, 3 insertions(+), 5 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/64/32664/4
Hello Aaron Durbin, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/32664
to look at the new patch set (#5).
Change subject: vboot: remove use of VbInitParams ......................................................................
vboot: remove use of VbInitParams
The VbInitParams struct will be deprecated. Remove its use in preparation.
Additionally, remove use of the flag VB_INIT_OUT_ENABLE_USB_STORAGE, which is no longer used downstream since vboot_reference CL:347257.
BUG=b:124141368, chromium:960226 TEST=make clean && make test-abuild BRANCH=none
Change-Id: Ibe02cb6ba639de0d7cbdf79fc4dbf49044c92278 Signed-off-by: Joel Kitching kitching@google.com Cq-Depend: chromium:1583943 --- M src/security/vboot/vboot_common.c M src/security/vboot/vboot_common.h M src/security/vboot/vboot_handoff.c 3 files changed, 3 insertions(+), 5 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/64/32664/5
Julius Werner has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/32664 )
Change subject: vboot: remove use of VbInitParams ......................................................................
Patch Set 5:
(1 comment)
https://review.coreboot.org/#/c/32664/5/src/security/vboot/vboot_common.h File src/security/vboot/vboot_common.h:
https://review.coreboot.org/#/c/32664/5/src/security/vboot/vboot_common.h@42 PS5, Line 42: uint32_t out_flags; I'd suggest adding a u32 reserved above here, so that the layout of the struct stays the same. Eventually we'll wanna remove this entirely, but until then it would be nice to keep the interface stable (where it's not too much of a hassle, at least).
Hello Aaron Durbin, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/32664
to look at the new patch set (#7).
Change subject: vboot: remove use of VbInitParams ......................................................................
vboot: remove use of VbInitParams
The VbInitParams struct will be deprecated. Remove its use in preparation.
Additionally, remove use of the flag VB_INIT_OUT_ENABLE_USB_STORAGE, which is no longer used downstream since vboot_reference CL:347257.
BUG=b:124141368, chromium:960226 TEST=make clean && make test-abuild BRANCH=none
Change-Id: Ibe02cb6ba639de0d7cbdf79fc4dbf49044c92278 Signed-off-by: Joel Kitching kitching@google.com Cq-Depend: chromium:1583943 --- M src/security/vboot/vboot_common.c M src/security/vboot/vboot_common.h M src/security/vboot/vboot_handoff.c 3 files changed, 4 insertions(+), 5 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/64/32664/7
Joel Kitching has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/32664 )
Change subject: vboot: remove use of VbInitParams ......................................................................
Patch Set 7:
(1 comment)
https://review.coreboot.org/#/c/32664/5/src/security/vboot/vboot_common.h File src/security/vboot/vboot_common.h:
https://review.coreboot.org/#/c/32664/5/src/security/vboot/vboot_common.h@42 PS5, Line 42: uint32_t out_flags;
I'd suggest adding a u32 reserved above here, so that the layout of the struct stays the same. […]
Done
Furquan Shaikh has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/32664 )
Change subject: vboot: remove use of VbInitParams ......................................................................
Patch Set 8:
(1 comment)
https://review.coreboot.org/#/c/32664/8/src/security/vboot/vboot_common.h File src/security/vboot/vboot_common.h:
https://review.coreboot.org/#/c/32664/8/src/security/vboot/vboot_common.h@42 PS8, Line 42: reserved0 Can you please add a comment indicating why this reserved field is added?
Julius Werner has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/32664 )
Change subject: vboot: remove use of VbInitParams ......................................................................
Patch Set 8: Code-Review+1
Hello Aaron Durbin, Julius Werner, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/32664
to look at the new patch set (#9).
Change subject: vboot: remove use of VbInitParams ......................................................................
vboot: remove use of VbInitParams
The VbInitParams struct will be deprecated. Remove its use in preparation.
Additionally, remove use of the flag VB_INIT_OUT_ENABLE_USB_STORAGE, which is no longer used downstream since vboot_reference CL:347257.
BUG=b:124141368, chromium:960226 TEST=make clean && make test-abuild BRANCH=none
Change-Id: Ibe02cb6ba639de0d7cbdf79fc4dbf49044c92278 Signed-off-by: Joel Kitching kitching@google.com Cq-Depend: chromium:1583943 --- M src/security/vboot/vboot_common.c M src/security/vboot/vboot_common.h M src/security/vboot/vboot_handoff.c 3 files changed, 4 insertions(+), 5 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/64/32664/9
Joel Kitching has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/32664 )
Change subject: vboot: remove use of VbInitParams ......................................................................
Patch Set 9:
(1 comment)
https://review.coreboot.org/#/c/32664/8/src/security/vboot/vboot_common.h File src/security/vboot/vboot_common.h:
https://review.coreboot.org/#/c/32664/8/src/security/vboot/vboot_common.h@42 PS8, Line 42: reserved0
Can you please add a comment indicating why this reserved field is added?
Done
Furquan Shaikh has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/32664 )
Change subject: vboot: remove use of VbInitParams ......................................................................
Patch Set 9: Code-Review+2
Patrick Georgi has submitted this change and it was merged. ( https://review.coreboot.org/c/coreboot/+/32664 )
Change subject: vboot: remove use of VbInitParams ......................................................................
vboot: remove use of VbInitParams
The VbInitParams struct will be deprecated. Remove its use in preparation.
Additionally, remove use of the flag VB_INIT_OUT_ENABLE_USB_STORAGE, which is no longer used downstream since vboot_reference CL:347257.
BUG=b:124141368, chromium:960226 TEST=make clean && make test-abuild BRANCH=none
Change-Id: Ibe02cb6ba639de0d7cbdf79fc4dbf49044c92278 Signed-off-by: Joel Kitching kitching@google.com Cq-Depend: chromium:1583943 Reviewed-on: https://review.coreboot.org/c/coreboot/+/32664 Reviewed-by: Furquan Shaikh furquan@google.com Tested-by: build bot (Jenkins) no-reply@coreboot.org --- M src/security/vboot/vboot_common.c M src/security/vboot/vboot_common.h M src/security/vboot/vboot_handoff.c 3 files changed, 4 insertions(+), 5 deletions(-)
Approvals: build bot (Jenkins): Verified Furquan Shaikh: Looks good to me, approved
diff --git a/src/security/vboot/vboot_common.c b/src/security/vboot/vboot_common.c index 493cb88..14f154c 100644 --- a/src/security/vboot/vboot_common.c +++ b/src/security/vboot/vboot_common.c @@ -85,7 +85,7 @@ if (vboot_get_handoff_info((void **)&vbho, NULL)) return 0;
- return !!(vbho->init_params.out_flags & flag); + return !!(vbho->out_flags & flag); }
int vboot_handoff_check_developer_flag(void) diff --git a/src/security/vboot/vboot_common.h b/src/security/vboot/vboot_common.h index 768b29d..9a02303 100644 --- a/src/security/vboot/vboot_common.h +++ b/src/security/vboot/vboot_common.h @@ -39,7 +39,8 @@ * vboot shared data as well as the flags from VbInit. */ struct vboot_handoff { - VbInitParams init_params; + uint32_t reserved0; /* originally from VbInitParams */ + uint32_t out_flags; uint32_t selected_firmware; char shared_data[VB_SHARED_DATA_MIN_SIZE]; } __packed; diff --git a/src/security/vboot/vboot_handoff.c b/src/security/vboot/vboot_handoff.c index 178877d..208663e 100644 --- a/src/security/vboot/vboot_handoff.c +++ b/src/security/vboot/vboot_handoff.c @@ -40,7 +40,7 @@ { VbSharedDataHeader *vb_sd = (VbSharedDataHeader *)vboot_handoff->shared_data; - uint32_t *oflags = &vboot_handoff->init_params.out_flags; + uint32_t *oflags = &vboot_handoff->out_flags;
vb_sd->flags |= VBSD_BOOT_FIRMWARE_VBOOT2;
@@ -61,12 +61,10 @@ vb_sd->flags |= VBSD_BOOT_REC_SWITCH_ON; *oflags |= VB_INIT_OUT_ENABLE_RECOVERY; *oflags |= VB_INIT_OUT_CLEAR_RAM; - *oflags |= VB_INIT_OUT_ENABLE_USB_STORAGE; } if (vb2_sd->flags & VB2_SD_FLAG_DEV_MODE_ENABLED) { *oflags |= VB_INIT_OUT_ENABLE_DEVELOPER; *oflags |= VB_INIT_OUT_CLEAR_RAM; - *oflags |= VB_INIT_OUT_ENABLE_USB_STORAGE; vb_sd->flags |= VBSD_BOOT_DEV_SWITCH_ON; vb_sd->flags |= VBSD_LF_DEV_SWITCH_ON; }