X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=MdeModulePkg%2FCore%2FPei%2FDispatcher%2FDispatcher.c;h=bdbb00b205f86dcec674c108743fe5a830811168;hb=087e13cbe2946501afcce31b62a1b342715bc20d;hp=6883bc300f1f35ecaeb110cb92501d751b889cb6;hpb=341a658fca6ff05deb7a9db4fbc7cc491dff473f;p=mirror_edk2.git diff --git a/MdeModulePkg/Core/Pei/Dispatcher/Dispatcher.c b/MdeModulePkg/Core/Pei/Dispatcher/Dispatcher.c index 6883bc300f..bdbb00b205 100644 --- a/MdeModulePkg/Core/Pei/Dispatcher/Dispatcher.c +++ b/MdeModulePkg/Core/Pei/Dispatcher/Dispatcher.c @@ -75,7 +75,7 @@ DiscoverPeimsAndOrderWithApriori ( // // Go ahead to scan this Fv, and cache FileHandles within it. // - for (PeimCount = 0; PeimCount < FixedPcdGet32 (PcdPeiCoreMaxPeimPerFv); PeimCount++) { + for (PeimCount = 0; PeimCount < PcdGet32 (PcdPeiCoreMaxPeimPerFv); PeimCount++) { Status = FvPpi->FindFileByType (FvPpi, PEI_CORE_INTERNAL_FFS_FILE_DISPATCH_TYPE, CoreFileHandle->FvHandle, &FileHandle); if (Status != EFI_SUCCESS) { break; @@ -88,7 +88,7 @@ DiscoverPeimsAndOrderWithApriori ( // Check whether the count of Peims exceeds the max support PEIMs in a FV image // If more Peims are required in a FV image, PcdPeiCoreMaxPeimPerFv can be set to a larger value in DSC file. // - ASSERT (PeimCount < FixedPcdGet32 (PcdPeiCoreMaxPeimPerFv)); + ASSERT (PeimCount < PcdGet32 (PcdPeiCoreMaxPeimPerFv)); // // Get Apriori File handle @@ -293,7 +293,7 @@ PeiDispatcher ( SaveCurrentFileHandle = Private->CurrentFileHandle; for (Index1 = 0; Index1 <= SaveCurrentFvCount; Index1++) { - for (Index2 = 0; (Index2 < FixedPcdGet32 (PcdPeiCoreMaxPeimPerFv)) && (Private->Fv[Index1].FvFileHandles[Index2] != NULL); Index2++) { + for (Index2 = 0; (Index2 < PcdGet32 (PcdPeiCoreMaxPeimPerFv)) && (Private->Fv[Index1].FvFileHandles[Index2] != NULL); Index2++) { if (Private->Fv[Index1].PeimState[Index2] == PEIM_STATE_REGISITER_FOR_SHADOW) { PeimFileHandle = Private->Fv[Index1].FvFileHandles[Index2]; Status = PeiLoadImage ( @@ -316,9 +316,9 @@ PeiDispatcher ( // PeimEntryPoint = (EFI_PEIM_ENTRY_POINT2)(UINTN)EntryPoint; - PERF_START (0, "PEIM", NULL, 0); + PERF_START (PeimFileHandle, "PEIM", NULL, 0); PeimEntryPoint(PeimFileHandle, (const EFI_PEI_SERVICES **) &Private->PS); - PERF_END (0, "PEIM", NULL, 0); + PERF_END (PeimFileHandle, "PEIM", NULL, 0); } // @@ -379,7 +379,7 @@ PeiDispatcher ( // Start to dispatch all modules within the current Fv. // for (PeimCount = Private->CurrentPeimCount; - (PeimCount < FixedPcdGet32 (PcdPeiCoreMaxPeimPerFv)) && (Private->CurrentFvFileHandles[PeimCount] != NULL); + (PeimCount < PcdGet32 (PcdPeiCoreMaxPeimPerFv)) && (Private->CurrentFvFileHandles[PeimCount] != NULL); PeimCount++) { Private->CurrentPeimCount = PeimCount; PeimFileHandle = Private->CurrentFileHandle = Private->CurrentFvFileHandles[PeimCount]; @@ -414,13 +414,13 @@ PeiDispatcher ( // The PEIM has its dependencies satisfied, and its entry point // has been found, so invoke it. // - PERF_START (0, "PEIM", NULL, 0); + PERF_START (PeimFileHandle, "PEIM", NULL, 0); ExtendedData.Handle = (EFI_HANDLE)PeimFileHandle; REPORT_STATUS_CODE_WITH_EXTENDED_DATA ( EFI_PROGRESS_CODE, - PcdGet32(PcdStatusCodeValuePeimDispatch), + (EFI_SOFTWARE_PEI_CORE | EFI_SW_PC_INIT_BEGIN), (VOID *)(&ExtendedData), sizeof (ExtendedData) ); @@ -445,11 +445,11 @@ PeiDispatcher ( REPORT_STATUS_CODE_WITH_EXTENDED_DATA ( EFI_PROGRESS_CODE, - PcdGet32(PcdStatusCodeValuePeimDispatch), + (EFI_SOFTWARE_PEI_CORE | EFI_SW_PC_INIT_BEGIN), (VOID *)(&ExtendedData), sizeof (ExtendedData) ); - PERF_END (0, "PEIM", NULL, 0); + PERF_END (PeimFileHandle, "PEIM", NULL, 0); }