mirror of
https://github.com/riscv-software-src/opensbi.git
synced 2025-08-29 09:31:55 +01:00
platform: generic: Pack the FDT after applying fixups
This minimizes the size that will be reserved by the OS for the FDT, and it prevents the FDT buffer from containing uninitialized memory, which can be important for some simulation platforms and for attestation. Closes: https://github.com/riscv-software-src/opensbi/issues/388 Signed-off-by: Samuel Holland <samuel.holland@sifive.com> Reviewed-by: Anup Patel <anup@brainfault.org> Link: https://lore.kernel.org/r/20250722233923.1356605-1-samuel.holland@sifive.com Signed-off-by: Anup Patel <anup@brainfault.org>
This commit is contained in:

committed by
Anup Patel

parent
525ac970b3
commit
bbe9a23060
@@ -245,6 +245,8 @@ int generic_final_init(bool cold_boot)
|
||||
fdt_fixups(fdt);
|
||||
fdt_domain_fixup(fdt);
|
||||
|
||||
fdt_pack(fdt);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user