From ea544574d06e8a149c447b35c5e8fba96e61152a Mon Sep 17 00:00:00 2001 From: Yu-Ping Wu Date: Thu, 14 Nov 2019 11:38:44 +0800 Subject: security/vboot: Remove buffer_size from struct vboot_working_data Since buffer_size is no longer used, remove it from struct vboot_working_data. BRANCH=none BUG=chromium:1021452 TEST=emerge-kukui coreboot Change-Id: Ie770e89b4a45e0ec703d5bbb8fb6a298ce915056 Signed-off-by: Yu-Ping Wu Reviewed-on: https://review.coreboot.org/c/coreboot/+/36844 Tested-by: build bot (Jenkins) Reviewed-by: Julius Werner --- src/lib/coreboot_table.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src/lib') diff --git a/src/lib/coreboot_table.c b/src/lib/coreboot_table.c index d3576e6a32..241d8e1550 100644 --- a/src/lib/coreboot_table.c +++ b/src/lib/coreboot_table.c @@ -227,7 +227,14 @@ static void lb_vboot_workbuf(struct lb_header *header) vbwb->tag = LB_TAG_VBOOT_WORKBUF; vbwb->size = sizeof(*vbwb); vbwb->range_start = (uintptr_t)wd + wd->buffer_offset; - vbwb->range_size = wd->buffer_size; + /* + * TODO(chromium:1021452): Since cbmem size of vboot workbuf is now + * always a known value, we hardcode the value of range_size here. + * Ultimately we'll want to move this to add_cbmem_pointers() below, + * but we'll have to get rid of the vboot_working_data struct first. + */ + vbwb->range_size = VB2_KERNEL_WORKBUF_RECOMMENDED_SIZE - + wd->buffer_offset; } __weak uint32_t board_id(void) { return UNDEFINED_STRAPPING_ID; } -- cgit v1.2.3