Kyösti Mälkki has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/33051 )
Change subject: src/arch/x86: Prevent attack on null pointer dereference ......................................................................
Patch Set 3:
(2 comments)
https://review.coreboot.org/#/c/33051/3/src/arch/x86/acpi.c File src/arch/x86/acpi.c:
https://review.coreboot.org/#/c/33051/3/src/arch/x86/acpi.c@219 PS3, Line 219: memset((void *)madt, 0, sizeof(acpi_madt_t)); IMHO one should have tested for madt!=NULL before this line. Possibly would have taken care of the static analyzer complaint too as header == &(madt->header) == madt.
https://review.coreboot.org/#/c/33051/3/src/arch/x86/acpi.c@225 PS3, Line 225: memcpy(header->signature, "APIC", 4); I am guessing analyzer complained on this line only? The signature is the first field of hearder, so only this might be mistaken for NULL by analyzer?