OvmfPkg: Refactor MeasureHobList
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=4243 MeasureHobList once was implemented in PeilessStartupLib and it does measurement and logging for TdHob in one go, using TpmMeasureAndLogData(). But it doesn't work in SEC. This patch splits MeasureHobList into 2 functions and implement them in SecTdxHelperLib. - TdxHelperMeasureTdHob - TdxHelperBuildGuidHobForTdxMeasurement TdxHelperMeasureTdHob measures the TdHob and stores the hash value in WorkArea. TdxHelperBuildGuidHobForTdxMeasurement builds GuidHob for the measurement based on the hash value in WorkArea. After these 2 functions are introduced, PeilessStartupLib should also be updated: - Call these 2 functions instead of the MeasureHobList - Delete the duplicated codes in PeilessStartupLib Cc: Erdem Aktas <erdemaktas@google.com> Cc: James Bottomley <jejb@linux.ibm.com> Cc: Jiewen Yao <jiewen.yao@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.com> Cc: Tom Lendacky <thomas.lendacky@amd.com> Cc: Michael Roth <michael.roth@amd.com> Acked-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Jiewen Yao <jiewen.yao@intel.com> Signed-off-by: Min Xu <min.m.xu@intel.com>
This commit is contained in:
@@ -58,21 +58,6 @@ EFIAPI
|
||||
ConstructSecHobList (
|
||||
);
|
||||
|
||||
/**
|
||||
Measure the Hoblist passed from the VMM.
|
||||
|
||||
@param[in] VmmHobList The Hoblist pass the firmware
|
||||
|
||||
@retval EFI_SUCCESS Fv image is measured successfully
|
||||
or it has been already measured.
|
||||
@retval Others Other errors as indicated
|
||||
**/
|
||||
EFI_STATUS
|
||||
EFIAPI
|
||||
MeasureHobList (
|
||||
IN CONST VOID *VmmHobList
|
||||
);
|
||||
|
||||
/**
|
||||
Measure FV image.
|
||||
|
||||
|
Reference in New Issue
Block a user