Update SEC Platform Information PPI according to PI 1.2 errata A.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10118 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
xli24 2010-02-27 15:37:52 +00:00
parent 7fedcf9d2a
commit 53f3249595
2 changed files with 48 additions and 26 deletions

View File

@ -6,7 +6,7 @@
environment and also encapsulates knowledge of at least the
location of the Boot Firmware Volume (BFV).
Copyright (c) 2006 - 2008, Intel Corporation
Copyright (c) 2006 - 2010, Intel Corporation
All rights reserved. This program and the accompanying materials
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
@ -87,40 +87,61 @@ typedef union {
#define NORMAL_BOOT_CALL 0x0
#define RECOVERY_CHECK_CALL 0x3
typedef EFI_HEALTH_FLAGS X64_HANDOFF_STATUS;
typedef EFI_HEALTH_FLAGS IA32_HANDOFF_STATUS;
///
/// The hand-off status structure for Itanium architecture.
///
typedef struct {
///
/// SALE_ENTRY state : 3 = Recovery_Check
/// and 0 = RESET or Normal_Boot phase.
///
UINT8 BootPhase;
///
/// Firmware status on entry to SALE.
///
UINT8 FWStatus;
UINT16 Reserved1;
UINT32 Reserved2;
///
/// Geographically significant unique processor ID assigned by PAL.
///
UINT16 ProcId;
UINT16 Reserved3;
UINT8 IdMask;
UINT8 EidMask;
UINT16 Reserved4;
///
/// Address to make PAL calls
///
UINT64 PalCallAddress;
///
/// If the entry state is RECOVERY_CHECK, this contains the PAL_RESET
/// return address, and if entry state is RESET, this contains
/// address for PAL_authentication call.
///
UINT64 PalSpecialAddress;
///
/// GR35 from PALE_EXIT state
///
UINT64 SelfTestStatus;
///
/// GR37 from PALE_EXIT state.
///
UINT64 SelfTestControl;
UINT64 MemoryBufferRequired;
} IPF_HANDOFF_STATUS;
} ITANIUM_HANDOFF_STATUS;
///
/// EFI_SEC_PLATFORM_INFORMATION_RECORD
///
typedef struct {
///
/// Contains information generated by microcode, hardware,
/// and/or the Itanium processor PAL code about the state
/// of the processor upon reset.
///
EFI_HEALTH_FLAGS HealthFlags;
typedef union {
IA32_HANDOFF_STATUS IA32HealthFlags;
X64_HANDOFF_STATUS x64HealthFlags;
ITANIUM_HANDOFF_STATUS ItaniumHealthFlags;
} EFI_SEC_PLATFORM_INFORMATION_RECORD;
/**
This interface conveys state information out of the Security (SEC) phase into PEI.
@ -137,7 +158,8 @@ typedef struct {
@param PlatformInformationRecord Pointer to the EFI_SEC_PLATFORM_INFORMATION_RECORD.
@retval EFI_SUCCESS The data was successfully returned.
@retval EFI_BUFFER_TOO_SMALL The buffer was too small.
@retval EFI_BUFFER_TOO_SMALL The buffer was too small. The current buffer size needed to
hold the record is returned in StructureSize.
**/
typedef

View File

@ -1,7 +1,7 @@
/** @file
PAL Call Services Function.
Copyright (c) 2006 - 2008, Intel Corporation<BR>
Copyright (c) 2006 - 2010, Intel Corporation<BR>
All rights reserved. This program and the accompanying materials
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
@ -57,13 +57,13 @@ PalCall (
IN UINT64 Arg4
)
{
UINT64 PalCallAddress;
PAL_CALL_RETURN ReturnVal;
CONST EFI_PEI_SERVICES **PeiServices;
EFI_STATUS Status;
EFI_SEC_PLATFORM_INFORMATION_PPI *SecPlatformPpi;
IPF_HANDOFF_STATUS IpfStatus;
UINT64 RecordSize;
UINT64 PalCallAddress;
PAL_CALL_RETURN ReturnVal;
CONST EFI_PEI_SERVICES **PeiServices;
EFI_STATUS Status;
EFI_SEC_PLATFORM_INFORMATION_PPI *SecPlatformPpi;
EFI_SEC_PLATFORM_INFORMATION_RECORD SecPlatformInfoRecord;
UINT64 RecordSize;
//
// Get PEI Service Table Pointer
@ -84,13 +84,13 @@ PalCall (
//
// Retrieve PAL call address from platform information reported by the PPI
//
RecordSize = sizeof (IpfStatus);
RecordSize = sizeof (SecPlatformInfoRecord);
SecPlatformPpi->PlatformInformation (
PeiServices,
&RecordSize,
(EFI_SEC_PLATFORM_INFORMATION_RECORD *) &IpfStatus
&SecPlatformInfoRecord
);
PalCallAddress = IpfStatus.PalCallAddress;
PalCallAddress = SecPlatformInfoRecord.ItaniumHealthFlags.PalCallAddress;
ReturnVal = AsmPalCall (PalCallAddress, Index, Arg2, Arg3, Arg4);