Attention is currently required from: Anil Kumar K, Subrata Banik, Andrey Petrov, Patrick Rudolph. Tim Wawrzynczak has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/59638 )
Change subject: [WIP] src/drivers/intel/fsp2_0: Update GUID for FSP_NON_VOLATILE_STORAGE_HOB2 HOB introduced in FSP 2.3 ......................................................................
Patch Set 8:
(3 comments)
File src/drivers/intel/fsp2_0/hand_off_block.c:
https://review.coreboot.org/c/coreboot/+/59638/comment/efa6cc5d_3833edd5 PS8, Line 25: #if CONFIG(PLATFORM_USES_FSP2_3) suggestion: don't guard the definition of this, I will explain more below
https://review.coreboot.org/c/coreboot/+/59638/comment/e051127d_51bb27cf PS8, Line 318: #if CONFIG(PLATFORM_USES_FSP2_3) : : void *hob_ptr = NULL; : hob_ptr = fsp_find_extension_hob_by_guid(fsp_nv_storage_guid_2, size); : if (hob_ptr != NULL) { : size = (fsp_nvs_hob2_data_region_header *) hob_ptr->nvs_data_length; : return (fsp_nvs_hob2_data_region_header *) hob_ptr->nvs_data_ptr; : } : #endif : return fsp_find_extension_hob_by_guid(fsp_nv_storage_guid, size); suggestion: we don't need the preprocessor, we can just do something like
``` if (CONFIG(PLATFORM_USES_FSP2_3)) { void *hob_ptr = NULL; hob_ptr = fsp_find_extension_hob_by_guid(fsp_nv_storage_guid_2, size); if (hob_ptr != NULL) { size = (fsp_nvs_hob2_data_region_header *) hob_ptr->nvs_data_length; return (fsp_nvs_hob2_data_region_header *) hob_ptr->nvs_data_ptr; } } else { return fsp_find_extension_hob_by_guid(fsp_nv_storage_guid, size); } ```
File src/drivers/intel/fsp2_0/include/fsp/util.h:
https://review.coreboot.org/c/coreboot/+/59638/comment/efdc3b0c_51e538db PS8, Line 30: #if CONFIG(PLATFORM_USES_FSP2_3) : struct fsp_nvs_hob2_data_region_header { : uint64_t nvs_data_ptr; : uint64_t nvs_data_length; : } __packed; : #endif : no need to guard this