Duncan Laurie has uploaded this change for review. ( https://review.coreboot.org/20367
Change subject: lib/coreboot_tables: Zero framebuffer structure ......................................................................
lib/coreboot_tables: Zero framebuffer structure
Zero the framebuffer structure so if it is not filled in (either if it is not present or if there is an error) then it does not present garbage data to the payload.
This was noticed when booting a board without a display attached as the payload wrote to the framebuffer at a random address.
With this change the payload can properly handle the case where a display is not attached and not corrupt memory.
Change-Id: I8114d88496cd2a4f2e7f07f377fe76f3180a7f40 Signed-off-by: Duncan Laurie dlaurie@chromium.org --- M src/lib/coreboot_table.c 1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/67/20367/1
diff --git a/src/lib/coreboot_table.c b/src/lib/coreboot_table.c index aa6c7a5..52c18d0 100644 --- a/src/lib/coreboot_table.c +++ b/src/lib/coreboot_table.c @@ -138,7 +138,7 @@ static void lb_framebuffer(struct lb_header *header) { struct lb_framebuffer *framebuffer; - struct lb_framebuffer fb; + struct lb_framebuffer fb = {0};
if (!IS_ENABLED(CONFIG_LINEAR_FRAMEBUFFER) || fill_lb_framebuffer(&fb)) return;