Michael Niewöhner has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/49050 )
Change subject: drivers/vpd: Add support to read device serial from VPD ......................................................................
Patch Set 3:
(4 comments)
https://review.coreboot.org/c/coreboot/+/49050/1/src/drivers/vpd/vpd.c File src/drivers/vpd/vpd.c:
https://review.coreboot.org/c/coreboot/+/49050/1/src/drivers/vpd/vpd.c@308 PS1, Line 308: static
ok, can be dropped then I guess. […]
without static you're returning a pointer to that string but the variable is local. that won't work ofc. that's why vpd_gets uses that buffer :D my fault, sry ;)
https://review.coreboot.org/c/coreboot/+/49050/1/src/drivers/vpd/vpd.c@306 PS1, Line 306: har *smbios_system_serial_number(void) : { : static char serial[VPD_SERIAL_LEN]; : if (vpd_gets(VPD_KEY_SYSTEM_SERIAL, serial, VPD_SERIAL_LEN, VPD_RO)) : return serial; : return ""; : } : : const char *smbios_mainboard_serial_number(void) : { : static char serial[VPD_SERIAL_LEN]; : if (vpd_gets(VPD_KEY_MAINBOARD_SERIAL, serial, VPD_SERIAL_LEN, VPD_RO)) : return serial; : return ""; : } : #endif
ah, I missed that it's defined weak in smbios code, nvm then
Done
https://review.coreboot.org/c/coreboot/+/49050/2/src/drivers/vpd/vpd.c File src/drivers/vpd/vpd.c:
https://review.coreboot.org/c/coreboot/+/49050/2/src/drivers/vpd/vpd.c@301 PS2, Line 301: #if CONFIG(SMBIOS_SERIAL_FROM_VPD)
Does the code need to be in this compilation unit? If not, the guard could […]
Done
https://review.coreboot.org/c/coreboot/+/49050/3/src/mainboard/google/dralli... File src/mainboard/google/drallion/ramstage.c:
https://review.coreboot.org/c/coreboot/+/49050/3/src/mainboard/google/dralli... PS3, Line 9: #include <vendorcode/google/chromeos/chromeos.h> shouldn't be needed anymore