mirror of https://github.com/acidanthera/audk.git
Remove unnecessary use of FixedPcdxxx() functions and [FixedPcd] INF sections. These should only be used for PCDs that are used to pre-init global variables, pre-init global structures, or size arrays.
Do some minor clean ups to INF files git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9870 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
adbd84b439
commit
29a3f13989
|
@ -2,7 +2,7 @@
|
||||||
Firmware Block Services to support emulating non-volatile variables
|
Firmware Block Services to support emulating non-volatile variables
|
||||||
by pretending that a memory buffer is storage for the NV variables.
|
by pretending that a memory buffer is storage for the NV variables.
|
||||||
|
|
||||||
Copyright (c) 2006 - 2009, Intel Corporation
|
Copyright (c) 2006 - 2010, Intel Corporation
|
||||||
All rights reserved. This program and the accompanying materials
|
All rights reserved. This program and the accompanying materials
|
||||||
are licensed and made available under the terms and conditions of the BSD License
|
are licensed and made available under the terms and conditions of the BSD License
|
||||||
which accompanies this distribution. The full text of the license may be found at
|
which accompanies this distribution. The full text of the license may be found at
|
||||||
|
@ -769,8 +769,8 @@ FvbInitialize (
|
||||||
// Verify that the PCD's are set correctly.
|
// Verify that the PCD's are set correctly.
|
||||||
//
|
//
|
||||||
if (
|
if (
|
||||||
(FixedPcdGet32 (PcdVariableStoreSize) +
|
(PcdGet32 (PcdVariableStoreSize) +
|
||||||
FixedPcdGet32 (PcdFlashNvStorageFtwWorkingSize)
|
PcdGet32 (PcdFlashNvStorageFtwWorkingSize)
|
||||||
) >
|
) >
|
||||||
EMU_FVB_BLOCK_SIZE
|
EMU_FVB_BLOCK_SIZE
|
||||||
) {
|
) {
|
||||||
|
@ -820,7 +820,7 @@ FvbInitialize (
|
||||||
//
|
//
|
||||||
// Initialize the Fault Tolerant Write data area
|
// Initialize the Fault Tolerant Write data area
|
||||||
//
|
//
|
||||||
SubPtr = (VOID*) ((UINT8*) Ptr + FixedPcdGet32 (PcdVariableStoreSize));
|
SubPtr = (VOID*) ((UINT8*) Ptr + PcdGet32 (PcdVariableStoreSize));
|
||||||
if (Initialize) {
|
if (Initialize) {
|
||||||
InitializeFtwState (SubPtr);
|
InitializeFtwState (SubPtr);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Firmware Block Services to support emulating non-volatile variables
|
# Firmware Block Services to support emulating non-volatile variables
|
||||||
# by pretending that a memory buffer is storage for the NV variables.
|
# by pretending that a memory buffer is storage for the NV variables.
|
||||||
#
|
#
|
||||||
# Copyright (c) 2008 - 2009, Intel Corporation
|
# Copyright (c) 2008 - 2010, Intel Corporation
|
||||||
#
|
#
|
||||||
# All rights reserved. This program and the accompanying materials
|
# All rights reserved. This program and the accompanying materials
|
||||||
# are licensed and made available under the terms and conditions of the BSD License
|
# are licensed and made available under the terms and conditions of the BSD License
|
||||||
|
@ -19,9 +19,6 @@
|
||||||
FILE_GUID = 22dc2b60-fe40-42ac-b01f-3ab1fad9aad8
|
FILE_GUID = 22dc2b60-fe40-42ac-b01f-3ab1fad9aad8
|
||||||
MODULE_TYPE = DXE_RUNTIME_DRIVER
|
MODULE_TYPE = DXE_RUNTIME_DRIVER
|
||||||
VERSION_STRING = 1.0
|
VERSION_STRING = 1.0
|
||||||
EDK_RELEASE_VERSION = 0x00020000
|
|
||||||
EFI_SPECIFICATION_VERSION = 0x00020000
|
|
||||||
|
|
||||||
ENTRY_POINT = FvbInitialize
|
ENTRY_POINT = FvbInitialize
|
||||||
|
|
||||||
#
|
#
|
||||||
|
@ -30,16 +27,14 @@
|
||||||
# VALID_ARCHITECTURES = IA32 X64 IPF EBC
|
# VALID_ARCHITECTURES = IA32 X64 IPF EBC
|
||||||
#
|
#
|
||||||
|
|
||||||
[Sources.common]
|
[Sources]
|
||||||
Fvb.c
|
Fvb.c
|
||||||
|
|
||||||
|
|
||||||
[Packages]
|
[Packages]
|
||||||
MdePkg/MdePkg.dec
|
MdePkg/MdePkg.dec
|
||||||
MdeModulePkg/MdeModulePkg.dec
|
MdeModulePkg/MdeModulePkg.dec
|
||||||
OvmfPkg/OvmfPkg.dec
|
OvmfPkg/OvmfPkg.dec
|
||||||
|
|
||||||
|
|
||||||
[LibraryClasses]
|
[LibraryClasses]
|
||||||
BaseLib
|
BaseLib
|
||||||
BaseMemoryLib
|
BaseMemoryLib
|
||||||
|
@ -54,30 +49,25 @@
|
||||||
UefiLib
|
UefiLib
|
||||||
UefiRuntimeLib
|
UefiRuntimeLib
|
||||||
|
|
||||||
|
|
||||||
[Guids]
|
[Guids]
|
||||||
gEfiEventVirtualAddressChangeGuid # ALWAYS_CONSUMED Create Event: EVENT_GROUP_GUID
|
gEfiEventVirtualAddressChangeGuid # ALWAYS_CONSUMED Create Event: EVENT_GROUP_GUID
|
||||||
|
|
||||||
|
|
||||||
[Protocols]
|
[Protocols]
|
||||||
gEfiFirmwareVolumeBlockProtocolGuid # PROTOCOL ALWAYS_PRODUCED
|
gEfiFirmwareVolumeBlockProtocolGuid # PROTOCOL ALWAYS_PRODUCED
|
||||||
gEfiDevicePathProtocolGuid # PROTOCOL ALWAYS_PRODUCED
|
gEfiDevicePathProtocolGuid # PROTOCOL ALWAYS_PRODUCED
|
||||||
|
|
||||||
|
|
||||||
[FixedPcd]
|
[FixedPcd]
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize
|
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdVariableStoreSize
|
gEfiMdeModulePkgTokenSpaceGuid.PcdVariableStoreSize
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingSize
|
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingSize
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize
|
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize
|
||||||
|
|
||||||
|
|
||||||
[Pcd]
|
[Pcd]
|
||||||
|
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase
|
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingBase
|
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingBase
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareBase
|
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareBase
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdEmuVariableNvStoreReserved
|
gEfiMdeModulePkgTokenSpaceGuid.PcdEmuVariableNvStoreReserved
|
||||||
|
|
||||||
|
|
||||||
[Depex]
|
[Depex]
|
||||||
TRUE
|
TRUE
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/**@file
|
/**@file
|
||||||
Platform PEI driver
|
Platform PEI driver
|
||||||
|
|
||||||
Copyright (c) 2006 - 2009, Intel Corporation
|
Copyright (c) 2006 - 2010, Intel Corporation
|
||||||
All rights reserved. This program and the accompanying materials
|
All rights reserved. This program and the accompanying materials
|
||||||
are licensed and made available under the terms and conditions of the BSD License
|
are licensed and made available under the terms and conditions of the BSD License
|
||||||
which accompanies this distribution. The full text of the license may be found at
|
which accompanies this distribution. The full text of the license may be found at
|
||||||
|
@ -173,12 +173,12 @@ ReserveEmuVariableNvStore (
|
||||||
VariableStore =
|
VariableStore =
|
||||||
(EFI_PHYSICAL_ADDRESS)(UINTN)
|
(EFI_PHYSICAL_ADDRESS)(UINTN)
|
||||||
AllocateRuntimePool (
|
AllocateRuntimePool (
|
||||||
2 * FixedPcdGet32(PcdFlashNvStorageFtwSpareSize)
|
2 * PcdGet32 (PcdFlashNvStorageFtwSpareSize)
|
||||||
);
|
);
|
||||||
DEBUG ((EFI_D_INFO,
|
DEBUG ((EFI_D_INFO,
|
||||||
"Reserved variable store memory: 0x%lX; size: %dkb\n",
|
"Reserved variable store memory: 0x%lX; size: %dkb\n",
|
||||||
VariableStore,
|
VariableStore,
|
||||||
(2 * FixedPcdGet32(PcdFlashNvStorageFtwSpareSize)) / 1024
|
(2 * PcdGet32 (PcdFlashNvStorageFtwSpareSize)) / 1024
|
||||||
));
|
));
|
||||||
PcdSet64 (PcdEmuVariableNvStoreReserved, VariableStore);
|
PcdSet64 (PcdEmuVariableNvStoreReserved, VariableStore);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Platform PEI driver
|
# Platform PEI driver
|
||||||
#
|
#
|
||||||
# This module provides platform specific function to detect boot mode.
|
# This module provides platform specific function to detect boot mode.
|
||||||
# Copyright (c) 2006 - 2009, Intel Corporation
|
# Copyright (c) 2006 - 2010, Intel Corporation
|
||||||
#
|
#
|
||||||
# All rights reserved. This program and the accompanying materials
|
# All rights reserved. This program and the accompanying materials
|
||||||
# are licensed and made available under the terms and conditions of the BSD License
|
# are licensed and made available under the terms and conditions of the BSD License
|
||||||
|
@ -20,9 +20,6 @@
|
||||||
FILE_GUID = 222c386d-5abc-4fb4-b124-fbb82488acf4
|
FILE_GUID = 222c386d-5abc-4fb4-b124-fbb82488acf4
|
||||||
MODULE_TYPE = PEIM
|
MODULE_TYPE = PEIM
|
||||||
VERSION_STRING = 1.0
|
VERSION_STRING = 1.0
|
||||||
EDK_RELEASE_VERSION = 0x00020000
|
|
||||||
EFI_SPECIFICATION_VERSION = 0x00020000
|
|
||||||
|
|
||||||
ENTRY_POINT = InitializePlatform
|
ENTRY_POINT = InitializePlatform
|
||||||
|
|
||||||
#
|
#
|
||||||
|
@ -31,7 +28,7 @@
|
||||||
# VALID_ARCHITECTURES = IA32 X64 IPF EBC
|
# VALID_ARCHITECTURES = IA32 X64 IPF EBC
|
||||||
#
|
#
|
||||||
|
|
||||||
[Sources.common]
|
[Sources]
|
||||||
Cmos.c
|
Cmos.c
|
||||||
Fv.c
|
Fv.c
|
||||||
MemDetect.c
|
MemDetect.c
|
||||||
|
@ -53,14 +50,12 @@
|
||||||
PeiServicesTablePointerLib
|
PeiServicesTablePointerLib
|
||||||
PeimEntryPoint
|
PeimEntryPoint
|
||||||
|
|
||||||
[FixedPcd.common]
|
[Pcd]
|
||||||
gUefiOvmfPkgTokenSpaceGuid.PcdOvmfMemFvBase
|
gUefiOvmfPkgTokenSpaceGuid.PcdOvmfMemFvBase
|
||||||
gUefiOvmfPkgTokenSpaceGuid.PcdOvmfMemFvSize
|
gUefiOvmfPkgTokenSpaceGuid.PcdOvmfMemFvSize
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdVariableStoreSize
|
gEfiMdeModulePkgTokenSpaceGuid.PcdVariableStoreSize
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize
|
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize
|
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize
|
||||||
|
|
||||||
[Pcd.common]
|
|
||||||
gEfiMdeModulePkgTokenSpaceGuid.PcdEmuVariableNvStoreReserved
|
gEfiMdeModulePkgTokenSpaceGuid.PcdEmuVariableNvStoreReserved
|
||||||
|
|
||||||
[Depex]
|
[Depex]
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#/** @file
|
#/** @file
|
||||||
# SEC Driver
|
# SEC Driver
|
||||||
#
|
#
|
||||||
# Copyright (c) 2008 - 2009, Intel Corporation
|
# Copyright (c) 2008 - 2010, Intel Corporation
|
||||||
#
|
#
|
||||||
# All rights reserved. This program and the accompanying materials
|
# All rights reserved. This program and the accompanying materials
|
||||||
# are licensed and made available under the terms and conditions of the BSD License
|
# are licensed and made available under the terms and conditions of the BSD License
|
||||||
|
@ -19,8 +19,6 @@
|
||||||
FILE_GUID = df1ccef6-f301-4a63-9661-fc6030dcc880
|
FILE_GUID = df1ccef6-f301-4a63-9661-fc6030dcc880
|
||||||
MODULE_TYPE = SEC
|
MODULE_TYPE = SEC
|
||||||
VERSION_STRING = 1.0
|
VERSION_STRING = 1.0
|
||||||
EDK_RELEASE_VERSION = 0x00020000
|
|
||||||
EFI_SPECIFICATION_VERSION = 0x00020000
|
|
||||||
ENTRY_POINT = SecMain
|
ENTRY_POINT = SecMain
|
||||||
|
|
||||||
#
|
#
|
||||||
|
@ -59,7 +57,7 @@
|
||||||
[Ppis]
|
[Ppis]
|
||||||
gEfiTemporaryRamSupportPpiGuid # PPI ALWAYS_PRODUCED
|
gEfiTemporaryRamSupportPpiGuid # PPI ALWAYS_PRODUCED
|
||||||
|
|
||||||
[FixedPcd.common]
|
[Pcd]
|
||||||
gUefiOvmfPkgTokenSpaceGuid.PcdOvmfMemFvBase
|
gUefiOvmfPkgTokenSpaceGuid.PcdOvmfMemFvBase
|
||||||
gUefiOvmfPkgTokenSpaceGuid.PcdOvmfMemFvSize
|
gUefiOvmfPkgTokenSpaceGuid.PcdOvmfMemFvSize
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue