IntelFrameworkModulePkg: Clean up source files
1. Do not use tab characters 2. No trailing white space in one line 3. All files must end with CRLF Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao <liming.gao@intel.com>
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
This is an implementation of the ACPI S3 Save protocol. This is defined in
|
||||
S3 boot path specification 0.9.
|
||||
|
||||
Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -55,7 +55,7 @@ EFI_ACPI_S3_SAVE_PROTOCOL mS3Save = {
|
||||
|
||||
@param MemoryType Memory type of memory to allocate.
|
||||
@param Size Size of memory to allocate.
|
||||
|
||||
|
||||
@return Allocated address for output.
|
||||
|
||||
**/
|
||||
@@ -88,7 +88,7 @@ AllocateMemoryBelow4G (
|
||||
}
|
||||
|
||||
/**
|
||||
Gets the buffer of legacy memory below 1 MB
|
||||
Gets the buffer of legacy memory below 1 MB
|
||||
This function is to get the buffer in legacy memory below 1MB that is required during S3 resume.
|
||||
|
||||
@param This A pointer to the EFI_ACPI_S3_SAVE_PROTOCOL instance.
|
||||
@@ -115,9 +115,9 @@ LegacyGetS3MemorySize (
|
||||
|
||||
/**
|
||||
Prepares all information that is needed in the S3 resume boot path.
|
||||
|
||||
Allocate the resources or prepare informations and save in ACPI variable set for S3 resume boot path
|
||||
|
||||
|
||||
Allocate the resources or prepare informations and save in ACPI variable set for S3 resume boot path
|
||||
|
||||
@param This A pointer to the EFI_ACPI_S3_SAVE_PROTOCOL instance.
|
||||
@param LegacyMemoryAddress The base address of legacy memory.
|
||||
|
||||
@@ -156,9 +156,9 @@ S3Ready (
|
||||
|
||||
/**
|
||||
The Driver Entry Point.
|
||||
|
||||
|
||||
The function is the driver Entry point which will produce AcpiS3SaveProtocol.
|
||||
|
||||
|
||||
@param ImageHandle A handle for the image that is initializing this driver
|
||||
@param SystemTable A pointer to the EFI system table
|
||||
|
||||
|
@@ -1,8 +1,8 @@
|
||||
/** @file
|
||||
This is an implementation of the ACPI S3 Save protocol. This is defined in
|
||||
This is an implementation of the ACPI S3 Save protocol. This is defined in
|
||||
S3 boot path specification 0.9.
|
||||
|
||||
Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -19,7 +19,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#define _ACPI_S3_SAVE_H_
|
||||
|
||||
/**
|
||||
Gets the buffer of legacy memory below 1 MB
|
||||
Gets the buffer of legacy memory below 1 MB
|
||||
This function is to get the buffer in legacy memory below 1MB that is required during S3 resume.
|
||||
|
||||
@param This A pointer to the EFI_ACPI_S3_SAVE_PROTOCOL instance.
|
||||
@@ -38,9 +38,9 @@ LegacyGetS3MemorySize (
|
||||
|
||||
/**
|
||||
Prepares all information that is needed in the S3 resume boot path.
|
||||
|
||||
Allocate the resources or prepare informations and save in ACPI variable set for S3 resume boot path
|
||||
|
||||
|
||||
Allocate the resources or prepare informations and save in ACPI variable set for S3 resume boot path
|
||||
|
||||
@param This A pointer to the EFI_ACPI_S3_SAVE_PROTOCOL instance.
|
||||
@param LegacyMemoryAddress The base address of legacy memory.
|
||||
|
||||
@@ -54,6 +54,6 @@ EFI_STATUS
|
||||
EFIAPI
|
||||
S3Ready (
|
||||
IN EFI_ACPI_S3_SAVE_PROTOCOL *This,
|
||||
IN VOID *LegacyMemoryAddress
|
||||
IN VOID *LegacyMemoryAddress
|
||||
);
|
||||
#endif
|
||||
|
@@ -1,7 +1,7 @@
|
||||
## @file
|
||||
# AcpiS3Save module installs ACPI S3 Save protocol to prepare S3 boot data.
|
||||
#
|
||||
# Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
#
|
||||
# This program and the accompanying materials are
|
||||
# licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -73,7 +73,7 @@
|
||||
[Depex]
|
||||
#
|
||||
# Note: the extra dependency of gEfiMpServiceProtocolGuid is to ensure that ACPI variable is set by MpDxe driver before
|
||||
# AcpiS3SaveDxe module is executed.
|
||||
# AcpiS3SaveDxe module is executed.
|
||||
#
|
||||
gEfiVariableArchProtocolGuid AND gEfiVariableWriteArchProtocolGuid AND gEfiMpServiceProtocolGuid
|
||||
|
||||
|
@@ -3,13 +3,13 @@
|
||||
//
|
||||
// AcpiS3Save module installs ACPI S3 Save protocol to prepare S3 boot data.
|
||||
//
|
||||
// Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// AcpiS3SaveDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials are
|
||||
// licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -13,8 +13,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"ACPI S3 Save State DXE Driver"
|
||||
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
This is an implementation of the AcpiVariable platform field for ECP platform.
|
||||
|
||||
Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -25,8 +25,8 @@ typedef struct {
|
||||
ACPI_CPU_DATA_COMPATIBILITY AcpiCpuData;
|
||||
EFI_PHYSICAL_ADDRESS VideoOpromAddress;
|
||||
UINT32 VideoOpromSize;
|
||||
EFI_PHYSICAL_ADDRESS S3DebugBufferAddress;
|
||||
EFI_PHYSICAL_ADDRESS S3ResumeNvsEntryPoint;
|
||||
EFI_PHYSICAL_ADDRESS S3DebugBufferAddress;
|
||||
EFI_PHYSICAL_ADDRESS S3ResumeNvsEntryPoint;
|
||||
} ACPI_VARIABLE_SET_COMPATIBILITY;
|
||||
|
||||
**/
|
||||
@@ -54,7 +54,7 @@ ACPI_VARIABLE_SET_COMPATIBILITY *mAcpiVariableSetCompatibility = N
|
||||
|
||||
@param MemoryType Memory type of memory to allocate.
|
||||
@param Size Size of memory to allocate.
|
||||
|
||||
|
||||
@return Allocated address for output.
|
||||
|
||||
**/
|
||||
@@ -167,8 +167,8 @@ InstallAcpiS3SaveThunk (
|
||||
);
|
||||
if (!EFI_ERROR (Status)) {
|
||||
//
|
||||
// On ECP platform, if framework CPU drivers are in use, The compatible version of ACPI variable set
|
||||
// should be produced by CPU driver.
|
||||
// On ECP platform, if framework CPU drivers are in use, The compatible version of ACPI variable set
|
||||
// should be produced by CPU driver.
|
||||
//
|
||||
VarSize = sizeof (mAcpiVariableSetCompatibility);
|
||||
Status = gRT->GetVariable (
|
||||
@@ -184,7 +184,7 @@ InstallAcpiS3SaveThunk (
|
||||
}
|
||||
} else {
|
||||
//
|
||||
// Allocate/initialize the compatible version of Acpi Variable Set since Framework chipset/platform
|
||||
// Allocate/initialize the compatible version of Acpi Variable Set since Framework chipset/platform
|
||||
// driver need this variable. ACPI_GLOBAL_VARIABLE variable is not used in runtime phase,
|
||||
// so RT attribute is not needed for it.
|
||||
//
|
||||
|
@@ -1,8 +1,8 @@
|
||||
/** @file
|
||||
This is an implementation of the ACPI Support protocol. This is defined in
|
||||
This is an implementation of the ACPI Support protocol. This is defined in
|
||||
the Tiano ACPI External Product Specification, revision 0.3.6.
|
||||
|
||||
Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -26,14 +26,14 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
EFI_HANDLE mHandle = NULL;
|
||||
|
||||
/**
|
||||
Entry point of the ACPI support driver. This function creates and initializes an instance of the ACPI Support
|
||||
Entry point of the ACPI support driver. This function creates and initializes an instance of the ACPI Support
|
||||
Protocol and installs it on a new handle.
|
||||
|
||||
@param ImageHandle A handle for the image that is initializing this driver
|
||||
@param SystemTable A pointer to the EFI system table
|
||||
@param SystemTable A pointer to the EFI system table
|
||||
|
||||
@retval EFI_SUCCESS Driver initialized successfully
|
||||
@retval EFI_LOAD_ERROR Failed to Initialize or has been loaded
|
||||
@retval EFI_LOAD_ERROR Failed to Initialize or has been loaded
|
||||
@retval EFI_OUT_OF_RESOURCES Could not allocate needed resources
|
||||
**/
|
||||
EFI_STATUS
|
||||
@@ -85,7 +85,7 @@ InstallAcpiSupport (
|
||||
NULL
|
||||
);
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
}
|
||||
}
|
||||
|
||||
return Status;
|
||||
}
|
||||
|
@@ -2,7 +2,7 @@
|
||||
This is an implementation of the ACPI Support protocol.
|
||||
It is in compliance with the 0.9 definition of the protocol.
|
||||
|
||||
Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -131,12 +131,12 @@ typedef struct {
|
||||
AcpiTableProtocol, \
|
||||
EFI_ACPI_SUPPORT_SIGNATURE \
|
||||
)
|
||||
|
||||
|
||||
/**
|
||||
Constructor for the ACPI support protocol.
|
||||
|
||||
Constructor for the ACPI support protocol.
|
||||
|
||||
Constructor for the ACPI support protocol to initializes instance data.
|
||||
|
||||
|
||||
@param AcpiSupportInstance Instance to construct
|
||||
|
||||
@retval EFI_SUCCESS Instance initialized.
|
||||
@@ -147,14 +147,14 @@ AcpiSupportAcpiSupportConstructor (
|
||||
IN EFI_ACPI_SUPPORT_INSTANCE *AcpiSupportInstance
|
||||
);
|
||||
/**
|
||||
Entry point of the ACPI support driver. This function creates and initializes an instance of the ACPI Support
|
||||
Entry point of the ACPI support driver. This function creates and initializes an instance of the ACPI Support
|
||||
Protocol and installs it on a new handle.
|
||||
|
||||
@param ImageHandle A handle for the image that is initializing this driver
|
||||
@param SystemTable A pointer to the EFI system table
|
||||
@param SystemTable A pointer to the EFI system table
|
||||
|
||||
@retval EFI_SUCCESS Driver initialized successfully
|
||||
@retval EFI_LOAD_ERROR Failed to Initialize or has been loaded
|
||||
@retval EFI_LOAD_ERROR Failed to Initialize or has been loaded
|
||||
@retval EFI_OUT_OF_RESOURCES Could not allocate needed resources
|
||||
**/
|
||||
EFI_STATUS
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
ACPI Support Protocol implementation
|
||||
|
||||
Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -19,9 +19,9 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
#include "AcpiSupport.h"
|
||||
//
|
||||
// The maximum number of tables that pre-allocated.
|
||||
// The maximum number of tables that pre-allocated.
|
||||
//
|
||||
UINTN mEfiAcpiMaxNumTables = EFI_ACPI_MAX_NUM_TABLES;
|
||||
UINTN mEfiAcpiMaxNumTables = EFI_ACPI_MAX_NUM_TABLES;
|
||||
/**
|
||||
This function adds an ACPI table to the table list. It will detect FACS and
|
||||
allocate the correct type of memory and properly align the table.
|
||||
@@ -91,10 +91,10 @@ ChecksumCommonTables (
|
||||
);
|
||||
|
||||
/**
|
||||
This function returns a table specified by an index if it exists.
|
||||
|
||||
The function returns a buffer containing the table that the caller must free.
|
||||
The function also returns a handle used to identify the table for update or
|
||||
This function returns a table specified by an index if it exists.
|
||||
|
||||
The function returns a buffer containing the table that the caller must free.
|
||||
The function also returns a handle used to identify the table for update or
|
||||
deletion using the SetAcpiTable function.
|
||||
|
||||
@param This Instance of the protocol.
|
||||
@@ -165,7 +165,7 @@ GetAcpiTable (
|
||||
}
|
||||
/**
|
||||
This function adds, removes, or updates ACPI tables. If the address is not
|
||||
null and the handle value is null, the table is added. If both the address and
|
||||
null and the handle value is null, the table is added. If both the address and
|
||||
handle are not null, the table at handle is updated with the table at address.
|
||||
If the address is null and the handle is not, the table at handle is deleted.
|
||||
|
||||
@@ -371,7 +371,7 @@ PublishTables (
|
||||
@param TableKey Reurns a key to refer to the ACPI table.
|
||||
|
||||
@return EFI_SUCCESS The table was successfully inserted.
|
||||
@return EFI_INVALID_PARAMETER Either AcpiTableBuffer is NULL, TableKey is NULL, or AcpiTableBufferSize
|
||||
@return EFI_INVALID_PARAMETER Either AcpiTableBuffer is NULL, TableKey is NULL, or AcpiTableBufferSize
|
||||
and the size field embedded in the ACPI table pointed to by AcpiTableBuffer
|
||||
are not in sync.
|
||||
@return EFI_OUT_OF_RESOURCES Insufficient resources exist to complete the request.
|
||||
@@ -427,7 +427,7 @@ InstallAcpiTable (
|
||||
);
|
||||
}
|
||||
FreePool (AcpiTableBufferConst);
|
||||
|
||||
|
||||
return Status;
|
||||
}
|
||||
/**
|
||||
@@ -500,7 +500,7 @@ ReallocateAcpiTableBuffer (
|
||||
EFI_STATUS Status;
|
||||
UINT64 CurrentData;
|
||||
|
||||
CopyMem (&TempPrivateData, AcpiSupportInstance, sizeof (EFI_ACPI_SUPPORT_INSTANCE));
|
||||
CopyMem (&TempPrivateData, AcpiSupportInstance, sizeof (EFI_ACPI_SUPPORT_INSTANCE));
|
||||
//
|
||||
// Enlarge the max table number from mEfiAcpiMaxNumTables to mEfiAcpiMaxNumTables + EFI_ACPI_MAX_NUM_TABLES
|
||||
//
|
||||
@@ -538,7 +538,7 @@ ReallocateAcpiTableBuffer (
|
||||
|
||||
Pointer = (UINT8 *) (UINTN) PageAddress;
|
||||
ZeroMem (Pointer, TotalSize);
|
||||
|
||||
|
||||
AcpiSupportInstance->Rsdt1 = (EFI_ACPI_DESCRIPTION_HEADER *) Pointer;
|
||||
Pointer += (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + NewMaxTableNumber * sizeof (UINT32));
|
||||
AcpiSupportInstance->Rsdt3 = (EFI_ACPI_DESCRIPTION_HEADER *) Pointer;
|
||||
@@ -554,12 +554,12 @@ ReallocateAcpiTableBuffer (
|
||||
CopyMem (&AcpiSupportInstance->Rsdp3->XsdtAddress, &CurrentData, sizeof (UINT64));
|
||||
|
||||
//
|
||||
// copy the original Rsdt1, Rsdt3 and Xsdt structure to new buffer
|
||||
// copy the original Rsdt1, Rsdt3 and Xsdt structure to new buffer
|
||||
//
|
||||
CopyMem (AcpiSupportInstance->Rsdt1, TempPrivateData.Rsdt1, (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + mEfiAcpiMaxNumTables * sizeof (UINT32)));
|
||||
CopyMem (AcpiSupportInstance->Rsdt3, TempPrivateData.Rsdt3, (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + mEfiAcpiMaxNumTables * sizeof (UINT32)));
|
||||
CopyMem (AcpiSupportInstance->Rsdt1, TempPrivateData.Rsdt1, (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + mEfiAcpiMaxNumTables * sizeof (UINT32)));
|
||||
CopyMem (AcpiSupportInstance->Rsdt3, TempPrivateData.Rsdt3, (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + mEfiAcpiMaxNumTables * sizeof (UINT32)));
|
||||
CopyMem (AcpiSupportInstance->Xsdt, TempPrivateData.Xsdt, (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + mEfiAcpiMaxNumTables * sizeof (UINT64)));
|
||||
|
||||
|
||||
//
|
||||
// Calculate orignal ACPI table buffer size
|
||||
//
|
||||
@@ -570,10 +570,10 @@ ReallocateAcpiTableBuffer (
|
||||
sizeof (EFI_ACPI_DESCRIPTION_HEADER) + // for ACPI 2.0/3.0 XSDT
|
||||
mEfiAcpiMaxNumTables * sizeof (UINT64);
|
||||
gBS->FreePages ((EFI_PHYSICAL_ADDRESS)(UINTN)TempPrivateData.Rsdt1, EFI_SIZE_TO_PAGES (TotalSize));
|
||||
|
||||
|
||||
//
|
||||
// Update the Max ACPI table number
|
||||
//
|
||||
//
|
||||
mEfiAcpiMaxNumTables = NewMaxTableNumber;
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
@@ -650,7 +650,7 @@ AddTableToList (
|
||||
//
|
||||
// Allocation memory type depends on the type of the table
|
||||
//
|
||||
if ((CurrentTableSignature == EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_SIGNATURE) ||
|
||||
if ((CurrentTableSignature == EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_SIGNATURE) ||
|
||||
(CurrentTableSignature == EFI_ACPI_4_0_UEFI_ACPI_DATA_TABLE_SIGNATURE)) {
|
||||
//
|
||||
// Allocate memory for the FACS. This structure must be aligned
|
||||
@@ -778,7 +778,7 @@ AddTableToList (
|
||||
|
||||
//
|
||||
// Update pointers in FADT. If tables don't exist this will put NULL pointers there.
|
||||
// Note: If the FIRMWARE_CTRL is non-zero, then X_FIRMWARE_CTRL must be zero, and
|
||||
// Note: If the FIRMWARE_CTRL is non-zero, then X_FIRMWARE_CTRL must be zero, and
|
||||
// vice-versa.
|
||||
//
|
||||
if ((UINT64)(UINTN)AcpiSupportInstance->Facs3 < BASE_4GB) {
|
||||
@@ -913,7 +913,7 @@ AddTableToList (
|
||||
//
|
||||
if (AcpiSupportInstance->Fadt3 != NULL) {
|
||||
//
|
||||
// Note: If the FIRMWARE_CTRL is non-zero, then X_FIRMWARE_CTRL must be zero, and
|
||||
// Note: If the FIRMWARE_CTRL is non-zero, then X_FIRMWARE_CTRL must be zero, and
|
||||
// vice-versa.
|
||||
//
|
||||
if ((UINT64)(UINTN)AcpiSupportInstance->Facs3 < BASE_4GB) {
|
||||
@@ -984,7 +984,7 @@ AddTableToList (
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if ((Version & EFI_ACPI_TABLE_VERSION_2_0) != 0 ||
|
||||
(Version & EFI_ACPI_TABLE_VERSION_3_0) != 0) {
|
||||
//
|
||||
@@ -1014,7 +1014,7 @@ AddTableToList (
|
||||
Checksum)
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
//
|
||||
// Checksum the table
|
||||
//
|
||||
@@ -1094,7 +1094,7 @@ AddTableToList (
|
||||
if (AcpiSupportInstance->NumberOfTableEntries3 >= mEfiAcpiMaxNumTables) {
|
||||
Status = ReallocateAcpiTableBuffer (AcpiSupportInstance);
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
}
|
||||
}
|
||||
//
|
||||
// At this time, it is assumed that RSDT and XSDT maintain parallel lists of tables.
|
||||
// If it becomes necessary to maintain separate table lists, changes will be required.
|
||||
@@ -1159,7 +1159,7 @@ AddTableToList (
|
||||
|
||||
@param Handle Table to find.
|
||||
@param TableList Table list to search
|
||||
@param Table Pointer to table found.
|
||||
@param Table Pointer to table found.
|
||||
|
||||
@return EFI_SUCCESS The function completed successfully.
|
||||
@return EFI_NOT_FOUND No table found matching the handle specified.
|
||||
@@ -1207,7 +1207,7 @@ FindTableByHandle (
|
||||
For Acpi 1.0 tables, pass in the Rsdt.
|
||||
For Acpi 2.0 tables, pass in both Rsdt and Xsdt.
|
||||
|
||||
@param Table Pointer to table found.
|
||||
@param Table Pointer to table found.
|
||||
@param NumberOfTableEntries Current number of table entries in the RSDT/XSDT
|
||||
@param Rsdt Pointer to the RSDT to remove from
|
||||
@param Xsdt Pointer to the Xsdt to remove from
|
||||
@@ -1417,11 +1417,11 @@ DeleteTable (
|
||||
//
|
||||
if (Version & EFI_ACPI_TABLE_VERSION_2_0 & Table->Version) {
|
||||
Table->Version = Table->Version &~EFI_ACPI_TABLE_VERSION_2_0;
|
||||
}
|
||||
}
|
||||
if (Version & EFI_ACPI_TABLE_VERSION_3_0 & Table->Version) {
|
||||
Table->Version = Table->Version &~EFI_ACPI_TABLE_VERSION_3_0;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Remove from Rsdt and Xsdt. We don't care about the return value
|
||||
// because it is acceptable for the table to not exist in Rsdt/Xsdt.
|
||||
@@ -1435,7 +1435,7 @@ DeleteTable (
|
||||
AcpiSupportInstance->Xsdt
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
//
|
||||
// Free the table, clean up any dependent tables and our private data pointers.
|
||||
//
|
||||
@@ -1495,7 +1495,7 @@ DeleteTable (
|
||||
Checksum)
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case EFI_ACPI_3_0_DIFFERENTIATED_SYSTEM_DESCRIPTION_TABLE_SIGNATURE:
|
||||
@@ -1520,7 +1520,7 @@ DeleteTable (
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
if ((Version & EFI_ACPI_TABLE_VERSION_2_0) != 0 ||
|
||||
(Version & EFI_ACPI_TABLE_VERSION_3_0) != 0) {
|
||||
AcpiSupportInstance->Dsdt3 = NULL;
|
||||
@@ -1733,12 +1733,12 @@ ChecksumCommonTables (
|
||||
OFFSET_OF (EFI_ACPI_DESCRIPTION_HEADER,
|
||||
Checksum)
|
||||
);
|
||||
|
||||
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
/**
|
||||
/**
|
||||
Constructor for the ACPI support protocol to initializes instance data.
|
||||
|
||||
|
||||
@param AcpiSupportInstance Instance to construct
|
||||
|
||||
@retval EFI_SUCCESS Instance initialized.
|
||||
@@ -1769,7 +1769,7 @@ AcpiSupportAcpiSupportConstructor (
|
||||
|
||||
AcpiSupportInstance->AcpiTableProtocol.InstallAcpiTable = InstallAcpiTable;
|
||||
AcpiSupportInstance->AcpiTableProtocol.UninstallAcpiTable = UninstallAcpiTable;
|
||||
|
||||
|
||||
//
|
||||
// Create RSDP table
|
||||
//
|
||||
|
@@ -1,10 +1,10 @@
|
||||
## @file
|
||||
# Acpi Support Dirver to install Framework Acpi Support Protocol.
|
||||
#
|
||||
# This driver initializes ACPI support protocol instance data structure and intstall
|
||||
# This driver initializes ACPI support protocol instance data structure and intstall
|
||||
# ACPI support protocol to provide Get, Set and Publish Table services.
|
||||
#
|
||||
# Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
#
|
||||
# This program and the accompanying materials
|
||||
# are licensed and made available under the terms and conditions
|
||||
|
@@ -4,14 +4,14 @@
|
||||
// This driver initializes ACPI support protocol instance data structure and intstall
|
||||
// ACPI support protocol to provide Get, Set and Publish Table services.
|
||||
//
|
||||
// Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// AcpiSupportDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials
|
||||
// are licensed and made available under the terms and conditions
|
||||
@@ -14,8 +14,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"ACPI Support DXE Driver"
|
||||
|
||||
|
||||
|
@@ -198,15 +198,15 @@ BdsProcessCapsules (
|
||||
then EFI_INVALID_PARAMETER is returned.
|
||||
@param VendorGuid A unique identifier for the vendor.
|
||||
@param Attributes Attributes bitmask to set for the variable.
|
||||
@param DataSize The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE,
|
||||
EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or
|
||||
EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero
|
||||
causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is
|
||||
set, then a SetVariable() call with a DataSize of zero will not cause any change to
|
||||
the variable value (the timestamp associated with the variable may be updated however
|
||||
even if no new data value is provided,see the description of the
|
||||
EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not
|
||||
be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated).
|
||||
@param DataSize The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE,
|
||||
EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or
|
||||
EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero
|
||||
causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is
|
||||
set, then a SetVariable() call with a DataSize of zero will not cause any change to
|
||||
the variable value (the timestamp associated with the variable may be updated however
|
||||
even if no new data value is provided,see the description of the
|
||||
EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not
|
||||
be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated).
|
||||
@param Data The contents for the variable.
|
||||
|
||||
@retval EFI_SUCCESS The firmware has successfully stored the variable and its data as
|
||||
@@ -218,8 +218,8 @@ BdsProcessCapsules (
|
||||
@retval EFI_DEVICE_ERROR The variable could not be retrieved due to a hardware error.
|
||||
@retval EFI_WRITE_PROTECTED The variable in question is read-only.
|
||||
@retval EFI_WRITE_PROTECTED The variable in question cannot be deleted.
|
||||
@retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS
|
||||
or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo
|
||||
@retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS
|
||||
or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo
|
||||
does NOT pass the validation check carried out by the firmware.
|
||||
|
||||
@retval EFI_NOT_FOUND The variable trying to be updated or deleted was not found.
|
||||
|
@@ -1,28 +1,28 @@
|
||||
## @file
|
||||
# BDSDxe module is core driver for BDS phase.
|
||||
#
|
||||
# When DxeCore dispatching all DXE driver, this module will produce architecture protocol
|
||||
# When DxeCore dispatching all DXE driver, this module will produce architecture protocol
|
||||
# gEfiBdsArchProtocolGuid. After DxeCore finish dispatching, DxeCore will invoke Entry
|
||||
# interface of protocol gEfiBdsArchProtocolGuid, then BDS phase is entered.
|
||||
#
|
||||
# Generally, this module take reposiblity to connect all necessary devices for platform boot,
|
||||
# Generally, this module take reposiblity to connect all necessary devices for platform boot,
|
||||
# these boot device path are hold in PlatformBdsLib library instance produced by platform.
|
||||
# For legacy boot, BDS will transfer control to legacy BIOS after legacy boot device is select.
|
||||
# For EFI boot, BDS will load boot loader file EFI\BOOT\BOOTIA32.EFI, EFI\BOOT\BOOTX64.EFI,
|
||||
# For EFI boot, BDS will load boot loader file EFI\BOOT\BOOTIA32.EFI, EFI\BOOT\BOOTX64.EFI,
|
||||
# EFI\BOOT\BOOTIA64.EFI file from selected boot device and transfer control to boot loader.
|
||||
#
|
||||
# BDSDxe also maintain the UI for "Boot Manager, Boot Maintaince Manager, Device Manager" which
|
||||
# is used for user to configure boot option or maintain hardware device.
|
||||
#
|
||||
#
|
||||
# Copyright (c) 2008 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
# 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
|
||||
# http://opensource.org/licenses/bsd-license.php
|
||||
#
|
||||
#
|
||||
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#
|
||||
#
|
||||
##
|
||||
|
||||
[Defines]
|
||||
@@ -31,7 +31,7 @@
|
||||
MODULE_UNI_FILE = BdsDxe.uni
|
||||
FILE_GUID = FC5C7020-1A48-4198-9BE2-EAD5ABC8CF2F
|
||||
MODULE_TYPE = DXE_DRIVER
|
||||
VERSION_STRING = 1.0
|
||||
VERSION_STRING = 1.0
|
||||
ENTRY_POINT = BdsInitialize
|
||||
|
||||
#
|
||||
@@ -91,7 +91,7 @@
|
||||
MdeModulePkg/MdeModulePkg.dec
|
||||
IntelFrameworkPkg/IntelFrameworkPkg.dec
|
||||
IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec
|
||||
|
||||
|
||||
[LibraryClasses]
|
||||
DevicePathLib
|
||||
BaseLib
|
||||
@@ -112,7 +112,7 @@
|
||||
CapsuleLib
|
||||
PcdLib
|
||||
UefiHiiServicesLib
|
||||
|
||||
|
||||
[Guids]
|
||||
## SOMETIMES_PRODUCES ## Variable:L"BootXXXX" # Boot option variable
|
||||
## SOMETIMES_PRODUCES ## Variable:L"DriverXXXX" # Driver load option.
|
||||
@@ -170,7 +170,7 @@
|
||||
gEfiGraphicsOutputProtocolGuid ## SOMETIMES_CONSUMES
|
||||
## CONSUMES
|
||||
## NOTIFY
|
||||
gEfiSimpleTextInputExProtocolGuid
|
||||
gEfiSimpleTextInputExProtocolGuid
|
||||
gEfiHiiConfigAccessProtocolGuid ## SOMETIMES_PRODUCES
|
||||
gEfiFormBrowser2ProtocolGuid ## CONSUMES
|
||||
gEfiSerialIoProtocolGuid ## SOMETIMES_CONSUMES
|
||||
@@ -201,7 +201,7 @@
|
||||
## CONSUMES
|
||||
## PRODUCES
|
||||
gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdBootState
|
||||
gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVendor ## CONSUMES
|
||||
gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVendor ## CONSUMES
|
||||
gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareRevision ## CONSUMES
|
||||
gEfiMdeModulePkgTokenSpaceGuid.PcdVideoHorizontalResolution ## PRODUCES
|
||||
gEfiMdeModulePkgTokenSpaceGuid.PcdVideoVerticalResolution ## PRODUCES
|
||||
@@ -220,7 +220,7 @@
|
||||
TRUE
|
||||
|
||||
#
|
||||
# [BootMode]
|
||||
# [BootMode]
|
||||
# FLASH_UPDATE ## SOMETIMES_CONSUMES # Update Capsule Image
|
||||
#
|
||||
|
||||
|
@@ -4,23 +4,23 @@
|
||||
// When DxeCore dispatching all DXE driver, this module will produce architecture protocol
|
||||
// gEfiBdsArchProtocolGuid. After DxeCore finish dispatching, DxeCore will invoke Entry
|
||||
// interface of protocol gEfiBdsArchProtocolGuid, then BDS phase is entered.
|
||||
//
|
||||
//
|
||||
// Generally, this module take reposiblity to connect all necessary devices for platform boot,
|
||||
// these boot device path are hold in PlatformBdsLib library instance produced by platform.
|
||||
// For legacy boot, BDS will transfer control to legacy BIOS after legacy boot device is select.
|
||||
// For EFI boot, BDS will load boot loader file EFI\BOOT\BOOTIA32.EFI, EFI\BOOT\BOOTX64.EFI,
|
||||
// EFI\BOOT\BOOTIA64.EFI file from selected boot device and transfer control to boot loader.
|
||||
//
|
||||
//
|
||||
// BDSDxe also maintain the UI for "Boot Manager, Boot Maintaince Manager, Device Manager" which
|
||||
// is used for user to configure boot option or maintain hardware device.
|
||||
//
|
||||
// Copyright (c) 2008 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2008 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// BdsDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials
|
||||
// are licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -13,8 +13,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"Boot Device Selection Core DXE Driver"
|
||||
|
||||
|
||||
|
@@ -179,7 +179,7 @@ BdsBootDeviceSelect (
|
||||
BdsLibBuildOptionFromVar (&BootLists, L"BootOrder");
|
||||
|
||||
//
|
||||
// When we didn't have chance to build boot option variables in the first
|
||||
// When we didn't have chance to build boot option variables in the first
|
||||
// full configuration boot (e.g.: Reset in the first page or in Device Manager),
|
||||
// we have no boot options in the following mini configuration boot.
|
||||
// Give the last chance to enumerate the boot options.
|
||||
@@ -260,7 +260,7 @@ BdsBootDeviceSelect (
|
||||
// Restore to original mode before launching boot option.
|
||||
//
|
||||
BdsSetConsoleMode (FALSE);
|
||||
|
||||
|
||||
//
|
||||
// All the driver options should have been processed since
|
||||
// now boot will be performed.
|
||||
@@ -325,10 +325,10 @@ BdsBootDeviceSelect (
|
||||
|
||||
/**
|
||||
|
||||
Validate input console variable data.
|
||||
Validate input console variable data.
|
||||
|
||||
If found the device path is not a valid device path, remove the variable.
|
||||
|
||||
|
||||
@param VariableName Input console variable name.
|
||||
|
||||
**/
|
||||
@@ -346,7 +346,7 @@ BdsFormalizeConsoleVariable (
|
||||
&gEfiGlobalVariableGuid,
|
||||
&VariableSize
|
||||
);
|
||||
if ((DevicePath != NULL) && !IsDevicePathValid (DevicePath, VariableSize)) {
|
||||
if ((DevicePath != NULL) && !IsDevicePathValid (DevicePath, VariableSize)) {
|
||||
Status = gRT->SetVariable (
|
||||
VariableName,
|
||||
&gEfiGlobalVariableGuid,
|
||||
@@ -363,15 +363,15 @@ BdsFormalizeConsoleVariable (
|
||||
|
||||
/**
|
||||
|
||||
Formalize Bds global variables.
|
||||
Formalize Bds global variables.
|
||||
|
||||
1. For ConIn/ConOut/ConErr, if found the device path is not a valid device path, remove the variable.
|
||||
2. For OsIndicationsSupported, Create a BS/RT/UINT64 variable to report caps
|
||||
2. For OsIndicationsSupported, Create a BS/RT/UINT64 variable to report caps
|
||||
3. Delete OsIndications variable if it is not NV/BS/RT UINT64
|
||||
Item 3 is used to solve case when OS corrupts OsIndications. Here simply delete this NV variable.
|
||||
|
||||
|
||||
**/
|
||||
VOID
|
||||
VOID
|
||||
BdsFormalizeEfiGlobalVariable (
|
||||
VOID
|
||||
)
|
||||
@@ -381,7 +381,7 @@ BdsFormalizeEfiGlobalVariable (
|
||||
UINT64 OsIndication;
|
||||
UINTN DataSize;
|
||||
UINT32 Attributes;
|
||||
|
||||
|
||||
//
|
||||
// Validate Console variable.
|
||||
//
|
||||
@@ -604,15 +604,15 @@ BdsEntry (
|
||||
then EFI_INVALID_PARAMETER is returned.
|
||||
@param VendorGuid A unique identifier for the vendor.
|
||||
@param Attributes Attributes bitmask to set for the variable.
|
||||
@param DataSize The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE,
|
||||
EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or
|
||||
EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero
|
||||
causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is
|
||||
set, then a SetVariable() call with a DataSize of zero will not cause any change to
|
||||
the variable value (the timestamp associated with the variable may be updated however
|
||||
even if no new data value is provided,see the description of the
|
||||
EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not
|
||||
be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated).
|
||||
@param DataSize The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE,
|
||||
EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or
|
||||
EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero
|
||||
causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is
|
||||
set, then a SetVariable() call with a DataSize of zero will not cause any change to
|
||||
the variable value (the timestamp associated with the variable may be updated however
|
||||
even if no new data value is provided,see the description of the
|
||||
EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not
|
||||
be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated).
|
||||
@param Data The contents for the variable.
|
||||
|
||||
@retval EFI_SUCCESS The firmware has successfully stored the variable and its data as
|
||||
@@ -624,8 +624,8 @@ BdsEntry (
|
||||
@retval EFI_DEVICE_ERROR The variable could not be retrieved due to a hardware error.
|
||||
@retval EFI_WRITE_PROTECTED The variable in question is read-only.
|
||||
@retval EFI_WRITE_PROTECTED The variable in question cannot be deleted.
|
||||
@retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS
|
||||
or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo
|
||||
@retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS
|
||||
or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo
|
||||
does NOT pass the validation check carried out by the firmware.
|
||||
|
||||
@retval EFI_NOT_FOUND The variable trying to be updated or deleted was not found.
|
||||
|
@@ -3,7 +3,7 @@
|
||||
and manage the legacy boot option, all legacy boot option is getting from
|
||||
the legacy BBS table.
|
||||
|
||||
Copyright (c) 2004 - 2015, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -53,9 +53,9 @@ OrderLegacyBootOption4SameType (
|
||||
UINTN BootOrderSize;
|
||||
UINTN Index;
|
||||
UINTN StartPosition;
|
||||
|
||||
|
||||
BDS_COMMON_OPTION *BootOption;
|
||||
|
||||
|
||||
CHAR16 OptionName[sizeof ("Boot####")];
|
||||
UINT16 *BbsIndexArray;
|
||||
UINT16 *DeviceTypeArray;
|
||||
@@ -82,12 +82,12 @@ OrderLegacyBootOption4SameType (
|
||||
ASSERT (*DisBootOption != NULL);
|
||||
|
||||
for (Index = 0; Index < BootOrderSize / sizeof (UINT16); Index++) {
|
||||
|
||||
|
||||
UnicodeSPrint (OptionName, sizeof (OptionName), L"Boot%04x", BootOrder[Index]);
|
||||
InitializeListHead (&List);
|
||||
BootOption = BdsLibVariableToOption (&List, OptionName);
|
||||
ASSERT (BootOption != NULL);
|
||||
|
||||
|
||||
if ((DevicePathType (BootOption->DevicePath) == BBS_DEVICE_PATH) &&
|
||||
(DevicePathSubType (BootOption->DevicePath) == BBS_BBS_DP)) {
|
||||
//
|
||||
@@ -119,7 +119,7 @@ OrderLegacyBootOption4SameType (
|
||||
if (BbsIndexArray[Index] == (DevOrder[DevOrderCount] & 0xFF)) {
|
||||
StartPosition = MIN (StartPosition, Index);
|
||||
NewBootOption[DevOrderCount] = BootOrder[Index];
|
||||
|
||||
|
||||
if ((DevOrder[DevOrderCount] & 0xFF00) == 0xFF00) {
|
||||
(*DisBootOption)[*DisBootOptionCount] = BootOrder[Index];
|
||||
(*DisBootOptionCount)++;
|
||||
@@ -157,7 +157,7 @@ OrderLegacyBootOption4SameType (
|
||||
/**
|
||||
Group the legacy boot options in the BootOption.
|
||||
|
||||
The routine assumes the boot options in the beginning that covers all the device
|
||||
The routine assumes the boot options in the beginning that covers all the device
|
||||
types are ordered properly and re-position the following boot options just after
|
||||
the corresponding boot options with the same device type.
|
||||
For example:
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
declares interface functions
|
||||
|
||||
Copyright (c) 2004 - 2012, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -39,7 +39,7 @@ BdsBuildLegacyDevNameString (
|
||||
/**
|
||||
Group the legacy boot options in the BootOption.
|
||||
|
||||
The routine assumes the boot options in the beginning that covers all the device
|
||||
The routine assumes the boot options in the beginning that covers all the device
|
||||
types are ordered properly and re-position the following boot options just after
|
||||
the corresponding boot options with the same device type.
|
||||
For example:
|
||||
|
@@ -1,16 +1,16 @@
|
||||
///** @file
|
||||
//
|
||||
//
|
||||
// Boot Maintenance Utility Formset
|
||||
//
|
||||
// Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
//
|
||||
//**/
|
||||
|
||||
#include "FormGuid.h"
|
||||
@@ -114,9 +114,9 @@ formset
|
||||
|
||||
subtitle text = STRING_TOKEN(STR_NULL_STRING);
|
||||
//
|
||||
// We will add "Select Legacy Boot Floppy Drive" and "Select Legacy Boot Hard Drive"
|
||||
// here dynamically
|
||||
//
|
||||
// We will add "Select Legacy Boot Floppy Drive" and "Select Legacy Boot Hard Drive"
|
||||
// here dynamically
|
||||
//
|
||||
label FORM_BOOT_LEGACY_DEVICE_ID;
|
||||
label LABEL_END;
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Utility routines used by boot maintenance modules.
|
||||
|
||||
Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -146,7 +146,7 @@ EfiLibGetVariable (
|
||||
|
||||
@param VarName A Null-terminated Unicode string that is
|
||||
the name of the vendor's variable.
|
||||
|
||||
|
||||
@param VarGuid A unique identifier for the vendor.
|
||||
|
||||
@retval EFI_SUCCESS The variable was found and removed
|
||||
@@ -361,7 +361,7 @@ EfiReallocatePool (
|
||||
}
|
||||
|
||||
/**
|
||||
Get a string from the Data Hub record based on
|
||||
Get a string from the Data Hub record based on
|
||||
a device path.
|
||||
|
||||
@param DevPath The device Path.
|
||||
|
@@ -1,16 +1,16 @@
|
||||
///** @file
|
||||
//
|
||||
//
|
||||
// String definitions for Boot Maintenance Utility.
|
||||
//
|
||||
// Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
//
|
||||
//**/
|
||||
|
||||
/=#
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
The functions for Boot Maintainence Main menu.
|
||||
|
||||
Copyright (c) 2004 - 2015, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -43,7 +43,7 @@ HII_VENDOR_DEVICE_PATH mBmmHiiVendorDevicePath = {
|
||||
{
|
||||
END_DEVICE_PATH_TYPE,
|
||||
END_ENTIRE_DEVICE_PATH_SUBTYPE,
|
||||
{
|
||||
{
|
||||
(UINT8) (END_DEVICE_PATH_LENGTH),
|
||||
(UINT8) ((END_DEVICE_PATH_LENGTH) >> 8)
|
||||
}
|
||||
@@ -65,7 +65,7 @@ HII_VENDOR_DEVICE_PATH mFeHiiVendorDevicePath = {
|
||||
{
|
||||
END_DEVICE_PATH_TYPE,
|
||||
END_ENTIRE_DEVICE_PATH_SUBTYPE,
|
||||
{
|
||||
{
|
||||
(UINT8) (END_DEVICE_PATH_LENGTH),
|
||||
(UINT8) ((END_DEVICE_PATH_LENGTH) >> 8)
|
||||
}
|
||||
@@ -143,8 +143,8 @@ InitializeBmmConfig (
|
||||
|
||||
//
|
||||
// Initialize data which located in Console Options Menu
|
||||
//
|
||||
GetConsoleOutMode (CallbackData);
|
||||
//
|
||||
GetConsoleOutMode (CallbackData);
|
||||
GetConsoleInCheck (CallbackData);
|
||||
GetConsoleOutCheck (CallbackData);
|
||||
GetConsoleErrCheck (CallbackData);
|
||||
@@ -314,7 +314,7 @@ BootMaintExtractConfig (
|
||||
|
||||
@param[in] This Points to the EFI_HII_CONFIG_ACCESS_PROTOCOL.
|
||||
@param[in] Configuration A null-terminated Unicode string in
|
||||
<ConfigString> format.
|
||||
<ConfigString> format.
|
||||
@param[out] Progress A pointer to a string filled in with the
|
||||
offset of the most recent '&' before the
|
||||
first failing name / value pair (or the
|
||||
@@ -324,7 +324,7 @@ BootMaintExtractConfig (
|
||||
successful.
|
||||
|
||||
@retval EFI_SUCCESS The results have been distributed or are
|
||||
awaiting distribution.
|
||||
awaiting distribution.
|
||||
@retval EFI_OUT_OF_RESOURCES Not enough memory to store the
|
||||
parts of the results that must be
|
||||
stored awaiting possible future
|
||||
@@ -352,9 +352,9 @@ BootMaintRouteConfig (
|
||||
BM_TERMINAL_CONTEXT *NewTerminalContext;
|
||||
BM_MENU_ENTRY *NewMenuEntry;
|
||||
BM_LOAD_CONTEXT *NewLoadContext;
|
||||
UINT16 Index;
|
||||
UINT16 Index;
|
||||
BOOLEAN TerminalAttChange;
|
||||
BMM_CALLBACK_DATA *Private;
|
||||
BMM_CALLBACK_DATA *Private;
|
||||
|
||||
if (Progress == NULL) {
|
||||
return EFI_INVALID_PARAMETER;
|
||||
@@ -374,8 +374,8 @@ BootMaintRouteConfig (
|
||||
}
|
||||
|
||||
Status = gBS->LocateProtocol (
|
||||
&gEfiHiiConfigRoutingProtocolGuid,
|
||||
NULL,
|
||||
&gEfiHiiConfigRoutingProtocolGuid,
|
||||
NULL,
|
||||
(VOID**) &ConfigRouting
|
||||
);
|
||||
if (EFI_ERROR (Status)) {
|
||||
@@ -401,7 +401,7 @@ BootMaintRouteConfig (
|
||||
);
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
//
|
||||
// Compare new and old BMM configuration data and only do action for modified item to
|
||||
// Compare new and old BMM configuration data and only do action for modified item to
|
||||
// avoid setting unnecessary non-volatile variable
|
||||
//
|
||||
|
||||
@@ -429,27 +429,27 @@ BootMaintRouteConfig (
|
||||
}
|
||||
|
||||
//
|
||||
// Change for "delete boot option" page need update NewBmmData->BootOptionOrder, so process
|
||||
// Change for "delete boot option" page need update NewBmmData->BootOptionOrder, so process
|
||||
// NewBmmData->BootOptionOrder before NewBmmData->BootOptionDel
|
||||
//
|
||||
if (CompareMem (NewBmmData->BootOptionOrder, OldBmmData->BootOptionOrder, sizeof (NewBmmData->BootOptionOrder)) != 0) {
|
||||
if (CompareMem (NewBmmData->BootOptionOrder, OldBmmData->BootOptionOrder, sizeof (NewBmmData->BootOptionOrder)) != 0) {
|
||||
Status = Var_UpdateBootOrder (Private);
|
||||
}
|
||||
|
||||
//
|
||||
// Change for "delete driver option" page need update NewBmmData->DriverOptionOrder, so process
|
||||
// Change for "delete driver option" page need update NewBmmData->DriverOptionOrder, so process
|
||||
// NewBmmData->DriverOptionOrder before NewBmmData->DriverOptionDel
|
||||
//
|
||||
if (CompareMem (NewBmmData->DriverOptionOrder, OldBmmData->DriverOptionOrder, sizeof (NewBmmData->DriverOptionOrder)) != 0) {
|
||||
if (CompareMem (NewBmmData->DriverOptionOrder, OldBmmData->DriverOptionOrder, sizeof (NewBmmData->DriverOptionOrder)) != 0) {
|
||||
Status = Var_UpdateDriverOrder (Private);
|
||||
}
|
||||
|
||||
//
|
||||
// Check data which located in Boot Options Menu and save the settings if need
|
||||
//
|
||||
if (CompareMem (NewBmmData->BootOptionDel, OldBmmData->BootOptionDel, sizeof (NewBmmData->BootOptionDel)) != 0) {
|
||||
for (Index = 0;
|
||||
((Index < BootOptionMenu.MenuNumber) && (Index < (sizeof (NewBmmData->BootOptionDel) / sizeof (NewBmmData->BootOptionDel[0]))));
|
||||
if (CompareMem (NewBmmData->BootOptionDel, OldBmmData->BootOptionDel, sizeof (NewBmmData->BootOptionDel)) != 0) {
|
||||
for (Index = 0;
|
||||
((Index < BootOptionMenu.MenuNumber) && (Index < (sizeof (NewBmmData->BootOptionDel) / sizeof (NewBmmData->BootOptionDel[0]))));
|
||||
Index ++) {
|
||||
NewMenuEntry = BOpt_GetMenuEntry (&BootOptionMenu, Index);
|
||||
NewLoadContext = (BM_LOAD_CONTEXT *) NewMenuEntry->VariableContext;
|
||||
@@ -464,9 +464,9 @@ BootMaintRouteConfig (
|
||||
//
|
||||
// Check data which located in Driver Options Menu and save the settings if need
|
||||
//
|
||||
if (CompareMem (NewBmmData->DriverOptionDel, OldBmmData->DriverOptionDel, sizeof (NewBmmData->DriverOptionDel)) != 0) {
|
||||
for (Index = 0;
|
||||
((Index < DriverOptionMenu.MenuNumber) && (Index < (sizeof (NewBmmData->DriverOptionDel) / sizeof (NewBmmData->DriverOptionDel[0]))));
|
||||
if (CompareMem (NewBmmData->DriverOptionDel, OldBmmData->DriverOptionDel, sizeof (NewBmmData->DriverOptionDel)) != 0) {
|
||||
for (Index = 0;
|
||||
((Index < DriverOptionMenu.MenuNumber) && (Index < (sizeof (NewBmmData->DriverOptionDel) / sizeof (NewBmmData->DriverOptionDel[0]))));
|
||||
Index++) {
|
||||
NewMenuEntry = BOpt_GetMenuEntry (&DriverOptionMenu, Index);
|
||||
NewLoadContext = (BM_LOAD_CONTEXT *) NewMenuEntry->VariableContext;
|
||||
@@ -490,14 +490,14 @@ BootMaintRouteConfig (
|
||||
//
|
||||
// Bugbug: code not exit in UiApp but in IntelFrameworkModulePkg, need do more check.
|
||||
//
|
||||
Private->BmmOldFakeNVData.BootTimeOut = NewBmmData->BootTimeOut;
|
||||
Private->BmmOldFakeNVData.BootTimeOut = NewBmmData->BootTimeOut;
|
||||
}
|
||||
|
||||
if (CompareMem (&NewBmmData->BootNext, &OldBmmData->BootNext, sizeof (NewBmmData->BootNext)) != 0) {
|
||||
Status = Var_UpdateBootNext (Private);
|
||||
}
|
||||
|
||||
if (CompareMem (&NewBmmData->ConsoleOutMode, &OldBmmData->ConsoleOutMode, sizeof (NewBmmData->ConsoleOutMode)) != 0) {
|
||||
if (CompareMem (&NewBmmData->ConsoleOutMode, &OldBmmData->ConsoleOutMode, sizeof (NewBmmData->ConsoleOutMode)) != 0) {
|
||||
Var_UpdateConMode (Private);
|
||||
}
|
||||
|
||||
@@ -570,7 +570,7 @@ BootMaintRouteConfig (
|
||||
Var_UpdateConsoleOutOption ();
|
||||
}
|
||||
|
||||
if (CompareMem (NewBmmData->ConsoleErrCheck, OldBmmData->ConsoleErrCheck, sizeof (NewBmmData->ConsoleErrCheck)) != 0) {
|
||||
if (CompareMem (NewBmmData->ConsoleErrCheck, OldBmmData->ConsoleErrCheck, sizeof (NewBmmData->ConsoleErrCheck)) != 0) {
|
||||
for (Index = 0; Index < ConsoleErrMenu.MenuNumber; Index++) {
|
||||
NewMenuEntry = BOpt_GetMenuEntry (&ConsoleErrMenu, Index);
|
||||
NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext;
|
||||
@@ -600,7 +600,7 @@ InitializeLegacyBootOption (
|
||||
{
|
||||
RefreshUpdateData ();
|
||||
mStartLabel->Number = FORM_BOOT_LEGACY_DEVICE_ID;
|
||||
|
||||
|
||||
//
|
||||
// If LegacyBios Protocol is installed, add 3 tags about legacy boot option
|
||||
// in BootOption form: legacy FD/HD/CD/NET/BEV
|
||||
@@ -649,7 +649,7 @@ InitializeLegacyBootOption (
|
||||
EFI_IFR_FLAG_CALLBACK,
|
||||
FORM_SET_BEV_ORDER_ID
|
||||
);
|
||||
|
||||
|
||||
HiiUpdateForm (
|
||||
mBmmCallbackInfo->BmmHiiHandle,
|
||||
&gBootMaintFormSetGuid,
|
||||
@@ -657,7 +657,7 @@ InitializeLegacyBootOption (
|
||||
mStartOpCodeHandle, // Label FORM_BOOT_LEGACY_DEVICE_ID
|
||||
mEndOpCodeHandle // LABEL_END
|
||||
);
|
||||
|
||||
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
@@ -700,7 +700,7 @@ BootMaintCallback (
|
||||
UINTN Pos;
|
||||
UINTN Bit;
|
||||
UINT16 NewValuePos;
|
||||
UINT16 Index3;
|
||||
UINT16 Index3;
|
||||
UINT16 Index2;
|
||||
UINT16 Index;
|
||||
UINT8 *OldLegacyDev;
|
||||
@@ -717,17 +717,17 @@ BootMaintCallback (
|
||||
if (!EFI_ERROR (Status)) {
|
||||
InitializeLegacyBootOption ();
|
||||
}
|
||||
|
||||
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
if (Action != EFI_BROWSER_ACTION_CHANGING && Action != EFI_BROWSER_ACTION_CHANGED) {
|
||||
if (Action != EFI_BROWSER_ACTION_CHANGING && Action != EFI_BROWSER_ACTION_CHANGED) {
|
||||
//
|
||||
// All other action return unsupported.
|
||||
//
|
||||
return EFI_UNSUPPORTED;
|
||||
}
|
||||
|
||||
|
||||
Status = EFI_SUCCESS;
|
||||
OldValue = 0;
|
||||
NewValue = 0;
|
||||
@@ -747,7 +747,7 @@ BootMaintCallback (
|
||||
if (Value == NULL) {
|
||||
return EFI_INVALID_PARAMETER;
|
||||
}
|
||||
|
||||
|
||||
UpdatePageId (Private, QuestionId);
|
||||
|
||||
if (QuestionId < FILE_OPTION_OFFSET) {
|
||||
@@ -1021,7 +1021,7 @@ BootMaintCallback (
|
||||
//
|
||||
DiscardChangeHandler (Private, CurrentFakeNVMap);
|
||||
*ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD_EXIT;
|
||||
break;
|
||||
break;
|
||||
|
||||
case FORM_RESET:
|
||||
gRT->ResetSystem (EfiResetCold, EFI_SUCCESS, 0, NULL);
|
||||
@@ -1121,7 +1121,7 @@ InitializeBM (
|
||||
UINT8 *Data;
|
||||
|
||||
Status = EFI_SUCCESS;
|
||||
BmmCallbackInfo = mBmmCallbackInfo;
|
||||
BmmCallbackInfo = mBmmCallbackInfo;
|
||||
|
||||
BmmCallbackInfo->BmmPreviousPageId = FORM_MAIN_ID;
|
||||
BmmCallbackInfo->BmmCurrentPageId = FORM_MAIN_ID;
|
||||
@@ -1131,17 +1131,17 @@ InitializeBM (
|
||||
//
|
||||
// Reinstall String packages to include more new strings.
|
||||
//
|
||||
|
||||
|
||||
//
|
||||
// String package size
|
||||
//
|
||||
Length = ReadUnaligned32 ((UINT32 *) BdsDxeStrings) - sizeof (UINT32);
|
||||
|
||||
//
|
||||
// Add the length of the Package List Header and the terminating Package Header
|
||||
// Add the length of the Package List Header and the terminating Package Header
|
||||
//
|
||||
Length += sizeof (EFI_HII_PACKAGE_LIST_HEADER) + sizeof (EFI_HII_PACKAGE_HEADER);
|
||||
|
||||
|
||||
//
|
||||
// Allocate the storage for the entire Package List
|
||||
//
|
||||
@@ -1160,12 +1160,12 @@ InitializeBM (
|
||||
PackageListHeader->PackageLength = Length;
|
||||
|
||||
//
|
||||
// Copy String Data into Package list.
|
||||
// Copy String Data into Package list.
|
||||
//
|
||||
Data = (UINT8 *)(PackageListHeader + 1);
|
||||
Length = ReadUnaligned32 ((UINT32 *) BdsDxeStrings) - sizeof (UINT32);
|
||||
CopyMem (Data, (UINT8 *) BdsDxeStrings + sizeof (UINT32), Length);
|
||||
|
||||
|
||||
//
|
||||
// Add End type HII package.
|
||||
//
|
||||
@@ -1178,13 +1178,13 @@ InitializeBM (
|
||||
//
|
||||
CopyGuid (&PackageListHeader->PackageListGuid, &gBootMaintFormSetGuid);
|
||||
Status = gHiiDatabase->UpdatePackageList (gHiiDatabase, BmmCallbackInfo->BmmHiiHandle, PackageListHeader);
|
||||
|
||||
|
||||
//
|
||||
// Update String package for FE.
|
||||
//
|
||||
CopyGuid (&PackageListHeader->PackageListGuid, &gFileExploreFormSetGuid);
|
||||
Status = gHiiDatabase->UpdatePackageList (gHiiDatabase, BmmCallbackInfo->FeHiiHandle, PackageListHeader);
|
||||
|
||||
|
||||
FreePool (PackageListHeader);
|
||||
|
||||
//
|
||||
@@ -1226,7 +1226,7 @@ InitializeBM (
|
||||
CreateMenuStringToken (BmmCallbackInfo, BmmCallbackInfo->BmmHiiHandle, &DriverOptionMenu);
|
||||
CreateMenuStringToken (BmmCallbackInfo, BmmCallbackInfo->BmmHiiHandle, &TerminalMenu);
|
||||
CreateMenuStringToken (BmmCallbackInfo, BmmCallbackInfo->BmmHiiHandle, &DriverMenu);
|
||||
|
||||
|
||||
InitializeBmmConfig (BmmCallbackInfo);
|
||||
|
||||
//
|
||||
@@ -1238,7 +1238,7 @@ InitializeBM (
|
||||
// Clean up.
|
||||
//
|
||||
CleanUpStringDepository ();
|
||||
|
||||
|
||||
FreeAllMenu ();
|
||||
|
||||
Exit:
|
||||
@@ -1544,7 +1544,7 @@ InitBMPackage (
|
||||
BMM_CALLBACK_DATA *BmmCallbackInfo;
|
||||
EFI_STATUS Status;
|
||||
UINT8 *Ptr;
|
||||
|
||||
|
||||
//
|
||||
// Create CallbackData structures for Driver Callback
|
||||
//
|
||||
@@ -1552,7 +1552,7 @@ InitBMPackage (
|
||||
if (BmmCallbackInfo == NULL) {
|
||||
return EFI_OUT_OF_RESOURCES;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Create LoadOption in BmmCallbackInfo for Driver Callback
|
||||
//
|
||||
@@ -1633,10 +1633,10 @@ InitBMPackage (
|
||||
NULL
|
||||
);
|
||||
ASSERT (BmmCallbackInfo->FeHiiHandle != NULL);
|
||||
|
||||
|
||||
mBmmCallbackInfo = BmmCallbackInfo;
|
||||
|
||||
return EFI_SUCCESS;
|
||||
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1683,8 +1683,8 @@ FreeBMPackage (
|
||||
FreePool (BmmCallbackInfo->LoadContext);
|
||||
FreePool (BmmCallbackInfo);
|
||||
|
||||
mBmmCallbackInfo = NULL;
|
||||
|
||||
mBmmCallbackInfo = NULL;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Header file for boot maintenance module.
|
||||
|
||||
Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -473,7 +473,7 @@ BOpt_GetBootOptions (
|
||||
|
||||
@return EFI_SUCESS The functin completes successfully.
|
||||
@retval EFI_OUT_OF_RESOURCES Not enough memory to compete the operation.
|
||||
|
||||
|
||||
|
||||
**/
|
||||
EFI_STATUS
|
||||
@@ -717,11 +717,11 @@ ChangeVariableDevicePath (
|
||||
|
||||
/**
|
||||
Update the multi-instance device path of Terminal Device based on
|
||||
the global TerminalMenu. If ChangeTernimal is TRUE, the terminal
|
||||
the global TerminalMenu. If ChangeTernimal is TRUE, the terminal
|
||||
device path in the Terminal Device in TerminalMenu is also updated.
|
||||
|
||||
@param DevicePath The multi-instance device path.
|
||||
@param ChangeTerminal TRUE, then device path in the Terminal Device
|
||||
@param ChangeTerminal TRUE, then device path in the Terminal Device
|
||||
in TerminalMenu is also updated; FALSE, no update.
|
||||
|
||||
@return EFI_SUCCESS The function completes successfully.
|
||||
@@ -737,8 +737,8 @@ ChangeTerminalDevicePath (
|
||||
// Variable operation by menu selection
|
||||
//
|
||||
/**
|
||||
This function create a currently loaded Boot Option from
|
||||
the BMM. It then appends this Boot Option to the end of
|
||||
This function create a currently loaded Boot Option from
|
||||
the BMM. It then appends this Boot Option to the end of
|
||||
the "BootOrder" list. It also append this Boot Opotion to the end
|
||||
of BootOptionMenu.
|
||||
|
||||
@@ -760,9 +760,9 @@ Var_UpdateBootOption (
|
||||
After deleting this boot option, call Var_ChangeBootOrder to
|
||||
make sure BootOrder is in valid state.
|
||||
|
||||
@retval EFI_SUCCESS If all boot load option EFI Variables corresponding to
|
||||
@retval EFI_SUCCESS If all boot load option EFI Variables corresponding to
|
||||
BM_LOAD_CONTEXT marked for deletion is deleted
|
||||
@return Others If failed to update the "BootOrder" variable after deletion.
|
||||
@return Others If failed to update the "BootOrder" variable after deletion.
|
||||
|
||||
**/
|
||||
EFI_STATUS
|
||||
@@ -786,8 +786,8 @@ Var_ChangeBootOrder (
|
||||
);
|
||||
|
||||
/**
|
||||
This function create a currently loaded Drive Option from
|
||||
the BMM. It then appends this Driver Option to the end of
|
||||
This function create a currently loaded Drive Option from
|
||||
the BMM. It then appends this Driver Option to the end of
|
||||
the "DriverOrder" list. It append this Driver Opotion to the end
|
||||
of DriverOptionMenu.
|
||||
|
||||
@@ -876,7 +876,7 @@ Var_UpdateErrorOutOption (
|
||||
);
|
||||
|
||||
/**
|
||||
Update the device path of "ConOut", "ConIn" and "ErrOut" based on the new BaudRate, Data Bits,
|
||||
Update the device path of "ConOut", "ConIn" and "ErrOut" based on the new BaudRate, Data Bits,
|
||||
parity and stop Bits set.
|
||||
|
||||
**/
|
||||
@@ -886,7 +886,7 @@ Var_UpdateAllConsoleOption (
|
||||
);
|
||||
|
||||
/**
|
||||
This function update the "BootNext" EFI Variable. If there is no "BootNex" specified in BMM,
|
||||
This function update the "BootNext" EFI Variable. If there is no "BootNex" specified in BMM,
|
||||
this EFI Variable is deleted.
|
||||
It also update the BMM context data specified the "BootNext" value.
|
||||
|
||||
@@ -902,7 +902,7 @@ Var_UpdateBootNext (
|
||||
);
|
||||
|
||||
/**
|
||||
This function update the "BootOrder" EFI Variable based on BMM Formset's NV map. It then refresh
|
||||
This function update the "BootOrder" EFI Variable based on BMM Formset's NV map. It then refresh
|
||||
BootOptionMenu with the new "BootOrder" list.
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
@@ -980,7 +980,7 @@ RefreshUpdateData (
|
||||
|
||||
/**
|
||||
Clean up the dynamic opcode at label and form specified by
|
||||
both LabelId.
|
||||
both LabelId.
|
||||
|
||||
@param LabelId It is both the Form ID and Label ID for
|
||||
opcode deletion.
|
||||
@@ -1177,7 +1177,7 @@ EfiReallocatePool (
|
||||
|
||||
@param VarName A Null-terminated Unicode string that is
|
||||
the name of the vendor's variable.
|
||||
|
||||
|
||||
@param VarGuid A unique identifier for the vendor.
|
||||
|
||||
@retval EFI_SUCCESS The variable was found and removed
|
||||
@@ -1242,7 +1242,7 @@ CreateMenuStringToken (
|
||||
);
|
||||
|
||||
/**
|
||||
Get a string from the Data Hub record based on
|
||||
Get a string from the Data Hub record based on
|
||||
a device path.
|
||||
|
||||
@param DevPath The device Path.
|
||||
@@ -1450,7 +1450,7 @@ FileExplorerCallback (
|
||||
|
||||
@param[in] This Points to the EFI_HII_CONFIG_ACCESS_PROTOCOL.
|
||||
@param[in] Configuration A null-terminated Unicode string in
|
||||
<ConfigString> format.
|
||||
<ConfigString> format.
|
||||
@param[out] Progress A pointer to a string filled in with the
|
||||
offset of the most recent '&' before the
|
||||
first failing name / value pair (or the
|
||||
@@ -1460,7 +1460,7 @@ FileExplorerCallback (
|
||||
successful.
|
||||
|
||||
@retval EFI_SUCCESS The results have been distributed or are
|
||||
awaiting distribution.
|
||||
awaiting distribution.
|
||||
@retval EFI_OUT_OF_RESOURCES Not enough memory to store the
|
||||
parts of the results that must be
|
||||
stored awaiting possible future
|
||||
@@ -1513,12 +1513,12 @@ EfiLibGetVariable (
|
||||
);
|
||||
|
||||
/**
|
||||
Get option number according to Boot#### and BootOrder variable.
|
||||
Get option number according to Boot#### and BootOrder variable.
|
||||
The value is saved as #### + 1.
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
**/
|
||||
VOID
|
||||
VOID
|
||||
GetBootOrder (
|
||||
IN BMM_CALLBACK_DATA *CallbackData
|
||||
);
|
||||
@@ -1527,9 +1527,9 @@ GetBootOrder (
|
||||
Get driver option order from globalc DriverOptionMenu.
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
|
||||
**/
|
||||
VOID
|
||||
VOID
|
||||
GetDriverOrder (
|
||||
IN BMM_CALLBACK_DATA *CallbackData
|
||||
);
|
||||
@@ -1562,7 +1562,7 @@ VOID
|
||||
GetLegacyDeviceOrder (
|
||||
IN BMM_CALLBACK_DATA *CallbackData
|
||||
);
|
||||
|
||||
|
||||
/**
|
||||
|
||||
Initialize console input device check box to ConsoleInCheck[MAX_MENU_NUMBER]
|
||||
@@ -1570,12 +1570,12 @@ GetLegacyDeviceOrder (
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
**/
|
||||
VOID
|
||||
**/
|
||||
VOID
|
||||
GetConsoleInCheck (
|
||||
IN BMM_CALLBACK_DATA *CallbackData
|
||||
);
|
||||
|
||||
|
||||
/**
|
||||
|
||||
Initialize console output device check box to ConsoleOutCheck[MAX_MENU_NUMBER]
|
||||
@@ -1583,8 +1583,8 @@ GetConsoleInCheck (
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
**/
|
||||
VOID
|
||||
**/
|
||||
VOID
|
||||
GetConsoleOutCheck (
|
||||
IN BMM_CALLBACK_DATA *CallbackData
|
||||
);
|
||||
@@ -1596,8 +1596,8 @@ GetConsoleOutCheck (
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
**/
|
||||
VOID
|
||||
**/
|
||||
VOID
|
||||
GetConsoleErrCheck (
|
||||
IN BMM_CALLBACK_DATA *CallbackData
|
||||
);
|
||||
@@ -1609,8 +1609,8 @@ GetConsoleErrCheck (
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
**/
|
||||
VOID
|
||||
**/
|
||||
VOID
|
||||
GetTerminalAttribute (
|
||||
IN BMM_CALLBACK_DATA *CallbackData
|
||||
);
|
||||
|
@@ -5,7 +5,7 @@
|
||||
|
||||
Boot option manipulation
|
||||
|
||||
Copyright (c) 2004 - 2017, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -872,7 +872,7 @@ BOpt_GetBootOptions (
|
||||
EFI_DEVICE_PATH_PROTOCOL *DevicePath;
|
||||
UINTN MenuCount;
|
||||
UINT8 *Ptr;
|
||||
|
||||
|
||||
MenuCount = 0;
|
||||
BootOrderListSize = 0;
|
||||
BootNextSize = 0;
|
||||
@@ -893,7 +893,7 @@ BOpt_GetBootOptions (
|
||||
if (BootOrderList == NULL) {
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Get the BootNext from the Var
|
||||
//
|
||||
@@ -1007,7 +1007,7 @@ BOpt_GetBootOptions (
|
||||
|
||||
NewLoadContext->FilePathListLength = *(UINT16 *) LoadOptionPtr;
|
||||
LoadOptionPtr += sizeof (UINT16);
|
||||
|
||||
|
||||
StringSize = StrSize((UINT16*)LoadOptionPtr);
|
||||
|
||||
NewLoadContext->Description = AllocateCopyPool (StrSize((UINT16*)LoadOptionPtr), LoadOptionPtr);
|
||||
@@ -1099,7 +1099,7 @@ BOpt_AppendFileName (
|
||||
Str = AllocateZeroPool (MaxLen * sizeof (CHAR16));
|
||||
ASSERT (Str != NULL);
|
||||
|
||||
TmpStr = AllocateZeroPool (MaxLen * sizeof (CHAR16));
|
||||
TmpStr = AllocateZeroPool (MaxLen * sizeof (CHAR16));
|
||||
ASSERT (TmpStr != NULL);
|
||||
|
||||
StrCatS (Str, MaxLen, Str1);
|
||||
@@ -1120,7 +1120,7 @@ BOpt_AppendFileName (
|
||||
//
|
||||
|
||||
//
|
||||
// Use TmpStr as a backup, as StrCpyS in BaseLib does not handle copy of two strings
|
||||
// Use TmpStr as a backup, as StrCpyS in BaseLib does not handle copy of two strings
|
||||
// that overlap.
|
||||
//
|
||||
StrCpyS (TmpStr, MaxLen, Ptr + 3);
|
||||
@@ -1132,7 +1132,7 @@ BOpt_AppendFileName (
|
||||
//
|
||||
|
||||
//
|
||||
// Use TmpStr as a backup, as StrCpyS in BaseLib does not handle copy of two strings
|
||||
// Use TmpStr as a backup, as StrCpyS in BaseLib does not handle copy of two strings
|
||||
// that overlap.
|
||||
//
|
||||
StrCpyS (TmpStr, MaxLen, Ptr + 2);
|
||||
@@ -1146,7 +1146,7 @@ BOpt_AppendFileName (
|
||||
}
|
||||
|
||||
FreePool (TmpStr);
|
||||
|
||||
|
||||
return Str;
|
||||
}
|
||||
|
||||
@@ -1497,7 +1497,7 @@ BOpt_GetDriverOptions (
|
||||
if (DriverOrderList == NULL) {
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
|
||||
|
||||
for (Index = 0; Index < DriverOrderListSize / sizeof (UINT16); Index++) {
|
||||
UnicodeSPrint (
|
||||
DriverString,
|
||||
@@ -1676,20 +1676,20 @@ GetLegacyDeviceOrder (
|
||||
UINTN Index;
|
||||
UINTN OptionIndex;
|
||||
UINT16 PageIdList[5];
|
||||
UINTN PageNum;
|
||||
UINTN PageNum;
|
||||
UINTN VarSize;
|
||||
UINT8 *VarData;
|
||||
UINT8 *WorkingVarData;
|
||||
UINT8 *VarData;
|
||||
UINT8 *WorkingVarData;
|
||||
LEGACY_DEV_ORDER_ENTRY *DevOrder;
|
||||
UINT16 VarDevOrder;
|
||||
UINT8 *DisMap;
|
||||
UINT16 VarDevOrder;
|
||||
UINT8 *DisMap;
|
||||
BM_MENU_OPTION *OptionMenu;
|
||||
BBS_TYPE BbsType;
|
||||
UINT8 *LegacyOrder;
|
||||
UINT8 *OldData;
|
||||
UINT8 *OldData;
|
||||
UINTN Pos;
|
||||
UINTN Bit;
|
||||
|
||||
|
||||
ASSERT (CallbackData != NULL);
|
||||
|
||||
PageIdList[0] = FORM_SET_FD_ORDER_ID;
|
||||
@@ -1711,7 +1711,7 @@ GetLegacyDeviceOrder (
|
||||
|
||||
for (Index = 0; Index < PageNum; Index++) {
|
||||
switch (PageIdList[Index]) {
|
||||
|
||||
|
||||
case FORM_SET_FD_ORDER_ID:
|
||||
OptionMenu = (BM_MENU_OPTION *) &LegacyFDMenu;
|
||||
BbsType = BBS_FLOPPY;
|
||||
@@ -1725,14 +1725,14 @@ GetLegacyDeviceOrder (
|
||||
LegacyOrder = CallbackData->BmmFakeNvData.LegacyHD;
|
||||
OldData = CallbackData->BmmOldFakeNVData.LegacyHD;
|
||||
break;
|
||||
|
||||
|
||||
case FORM_SET_CD_ORDER_ID:
|
||||
OptionMenu = (BM_MENU_OPTION *) &LegacyCDMenu;
|
||||
BbsType = BBS_CDROM;
|
||||
LegacyOrder = CallbackData->BmmFakeNvData.LegacyCD;
|
||||
OldData = CallbackData->BmmOldFakeNVData.LegacyCD;
|
||||
break;
|
||||
|
||||
|
||||
case FORM_SET_NET_ORDER_ID:
|
||||
OptionMenu = (BM_MENU_OPTION *) &LegacyNETMenu;
|
||||
BbsType = BBS_EMBED_NETWORK;
|
||||
@@ -1748,7 +1748,7 @@ GetLegacyDeviceOrder (
|
||||
OldData = CallbackData->BmmOldFakeNVData.LegacyBEV;
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
if (NULL != VarData) {
|
||||
WorkingVarData = VarData;
|
||||
DevOrder = (LEGACY_DEV_ORDER_ENTRY *) WorkingVarData;
|
||||
@@ -1756,11 +1756,11 @@ GetLegacyDeviceOrder (
|
||||
if (DevOrder->BbsType == BbsType) {
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
WorkingVarData = (UINT8 *)((UINTN)WorkingVarData + sizeof (BBS_TYPE));
|
||||
WorkingVarData += *(UINT16 *) WorkingVarData;
|
||||
DevOrder = (LEGACY_DEV_ORDER_ENTRY *) WorkingVarData;
|
||||
}
|
||||
}
|
||||
for (OptionIndex = 0; OptionIndex < OptionMenu->MenuNumber; OptionIndex++) {
|
||||
VarDevOrder = *(UINT16 *) ((UINTN) DevOrder + sizeof (BBS_TYPE) + sizeof (UINT16) + OptionIndex * sizeof (UINT16));
|
||||
if (0xFF00 == (VarDevOrder & 0xFF00)) {
|
||||
@@ -1771,17 +1771,17 @@ GetLegacyDeviceOrder (
|
||||
} else {
|
||||
LegacyOrder[OptionIndex] = (UINT8) (VarDevOrder & 0xFF);
|
||||
}
|
||||
}
|
||||
}
|
||||
CopyMem (OldData, LegacyOrder, 100);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
Get driver option order from globalc DriverOptionMenu.
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
|
||||
**/
|
||||
VOID
|
||||
GetDriverOrder (
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
handles console redirection from boot manager
|
||||
|
||||
Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -32,7 +32,7 @@ UART_FLOW_CONTROL_DEVICE_PATH mFlowControlDevicePath =
|
||||
Check the device path node whether it's the Flow Control node or not.
|
||||
|
||||
@param[in] FlowControl The device path node to be checked.
|
||||
|
||||
|
||||
@retval TRUE It's the Flow Control node.
|
||||
@retval FALSE It's not.
|
||||
|
||||
@@ -85,11 +85,11 @@ UpdateComAttributeFromVariable (
|
||||
|
||||
/**
|
||||
Update the multi-instance device path of Terminal Device based on
|
||||
the global TerminalMenu. If ChangeTernimal is TRUE, the terminal
|
||||
the global TerminalMenu. If ChangeTernimal is TRUE, the terminal
|
||||
device path in the Terminal Device in TerminalMenu is also updated.
|
||||
|
||||
@param DevicePath The multi-instance device path.
|
||||
@param ChangeTerminal TRUE, then device path in the Terminal Device
|
||||
@param ChangeTerminal TRUE, then device path in the Terminal Device
|
||||
in TerminalMenu is also updated; FALSE, no update.
|
||||
|
||||
@return EFI_SUCCESS The function completes successfully.
|
||||
@@ -760,7 +760,7 @@ UpdateComAttributeFromVariable (
|
||||
and BM_CONSOLE_ERR_CONTEXT_SELECT.
|
||||
|
||||
@retval EFI_UNSUPPORTED The type passed in is not in the 3 types defined.
|
||||
@retval EFI_NOT_FOUND If the EFI Variable defined in UEFI spec with name "ConOutDev",
|
||||
@retval EFI_NOT_FOUND If the EFI Variable defined in UEFI spec with name "ConOutDev",
|
||||
"ConInDev" or "ConErrDev" doesn't exists.
|
||||
@retval EFI_OUT_OF_RESOURCES Not enough resource to complete the operations.
|
||||
@retval EFI_SUCCESS Function completes successfully.
|
||||
@@ -1057,24 +1057,24 @@ GetConsoleOutMode (
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
**/
|
||||
VOID
|
||||
**/
|
||||
VOID
|
||||
GetConsoleInCheck (
|
||||
IN BMM_CALLBACK_DATA *CallbackData
|
||||
)
|
||||
{
|
||||
UINT16 Index;
|
||||
BM_MENU_ENTRY *NewMenuEntry;
|
||||
BM_MENU_ENTRY *NewMenuEntry;
|
||||
UINT8 *ConInCheck;
|
||||
BM_CONSOLE_CONTEXT *NewConsoleContext;
|
||||
|
||||
|
||||
ASSERT (CallbackData != NULL);
|
||||
|
||||
|
||||
ConInCheck = &CallbackData->BmmFakeNvData.ConsoleInCheck[0];
|
||||
for (Index = 0; ((Index < ConsoleInpMenu.MenuNumber) && \
|
||||
(Index < MAX_MENU_NUMBER)) ; Index++) {
|
||||
(Index < MAX_MENU_NUMBER)) ; Index++) {
|
||||
NewMenuEntry = BOpt_GetMenuEntry (&ConsoleInpMenu, Index);
|
||||
NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext;
|
||||
NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext;
|
||||
ConInCheck[Index] = NewConsoleContext->IsActive;
|
||||
}
|
||||
}
|
||||
@@ -1086,27 +1086,27 @@ GetConsoleInCheck (
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
**/
|
||||
VOID
|
||||
**/
|
||||
VOID
|
||||
GetConsoleOutCheck (
|
||||
IN BMM_CALLBACK_DATA *CallbackData
|
||||
)
|
||||
{
|
||||
UINT16 Index;
|
||||
BM_MENU_ENTRY *NewMenuEntry;
|
||||
BM_MENU_ENTRY *NewMenuEntry;
|
||||
UINT8 *ConOutCheck;
|
||||
BM_CONSOLE_CONTEXT *NewConsoleContext;
|
||||
|
||||
|
||||
ASSERT (CallbackData != NULL);
|
||||
ConOutCheck = &CallbackData->BmmFakeNvData.ConsoleOutCheck[0];
|
||||
for (Index = 0; ((Index < ConsoleOutMenu.MenuNumber) && \
|
||||
(Index < MAX_MENU_NUMBER)) ; Index++) {
|
||||
(Index < MAX_MENU_NUMBER)) ; Index++) {
|
||||
NewMenuEntry = BOpt_GetMenuEntry (&ConsoleOutMenu, Index);
|
||||
NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext;
|
||||
NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext;
|
||||
ConOutCheck[Index] = NewConsoleContext->IsActive;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
|
||||
Initialize standard error output device check box to ConsoleErrCheck[MAX_MENU_NUMBER]
|
||||
@@ -1114,23 +1114,23 @@ GetConsoleOutCheck (
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
**/
|
||||
VOID
|
||||
**/
|
||||
VOID
|
||||
GetConsoleErrCheck (
|
||||
IN BMM_CALLBACK_DATA *CallbackData
|
||||
)
|
||||
{
|
||||
UINT16 Index;
|
||||
BM_MENU_ENTRY *NewMenuEntry;
|
||||
BM_MENU_ENTRY *NewMenuEntry;
|
||||
UINT8 *ConErrCheck;
|
||||
BM_CONSOLE_CONTEXT *NewConsoleContext;
|
||||
|
||||
|
||||
ASSERT (CallbackData != NULL);
|
||||
ConErrCheck = &CallbackData->BmmFakeNvData.ConsoleErrCheck[0];
|
||||
for (Index = 0; ((Index < ConsoleErrMenu.MenuNumber) && \
|
||||
(Index < MAX_MENU_NUMBER)) ; Index++) {
|
||||
(Index < MAX_MENU_NUMBER)) ; Index++) {
|
||||
NewMenuEntry = BOpt_GetMenuEntry (&ConsoleErrMenu, Index);
|
||||
NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext;
|
||||
NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext;
|
||||
ConErrCheck[Index] = NewConsoleContext->IsActive;
|
||||
}
|
||||
}
|
||||
@@ -1142,23 +1142,23 @@ GetConsoleErrCheck (
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
**/
|
||||
VOID
|
||||
**/
|
||||
VOID
|
||||
GetTerminalAttribute (
|
||||
IN BMM_CALLBACK_DATA *CallbackData
|
||||
)
|
||||
{
|
||||
BMM_FAKE_NV_DATA *CurrentFakeNVMap;
|
||||
BM_MENU_ENTRY *NewMenuEntry;
|
||||
BM_TERMINAL_CONTEXT *NewTerminalContext;
|
||||
UINT16 TerminalIndex;
|
||||
BM_TERMINAL_CONTEXT *NewTerminalContext;
|
||||
UINT16 TerminalIndex;
|
||||
UINT8 AttributeIndex;
|
||||
|
||||
ASSERT (CallbackData != NULL);
|
||||
|
||||
CurrentFakeNVMap = &CallbackData->BmmFakeNvData;
|
||||
|
||||
CurrentFakeNVMap = &CallbackData->BmmFakeNvData;
|
||||
for (TerminalIndex = 0; ((TerminalIndex < TerminalMenu.MenuNumber) && \
|
||||
(TerminalIndex < MAX_MENU_NUMBER)); TerminalIndex++) {
|
||||
(TerminalIndex < MAX_MENU_NUMBER)); TerminalIndex++) {
|
||||
NewMenuEntry = BOpt_GetMenuEntry (&TerminalMenu, TerminalIndex);
|
||||
NewTerminalContext = (BM_TERMINAL_CONTEXT *) NewMenuEntry->VariableContext;
|
||||
for (AttributeIndex = 0; AttributeIndex < sizeof (BaudRateList) / sizeof (BaudRateList [0]); AttributeIndex++) {
|
||||
@@ -1172,27 +1172,27 @@ GetTerminalAttribute (
|
||||
NewTerminalContext->DataBitsIndex = AttributeIndex;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
for (AttributeIndex = 0; AttributeIndex < ARRAY_SIZE (ParityList); AttributeIndex++) {
|
||||
if (NewTerminalContext->Parity == (UINT64) (ParityList[AttributeIndex].Value)) {
|
||||
NewTerminalContext->ParityIndex = AttributeIndex;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
for (AttributeIndex = 0; AttributeIndex < ARRAY_SIZE (StopBitsList); AttributeIndex++) {
|
||||
if (NewTerminalContext->StopBits == (UINT64) (StopBitsList[AttributeIndex].Value)) {
|
||||
NewTerminalContext->StopBitsIndex = AttributeIndex;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
CurrentFakeNVMap->COMBaudRate[TerminalIndex] = NewTerminalContext->BaudRateIndex;
|
||||
CurrentFakeNVMap->COMDataRate[TerminalIndex] = NewTerminalContext->DataBitsIndex;
|
||||
CurrentFakeNVMap->COMStopBits[TerminalIndex] = NewTerminalContext->StopBitsIndex;
|
||||
CurrentFakeNVMap->COMParity[TerminalIndex] = NewTerminalContext->ParityIndex;
|
||||
CurrentFakeNVMap->COMParity[TerminalIndex] = NewTerminalContext->ParityIndex;
|
||||
CurrentFakeNVMap->COMTerminalType[TerminalIndex] = NewTerminalContext->TerminalType;
|
||||
CurrentFakeNVMap->COMFlowControl[TerminalIndex] = NewTerminalContext->FlowControl;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -1,16 +1,16 @@
|
||||
///** @file
|
||||
//
|
||||
//
|
||||
// File Explorer Formset
|
||||
//
|
||||
// Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
//
|
||||
//**/
|
||||
|
||||
#include "FormGuid.h"
|
||||
@@ -124,4 +124,4 @@ formset
|
||||
|
||||
endform;
|
||||
|
||||
endformset;
|
||||
endformset;
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
File explorer related functions.
|
||||
|
||||
Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -236,7 +236,7 @@ UpdateFileExplorer (
|
||||
|
||||
@param[in] This Points to the EFI_HII_CONFIG_ACCESS_PROTOCOL.
|
||||
@param[in] Configuration A null-terminated Unicode string in
|
||||
<ConfigString> format.
|
||||
<ConfigString> format.
|
||||
@param[out] Progress A pointer to a string filled in with the
|
||||
offset of the most recent '&' before the
|
||||
first failing name / value pair (or the
|
||||
@@ -246,7 +246,7 @@ UpdateFileExplorer (
|
||||
successful.
|
||||
|
||||
@retval EFI_SUCCESS The results have been distributed or are
|
||||
awaiting distribution.
|
||||
awaiting distribution.
|
||||
@retval EFI_OUT_OF_RESOURCES Not enough memory to store the
|
||||
parts of the results that must be
|
||||
stored awaiting possible future
|
||||
@@ -289,8 +289,8 @@ FileExplorerRouteConfig (
|
||||
}
|
||||
|
||||
Status = gBS->LocateProtocol (
|
||||
&gEfiHiiConfigRoutingProtocolGuid,
|
||||
NULL,
|
||||
&gEfiHiiConfigRoutingProtocolGuid,
|
||||
NULL,
|
||||
(VOID**) &ConfigRouting
|
||||
);
|
||||
if (EFI_ERROR (Status)) {
|
||||
@@ -393,7 +393,7 @@ FileExplorerCallback (
|
||||
//
|
||||
return EFI_UNSUPPORTED;
|
||||
}
|
||||
|
||||
|
||||
Status = EFI_SUCCESS;
|
||||
Private = FE_CALLBACK_DATA_FROM_THIS (This);
|
||||
|
||||
@@ -407,7 +407,7 @@ FileExplorerCallback (
|
||||
if ((Value == NULL) || (ActionRequest == NULL)) {
|
||||
return EFI_INVALID_PARAMETER;
|
||||
}
|
||||
|
||||
|
||||
if (QuestionId == KEY_VALUE_SAVE_AND_EXIT_BOOT) {
|
||||
NvRamMap->BootOptionChanged = FALSE;
|
||||
*ActionRequest = EFI_BROWSER_ACTION_REQUEST_SUBMIT;
|
||||
@@ -451,7 +451,7 @@ FileExplorerCallback (
|
||||
if (Value == NULL) {
|
||||
return EFI_INVALID_PARAMETER;
|
||||
}
|
||||
|
||||
|
||||
if (QuestionId >= FILE_OPTION_GOTO_OFFSET) {
|
||||
//
|
||||
// function will always return FALSE, no need to check here.
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Dynamically update the pages.
|
||||
|
||||
Copyright (c) 2004 - 2017, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -25,7 +25,7 @@ RefreshUpdateData (
|
||||
{
|
||||
//
|
||||
// Free current updated date
|
||||
//
|
||||
//
|
||||
if (mStartOpCodeHandle != NULL) {
|
||||
HiiFreeOpCodeHandle (mStartOpCodeHandle);
|
||||
}
|
||||
@@ -46,7 +46,7 @@ RefreshUpdateData (
|
||||
/**
|
||||
Add a "Go back to main page" tag in front of the form when there are no
|
||||
"Apply changes" and "Discard changes" tags in the end of the form.
|
||||
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
**/
|
||||
@@ -131,7 +131,7 @@ UpdatePageEnd (
|
||||
}
|
||||
|
||||
/**
|
||||
Clean up the dynamic opcode at label and form specified by both LabelId.
|
||||
Clean up the dynamic opcode at label and form specified by both LabelId.
|
||||
|
||||
@param LabelId It is both the Form ID and Label ID for opcode deletion.
|
||||
@param CallbackData The BMM context data.
|
||||
@@ -345,7 +345,7 @@ UpdateDrvDelPage (
|
||||
UpdatePageStart (CallbackData);
|
||||
|
||||
CreateMenuStringToken (CallbackData, CallbackData->BmmHiiHandle, &DriverOptionMenu);
|
||||
|
||||
|
||||
ASSERT (DriverOptionMenu.MenuNumber <= (sizeof (CallbackData->BmmFakeNvData.DriverOptionDel) / sizeof (CallbackData->BmmFakeNvData.DriverOptionDel[0])));
|
||||
for (Index = 0; Index < DriverOptionMenu.MenuNumber; Index++) {
|
||||
NewMenuEntry = BOpt_GetMenuEntry (&DriverOptionMenu, Index);
|
||||
@@ -380,7 +380,7 @@ UpdateDrvDelPage (
|
||||
}
|
||||
|
||||
/**
|
||||
Prepare the page to allow user to add description for
|
||||
Prepare the page to allow user to add description for
|
||||
a Driver Option.
|
||||
|
||||
@param CallbackData The BMM context data.
|
||||
@@ -552,11 +552,11 @@ UpdateOrderPage (
|
||||
UpdatePageStart (CallbackData);
|
||||
|
||||
CreateMenuStringToken (CallbackData, CallbackData->BmmHiiHandle, OptionMenu);
|
||||
|
||||
|
||||
OptionOrder = NULL;
|
||||
QuestionId = 0;
|
||||
VarOffset = 0;
|
||||
switch (UpdatePageId) {
|
||||
switch (UpdatePageId) {
|
||||
|
||||
case FORM_BOOT_CHG_ID:
|
||||
//
|
||||
@@ -587,12 +587,12 @@ UpdateOrderPage (
|
||||
QuestionId = DRIVER_OPTION_ORDER_QUESTION_ID;
|
||||
VarOffset = DRIVER_OPTION_ORDER_VAR_OFFSET;
|
||||
break;
|
||||
}
|
||||
}
|
||||
ASSERT (OptionOrder != NULL);
|
||||
|
||||
OptionsOpCodeHandle = HiiAllocateOpCodeHandle ();
|
||||
ASSERT (OptionsOpCodeHandle != NULL);
|
||||
|
||||
|
||||
NewMenuEntry = NULL;
|
||||
for (OptionIndex = 0; (OptionIndex < MAX_MENU_NUMBER && OptionOrder[OptionIndex] != 0); OptionIndex++) {
|
||||
BootOptionFound = FALSE;
|
||||
@@ -613,21 +613,21 @@ UpdateOrderPage (
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (OptionMenu->MenuNumber > 0) {
|
||||
HiiCreateOrderedListOpCode (
|
||||
mStartOpCodeHandle, // Container for dynamic created opcodes
|
||||
QuestionId, // Question ID
|
||||
VARSTORE_ID_BOOT_MAINT, // VarStore ID
|
||||
VarOffset, // Offset in Buffer Storage
|
||||
STRING_TOKEN (STR_CHANGE_ORDER), // Question prompt text
|
||||
STRING_TOKEN (STR_CHANGE_ORDER), // Question help text
|
||||
0, // Question flag
|
||||
HiiCreateOrderedListOpCode (
|
||||
mStartOpCodeHandle, // Container for dynamic created opcodes
|
||||
QuestionId, // Question ID
|
||||
VARSTORE_ID_BOOT_MAINT, // VarStore ID
|
||||
VarOffset, // Offset in Buffer Storage
|
||||
STRING_TOKEN (STR_CHANGE_ORDER), // Question prompt text
|
||||
STRING_TOKEN (STR_CHANGE_ORDER), // Question help text
|
||||
0, // Question flag
|
||||
0, // Ordered list flag, e.g. EFI_IFR_UNIQUE_SET
|
||||
EFI_IFR_TYPE_NUM_SIZE_32, // Data type of Question value
|
||||
100, // Maximum container
|
||||
OptionsOpCodeHandle, // Option Opcode list
|
||||
NULL // Default Opcode is NULL
|
||||
EFI_IFR_TYPE_NUM_SIZE_32, // Data type of Question value
|
||||
100, // Maximum container
|
||||
OptionsOpCodeHandle, // Option Opcode list
|
||||
NULL // Default Opcode is NULL
|
||||
);
|
||||
}
|
||||
|
||||
@@ -706,7 +706,7 @@ UpdateBootNextPage (
|
||||
EFI_IFR_TYPE_NUM_SIZE_16,
|
||||
Index
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
HiiCreateOneOfOpCode (
|
||||
mStartOpCodeHandle,
|
||||
@@ -765,7 +765,7 @@ UpdateTimeOutPage (
|
||||
0,
|
||||
DefaultOpCodeHandle
|
||||
);
|
||||
|
||||
|
||||
HiiFreeOpCodeHandle (DefaultOpCodeHandle);
|
||||
|
||||
//CallbackData->BmmFakeNvData.BootTimeOut = BootTimeOut;
|
||||
@@ -840,7 +840,7 @@ UpdateConModePage (
|
||||
if (EFI_ERROR (Status)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Build mode string Column x Row
|
||||
//
|
||||
@@ -956,7 +956,7 @@ UpdateTerminalPage (
|
||||
OptionsOpCodeHandle,
|
||||
NULL
|
||||
);
|
||||
|
||||
|
||||
HiiFreeOpCodeHandle (OptionsOpCodeHandle);
|
||||
OptionsOpCodeHandle = HiiAllocateOpCodeHandle ();
|
||||
ASSERT (OptionsOpCodeHandle != NULL);
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Variable operation that will be used by bootmaint
|
||||
|
||||
Copyright (c) 2004 - 2015, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -19,10 +19,10 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
After deleting this boot option, call Var_ChangeBootOrder to
|
||||
make sure BootOrder is in valid state.
|
||||
|
||||
@retval EFI_SUCCESS If all boot load option EFI Variables corresponding to
|
||||
@retval EFI_SUCCESS If all boot load option EFI Variables corresponding to
|
||||
BM_LOAD_CONTEXT marked for deletion is deleted.
|
||||
@retval EFI_NOT_FOUND If can not find the boot option want to be deleted.
|
||||
@return Others If failed to update the "BootOrder" variable after deletion.
|
||||
@return Others If failed to update the "BootOrder" variable after deletion.
|
||||
|
||||
**/
|
||||
EFI_STATUS
|
||||
@@ -86,7 +86,7 @@ Var_DelBootOption (
|
||||
scratch by content from BootOptionMenu is needed.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The boot order is updated successfully.
|
||||
@return EFI_STATUS other than EFI_SUCCESS if failed to
|
||||
@@ -313,7 +313,7 @@ Var_ChangeDriverOrder (
|
||||
}
|
||||
|
||||
/**
|
||||
Update the device path of "ConOut", "ConIn" and "ErrOut"
|
||||
Update the device path of "ConOut", "ConIn" and "ErrOut"
|
||||
based on the new BaudRate, Data Bits, parity and Stop Bits
|
||||
set.
|
||||
|
||||
@@ -383,7 +383,7 @@ Var_UpdateAllConsoleOption (
|
||||
|
||||
This function clear the EFI variable defined by ConsoleName and
|
||||
gEfiGlobalVariableGuid. It then build the multi-instance device
|
||||
path by appending the device path of the Console (In/Out/Err) instance
|
||||
path by appending the device path of the Console (In/Out/Err) instance
|
||||
in ConsoleMenu. Then it scan all corresponding console device by
|
||||
scanning Terminal (built from device supporting Serial I/O instances)
|
||||
devices in TerminalMenu. At last, it save a EFI variable specifed
|
||||
@@ -447,7 +447,7 @@ Var_UpdateConsoleOption (
|
||||
) {
|
||||
Vendor.Header.Type = MESSAGING_DEVICE_PATH;
|
||||
Vendor.Header.SubType = MSG_VENDOR_DP;
|
||||
|
||||
|
||||
ASSERT (NewTerminalContext->TerminalType < (ARRAY_SIZE (TerminalTypeGuid)));
|
||||
CopyMem (
|
||||
&Vendor.Guid,
|
||||
@@ -520,7 +520,7 @@ Var_UpdateConsoleOutOption (
|
||||
console device.
|
||||
|
||||
@retval EFI_SUCCESS The function complete successfully.
|
||||
@return The EFI variable can not be saved. See gRT->SetVariable for detail return information.
|
||||
@return The EFI variable can not be saved. See gRT->SetVariable for detail return information.
|
||||
**/
|
||||
EFI_STATUS
|
||||
Var_UpdateErrorOutOption (
|
||||
@@ -531,8 +531,8 @@ Var_UpdateErrorOutOption (
|
||||
}
|
||||
|
||||
/**
|
||||
This function create a currently loaded Drive Option from
|
||||
the BMM. It then appends this Driver Option to the end of
|
||||
This function create a currently loaded Drive Option from
|
||||
the BMM. It then appends this Driver Option to the end of
|
||||
the "DriverOrder" list. It append this Driver Opotion to the end
|
||||
of DriverOptionMenu.
|
||||
|
||||
@@ -726,8 +726,8 @@ Var_UpdateDriverOption (
|
||||
}
|
||||
|
||||
/**
|
||||
This function create a currently loaded Boot Option from
|
||||
the BMM. It then appends this Boot Option to the end of
|
||||
This function create a currently loaded Boot Option from
|
||||
the BMM. It then appends this Boot Option to the end of
|
||||
the "BootOrder" list. It also append this Boot Opotion to the end
|
||||
of BootOptionMenu.
|
||||
|
||||
@@ -911,7 +911,7 @@ Var_UpdateBootOption (
|
||||
}
|
||||
|
||||
/**
|
||||
This function update the "BootNext" EFI Variable. If there is
|
||||
This function update the "BootNext" EFI Variable. If there is
|
||||
no "BootNext" specified in BMM, this EFI Variable is deleted.
|
||||
It also update the BMM context data specified the "BootNext"
|
||||
vaule.
|
||||
@@ -919,7 +919,7 @@ Var_UpdateBootOption (
|
||||
@param CallbackData The BMM context data.
|
||||
|
||||
@retval EFI_SUCCESS The function complete successfully.
|
||||
@return The EFI variable can be saved. See gRT->SetVariable
|
||||
@return The EFI variable can be saved. See gRT->SetVariable
|
||||
for detail return information.
|
||||
|
||||
**/
|
||||
@@ -1105,7 +1105,7 @@ Var_UpdateDriverOrder (
|
||||
// Changing the content without increasing its size with current variable implementation shouldn't fail.
|
||||
//
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
|
||||
|
||||
BOpt_FreeMenu (&DriverOptionMenu);
|
||||
BOpt_GetDriverOptions (CallbackData);
|
||||
return EFI_SUCCESS;
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
The platform boot manager reference implementation
|
||||
|
||||
Copyright (c) 2004 - 2015, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -44,7 +44,7 @@ HII_VENDOR_DEVICE_PATH mBootManagerHiiVendorDevicePath = {
|
||||
{
|
||||
END_DEVICE_PATH_TYPE,
|
||||
END_ENTIRE_DEVICE_PATH_SUBTYPE,
|
||||
{
|
||||
{
|
||||
(UINT8) (END_DEVICE_PATH_LENGTH),
|
||||
(UINT8) ((END_DEVICE_PATH_LENGTH) >> 8)
|
||||
}
|
||||
@@ -187,10 +187,10 @@ InitializeBootManager (
|
||||
|
||||
/**
|
||||
This function invokes Boot Manager. If all devices have not a chance to be connected,
|
||||
the connect all will be triggered. It then enumerate all boot options. If
|
||||
the connect all will be triggered. It then enumerate all boot options. If
|
||||
a boot option from the Boot Manager page is selected, Boot Manager will boot
|
||||
from this boot option.
|
||||
|
||||
|
||||
**/
|
||||
VOID
|
||||
CallBootManager (
|
||||
@@ -294,7 +294,7 @@ CallBootManager (
|
||||
NeedEndOp = FALSE;
|
||||
HiiCreateEndOpCode (StartOpCodeHandle);
|
||||
}
|
||||
|
||||
|
||||
if (IsLegacyOption && DeviceType != ((BBS_BBS_DEVICE_PATH *) Option->DevicePath)->DeviceType) {
|
||||
if (NeedEndOp) {
|
||||
HiiCreateEndOpCode (StartOpCodeHandle);
|
||||
@@ -314,7 +314,7 @@ CallBootManager (
|
||||
}
|
||||
|
||||
ASSERT (Option->Description != NULL);
|
||||
|
||||
|
||||
Token = HiiSetString (HiiHandle, 0, Option->Description, NULL);
|
||||
|
||||
TempStr = DevicePathToStr (Option->DevicePath);
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
The platform boot manager reference implement
|
||||
|
||||
Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -90,10 +90,10 @@ InitializeBootManager (
|
||||
|
||||
/**
|
||||
This function invokes Boot Manager. If all devices have not a chance to be connected,
|
||||
the connect all will be triggered. It then enumerate all boot options. If
|
||||
the connect all will be triggered. It then enumerate all boot options. If
|
||||
a boot option from the Boot Manager page is selected, Boot Manager will boot
|
||||
from this boot option.
|
||||
|
||||
|
||||
**/
|
||||
VOID
|
||||
CallBootManager (
|
||||
|
@@ -1,16 +1,16 @@
|
||||
///** @file
|
||||
//
|
||||
//
|
||||
// String definitions for BdsPlatform formset.
|
||||
//
|
||||
// Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
//
|
||||
//**/
|
||||
|
||||
/=#
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
BDS routines to handle capsules.
|
||||
|
||||
Copyright (c) 2004 - 2013, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -51,7 +51,7 @@ BdsProcessCapsules (
|
||||
UINT32 CacheNumber;
|
||||
VOID **CapsulePtr;
|
||||
VOID **CapsulePtrCache;
|
||||
EFI_GUID *CapsuleGuidCache;
|
||||
EFI_GUID *CapsuleGuidCache;
|
||||
BOOLEAN NeedReset;
|
||||
|
||||
CapsuleNumber = 0;
|
||||
@@ -70,7 +70,7 @@ BdsProcessCapsules (
|
||||
DEBUG ((EFI_D_ERROR, "Boot mode is not correct for capsule update.\n"));
|
||||
return EFI_INVALID_PARAMETER;
|
||||
}
|
||||
|
||||
|
||||
Status = EFI_SUCCESS;
|
||||
//
|
||||
// Find all capsule images from hob
|
||||
@@ -80,7 +80,7 @@ BdsProcessCapsules (
|
||||
CapsuleTotalNumber ++;
|
||||
HobPointer.Raw = GET_NEXT_HOB (HobPointer);
|
||||
}
|
||||
|
||||
|
||||
if (CapsuleTotalNumber == 0) {
|
||||
//
|
||||
// We didn't find a hob, so had no errors.
|
||||
@@ -92,7 +92,7 @@ BdsProcessCapsules (
|
||||
PlatformBdsLockNonUpdatableFlash ();
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Init temp Capsule Data table.
|
||||
//
|
||||
@@ -102,7 +102,7 @@ BdsProcessCapsules (
|
||||
ASSERT (CapsulePtrCache != NULL);
|
||||
CapsuleGuidCache = (EFI_GUID *) AllocateZeroPool (sizeof (EFI_GUID) * CapsuleTotalNumber);
|
||||
ASSERT (CapsuleGuidCache != NULL);
|
||||
|
||||
|
||||
//
|
||||
// Find all capsule images from hob
|
||||
//
|
||||
@@ -119,12 +119,12 @@ BdsProcessCapsules (
|
||||
|
||||
//
|
||||
// Capsules who have CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE always are used for operating
|
||||
// System to have information persist across a system reset. EFI System Table must
|
||||
// System to have information persist across a system reset. EFI System Table must
|
||||
// point to an array of capsules that contains the same CapsuleGuid value. And agents
|
||||
// searching for this type capsule will look in EFI System Table and search for the
|
||||
// searching for this type capsule will look in EFI System Table and search for the
|
||||
// capsule's Guid and associated pointer to retrieve the data. Two steps below describes
|
||||
// how to sorting the capsules by the unique guid and install the array to EFI System Table.
|
||||
// Firstly, Loop for all coalesced capsules, record unique CapsuleGuids and cache them in an
|
||||
// how to sorting the capsules by the unique guid and install the array to EFI System Table.
|
||||
// Firstly, Loop for all coalesced capsules, record unique CapsuleGuids and cache them in an
|
||||
// array for later sorting capsules by CapsuleGuid.
|
||||
//
|
||||
for (Index = 0; Index < CapsuleTotalNumber; Index++) {
|
||||
@@ -132,7 +132,7 @@ BdsProcessCapsules (
|
||||
if ((CapsuleHeader->Flags & CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE) != 0) {
|
||||
//
|
||||
// For each capsule, we compare it with known CapsuleGuid in the CacheArray.
|
||||
// If already has the Guid, skip it. Whereas, record it in the CacheArray as
|
||||
// If already has the Guid, skip it. Whereas, record it in the CacheArray as
|
||||
// an additional one.
|
||||
//
|
||||
CacheIndex = 0;
|
||||
@@ -159,7 +159,7 @@ BdsProcessCapsules (
|
||||
//
|
||||
CacheIndex = 0;
|
||||
while (CacheIndex < CacheNumber) {
|
||||
CapsuleNumber = 0;
|
||||
CapsuleNumber = 0;
|
||||
for (Index = 0; Index < CapsuleTotalNumber; Index++) {
|
||||
CapsuleHeader = (EFI_CAPSULE_HEADER*) CapsulePtr [Index];
|
||||
if ((CapsuleHeader->Flags & CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE) != 0) {
|
||||
@@ -172,7 +172,7 @@ BdsProcessCapsules (
|
||||
}
|
||||
}
|
||||
if (CapsuleNumber != 0) {
|
||||
Size = sizeof(EFI_CAPSULE_TABLE) + (CapsuleNumber - 1) * sizeof(VOID*);
|
||||
Size = sizeof(EFI_CAPSULE_TABLE) + (CapsuleNumber - 1) * sizeof(VOID*);
|
||||
CapsuleTable = AllocateRuntimePool (Size);
|
||||
ASSERT (CapsuleTable != NULL);
|
||||
CapsuleTable->CapsuleArrayNumber = CapsuleNumber;
|
||||
@@ -185,7 +185,7 @@ BdsProcessCapsules (
|
||||
|
||||
//
|
||||
// Besides ones with CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE flag, all capsules left are
|
||||
// recognized by platform with CapsuleGuid. For general platform driver, UpdateFlash
|
||||
// recognized by platform with CapsuleGuid. For general platform driver, UpdateFlash
|
||||
// type is commonly supported, so here only deal with encapsuled FVs capsule. Additional
|
||||
// type capsule transaction could be extended. It depends on platform policy.
|
||||
//
|
||||
@@ -220,7 +220,7 @@ BdsProcessCapsules (
|
||||
}
|
||||
|
||||
PlatformBdsLockNonUpdatableFlash ();
|
||||
|
||||
|
||||
//
|
||||
// Free the allocated temp memory space.
|
||||
//
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
The platform device manager reference implementation
|
||||
|
||||
Copyright (c) 2004 - 2017, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -43,7 +43,7 @@ EFI_STRING mSelectedMacAddrString;
|
||||
//
|
||||
// Which form Id need to be show.
|
||||
//
|
||||
EFI_FORM_ID mNextShowFormId = DEVICE_MANAGER_FORM_ID;
|
||||
EFI_FORM_ID mNextShowFormId = DEVICE_MANAGER_FORM_ID;
|
||||
|
||||
//
|
||||
// The Mac Address show in the NETWORK_DEVICE_LIST_FORM_ID
|
||||
@@ -74,7 +74,7 @@ HII_VENDOR_DEVICE_PATH mDeviceManagerHiiVendorDevicePath = {
|
||||
{
|
||||
END_DEVICE_PATH_TYPE,
|
||||
END_ENTIRE_DEVICE_PATH_SUBTYPE,
|
||||
{
|
||||
{
|
||||
(UINT8) (END_DEVICE_PATH_LENGTH),
|
||||
(UINT8) ((END_DEVICE_PATH_LENGTH) >> 8)
|
||||
}
|
||||
@@ -96,7 +96,7 @@ HII_VENDOR_DEVICE_PATH mDriverHealthHiiVendorDevicePath = {
|
||||
{
|
||||
END_DEVICE_PATH_TYPE,
|
||||
END_ENTIRE_DEVICE_PATH_SUBTYPE,
|
||||
{
|
||||
{
|
||||
(UINT8) (END_DEVICE_PATH_LENGTH),
|
||||
(UINT8) ((END_DEVICE_PATH_LENGTH) >> 8)
|
||||
}
|
||||
@@ -240,7 +240,7 @@ ExtractDisplayedHiiFormFromHiiHandle (
|
||||
UINT8 ClassGuidNum;
|
||||
|
||||
ASSERT (Handle != NULL);
|
||||
ASSERT (SetupClassGuid != NULL);
|
||||
ASSERT (SetupClassGuid != NULL);
|
||||
ASSERT (FormSetTitle != NULL);
|
||||
ASSERT (FormSetHelp != NULL);
|
||||
|
||||
@@ -263,7 +263,7 @@ ExtractDisplayedHiiFormFromHiiHandle (
|
||||
// The return status should always be EFI_BUFFER_TOO_SMALL as input buffer's size is 0.
|
||||
//
|
||||
ASSERT (Status == EFI_BUFFER_TOO_SMALL);
|
||||
|
||||
|
||||
HiiPackageList = AllocatePool (BufferSize);
|
||||
ASSERT (HiiPackageList != NULL);
|
||||
|
||||
@@ -326,7 +326,7 @@ ExtractDisplayedHiiFormFromHiiHandle (
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Go to next package
|
||||
//
|
||||
@@ -341,12 +341,12 @@ ExtractDisplayedHiiFormFromHiiHandle (
|
||||
/**
|
||||
Get the mac address string from the device path.
|
||||
if the device path has the vlan, get the vanid also.
|
||||
|
||||
@param MacAddressNode Device path begin with mac address
|
||||
|
||||
@param MacAddressNode Device path begin with mac address
|
||||
@param PBuffer Output string buffer contain mac address.
|
||||
|
||||
**/
|
||||
BOOLEAN
|
||||
BOOLEAN
|
||||
GetMacAddressString(
|
||||
IN MAC_ADDR_DEVICE_PATH *MacAddressNode,
|
||||
OUT CHAR16 **PBuffer
|
||||
@@ -382,7 +382,7 @@ GetMacAddressString(
|
||||
*PBuffer = String;
|
||||
StrCpyS (String, BufferLen / sizeof (CHAR16), L"MAC:");
|
||||
String += 4;
|
||||
|
||||
|
||||
//
|
||||
// Convert the MAC address into a unicode string.
|
||||
//
|
||||
@@ -400,7 +400,7 @@ GetMacAddressString(
|
||||
*String++ = L':';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// If VLAN is configured, it will need extra 5 characters like "\0005".
|
||||
// Plus one unicode character for the null-terminator.
|
||||
@@ -442,7 +442,7 @@ GetMacAddressString(
|
||||
@retval EFI_SUCCESS Add the item is successful.
|
||||
@return Other values if failed to Add the item.
|
||||
**/
|
||||
BOOLEAN
|
||||
BOOLEAN
|
||||
AddIdToMacDeviceList (
|
||||
IN EFI_STRING MacAddrString
|
||||
)
|
||||
@@ -488,13 +488,13 @@ AddIdToMacDeviceList (
|
||||
} else {
|
||||
TempDeviceList = (MENU_INFO_ITEM *)AllocatePool (sizeof (MENU_INFO_ITEM) * mMacDeviceList.MaxListLen);
|
||||
}
|
||||
|
||||
|
||||
if (TempDeviceList == NULL) {
|
||||
return FALSE;
|
||||
}
|
||||
TempDeviceList[mMacDeviceList.CurListLen].PromptId = PromptId;
|
||||
TempDeviceList[mMacDeviceList.CurListLen].PromptId = PromptId;
|
||||
TempDeviceList[mMacDeviceList.CurListLen].QuestionId = (EFI_QUESTION_ID) (mMacDeviceList.CurListLen + NETWORK_DEVICE_LIST_KEY_OFFSET);
|
||||
|
||||
|
||||
mMacDeviceList.NodeList = TempDeviceList;
|
||||
}
|
||||
mMacDeviceList.CurListLen ++;
|
||||
@@ -511,9 +511,9 @@ AddIdToMacDeviceList (
|
||||
|
||||
@param *Node Input device which need to be check.
|
||||
@param *NeedAddItem Whether need to add the menu in the network device list.
|
||||
|
||||
|
||||
@retval TRUE Has mac address device path.
|
||||
@retval FALSE NOT Has mac address device path.
|
||||
@retval FALSE NOT Has mac address device path.
|
||||
|
||||
**/
|
||||
BOOLEAN
|
||||
@@ -525,7 +525,7 @@ IsMacAddressDevicePath (
|
||||
EFI_DEVICE_PATH_PROTOCOL *DevicePath;
|
||||
CHAR16 *Buffer;
|
||||
BOOLEAN ReturnVal;
|
||||
|
||||
|
||||
ASSERT (Node != NULL);
|
||||
*NeedAddItem = FALSE;
|
||||
ReturnVal = FALSE;
|
||||
@@ -540,12 +540,12 @@ IsMacAddressDevicePath (
|
||||
if ((DevicePathType (DevicePath) == MESSAGING_DEVICE_PATH) &&
|
||||
(DevicePathSubType (DevicePath) == MSG_MAC_ADDR_DP)) {
|
||||
ReturnVal = TRUE;
|
||||
|
||||
|
||||
if (DEVICE_MANAGER_FORM_ID == mNextShowFormId) {
|
||||
*NeedAddItem = TRUE;
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if (!GetMacAddressString((MAC_ADDR_DEVICE_PATH*)DevicePath, &Buffer)) {
|
||||
break;
|
||||
}
|
||||
@@ -559,7 +559,7 @@ IsMacAddressDevicePath (
|
||||
|
||||
if (NETWORK_DEVICE_LIST_FORM_ID == mNextShowFormId) {
|
||||
//
|
||||
// Same handle may has two network child handle, so the questionid
|
||||
// Same handle may has two network child handle, so the questionid
|
||||
// has the offset of SAME_HANDLE_KEY_OFFSET.
|
||||
//
|
||||
if (AddIdToMacDeviceList (Buffer)) {
|
||||
@@ -567,7 +567,7 @@ IsMacAddressDevicePath (
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
DevicePath = NextDevicePathNode (DevicePath);
|
||||
}
|
||||
|
||||
@@ -588,7 +588,7 @@ IsMacAddressDevicePath (
|
||||
@return FALSE Do not need to add the menu about the network.
|
||||
|
||||
**/
|
||||
BOOLEAN
|
||||
BOOLEAN
|
||||
IsNeedAddNetworkMenu (
|
||||
IN EFI_HII_HANDLE Handle,
|
||||
OUT UINTN *ItemCount
|
||||
@@ -596,7 +596,7 @@ IsNeedAddNetworkMenu (
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
UINTN EntryCount;
|
||||
UINTN Index;
|
||||
UINTN Index;
|
||||
EFI_HANDLE DriverHandle;
|
||||
EFI_HANDLE ControllerHandle;
|
||||
EFI_DEVICE_PATH_PROTOCOL *DevicePath;
|
||||
@@ -625,9 +625,9 @@ IsNeedAddNetworkMenu (
|
||||
}
|
||||
TmpDevicePath = DevicePath;
|
||||
|
||||
//
|
||||
//
|
||||
// Check whether this device path include mac address device path.
|
||||
// If this path has mac address path, get the value whether need
|
||||
// If this path has mac address path, get the value whether need
|
||||
// add this info to the menu and return.
|
||||
// Else check more about the child handle devcie path.
|
||||
//
|
||||
@@ -649,7 +649,7 @@ IsNeedAddNetworkMenu (
|
||||
}
|
||||
|
||||
if (!IsDevicePathEnd (TmpDevicePath)) {
|
||||
return FALSE;
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
//
|
||||
@@ -688,7 +688,7 @@ IsNeedAddNetworkMenu (
|
||||
continue;
|
||||
}
|
||||
|
||||
//
|
||||
//
|
||||
// Check whether this device path include mac address device path.
|
||||
//
|
||||
if (!IsMacAddressDevicePath(ChildDevicePath, &IsNeedAdd)) {
|
||||
@@ -708,7 +708,7 @@ IsNeedAddNetworkMenu (
|
||||
} else {
|
||||
//
|
||||
// If need to update other form, return whether need to add to the menu.
|
||||
//
|
||||
//
|
||||
goto Done;
|
||||
}
|
||||
}
|
||||
@@ -717,9 +717,9 @@ IsNeedAddNetworkMenu (
|
||||
|
||||
Done:
|
||||
if (OpenInfoBuffer != NULL) {
|
||||
FreePool (OpenInfoBuffer);
|
||||
FreePool (OpenInfoBuffer);
|
||||
}
|
||||
return IsNeedAdd;
|
||||
return IsNeedAdd;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -749,7 +749,7 @@ GetHiiHandleCount (
|
||||
@param HiiHandles The input HiiHandle array.
|
||||
@param GuidLists The input form set guid lists.
|
||||
@param ArrayCount The input array count, new array will be arraycount + 1 size.
|
||||
@param Offset The current used HiiHandle's Offset.
|
||||
@param Offset The current used HiiHandle's Offset.
|
||||
@param FormSetGuid The new found formset guid.
|
||||
|
||||
**/
|
||||
@@ -793,7 +793,7 @@ AdjustArrayData (
|
||||
|
||||
This function create the dynamic content for device manager. It includes
|
||||
section header for all class of devices, one-of opcode to set VBIOS.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS Operation is successful.
|
||||
@return Other values if failed to clean up the dynamic content from HII
|
||||
database.
|
||||
@@ -883,7 +883,7 @@ CallDeviceManager (
|
||||
NewStringLen += (StrLen(String) + 2) * 2;
|
||||
NewStringTitle = AllocatePool (NewStringLen);
|
||||
UnicodeSPrint (NewStringTitle, NewStringLen, L"%s %s", String, mSelectedMacAddrString);
|
||||
HiiSetString (HiiHandle, STRING_TOKEN (STR_FORM_NETWORK_DEVICE_TITLE), NewStringTitle, NULL);
|
||||
HiiSetString (HiiHandle, STRING_TOKEN (STR_FORM_NETWORK_DEVICE_TITLE), NewStringTitle, NULL);
|
||||
FreePool (String);
|
||||
FreePool (NewStringTitle);
|
||||
}
|
||||
@@ -941,9 +941,9 @@ CallDeviceManager (
|
||||
}
|
||||
|
||||
//
|
||||
// One HiiHandle has more than one formset can be shown,
|
||||
// One HiiHandle has more than one formset can be shown,
|
||||
// Insert a new pair of HiiHandle + Guid to the HiiHandles and GuidLists list.
|
||||
//
|
||||
//
|
||||
if (SkipCount > 0) {
|
||||
AdjustArrayData (&HiiHandles, &GuidLists, HandleNum, Index + 1, FormSetGuid);
|
||||
HandleNum ++;
|
||||
@@ -968,7 +968,7 @@ CallDeviceManager (
|
||||
|
||||
//
|
||||
// Network device process
|
||||
//
|
||||
//
|
||||
if (IsNeedAddNetworkMenu (HiiHandles[Index], &AddItemCount)) {
|
||||
if (mNextShowFormId == DEVICE_MANAGER_FORM_ID) {
|
||||
//
|
||||
@@ -1015,7 +1015,7 @@ CallDeviceManager (
|
||||
}
|
||||
} else {
|
||||
//
|
||||
//
|
||||
//
|
||||
// Not network device process, only need to show at device manger form.
|
||||
//
|
||||
if (mNextShowFormId == DEVICE_MANAGER_FORM_ID) {
|
||||
@@ -1128,7 +1128,7 @@ CallDeviceManager (
|
||||
}
|
||||
|
||||
//
|
||||
// Driver Health item chose.
|
||||
// Driver Health item chose.
|
||||
//
|
||||
if (gCallbackKey == DEVICE_MANAGER_KEY_DRIVER_HEALTH) {
|
||||
CallDriverHealth ();
|
||||
@@ -1152,7 +1152,7 @@ CallDeviceManager (
|
||||
// In this case, go from the network device list to the specify device.
|
||||
//
|
||||
if ((gCallbackKey < MAX_KEY_SECTION_LEN + NETWORK_DEVICE_LIST_KEY_OFFSET ) && (gCallbackKey >= NETWORK_DEVICE_LIST_KEY_OFFSET)) {
|
||||
mNextShowFormId = NETWORK_DEVICE_FORM_ID;
|
||||
mNextShowFormId = NETWORK_DEVICE_FORM_ID;
|
||||
gCallbackKey = FRONT_PAGE_KEY_DEVICE_MANAGER;
|
||||
goto Done;
|
||||
}
|
||||
@@ -1237,10 +1237,10 @@ DriverHealthCallback (
|
||||
}
|
||||
|
||||
/**
|
||||
Collect and display the platform's driver health relative information, allow user to do interactive
|
||||
Collect and display the platform's driver health relative information, allow user to do interactive
|
||||
operation while the platform is unhealthy.
|
||||
|
||||
This function display a form which divided into two parts. The one list all modules which has installed
|
||||
This function display a form which divided into two parts. The one list all modules which has installed
|
||||
driver health protocol. The list usually contain driver name, controller name, and it's health info.
|
||||
While the driver name can't be retrieved, will use device path as backup. The other part of the form provide
|
||||
a choice to the user to repair all platform.
|
||||
@@ -1251,7 +1251,7 @@ CallDriverHealth (
|
||||
VOID
|
||||
)
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
EFI_STATUS Status;
|
||||
EFI_HII_HANDLE HiiHandle;
|
||||
EFI_BROWSER_ACTION_REQUEST ActionRequest;
|
||||
EFI_IFR_GUID_LABEL *StartLabel;
|
||||
@@ -1278,7 +1278,7 @@ CallDriverHealth (
|
||||
UINTN StringSize;
|
||||
|
||||
Index = 0;
|
||||
DriverHealthInfo = NULL;
|
||||
DriverHealthInfo = NULL;
|
||||
DriverDevicePath = NULL;
|
||||
IsControllerNameEmpty = FALSE;
|
||||
InitializeListHead (&DriverHealthList);
|
||||
@@ -1352,8 +1352,8 @@ CallDriverHealth (
|
||||
|
||||
Link = GetFirstNode (&DriverHealthList);
|
||||
|
||||
while (!IsNull (&DriverHealthList, Link)) {
|
||||
DriverHealthInfo = DEVICE_MANAGER_HEALTH_INFO_FROM_LINK (Link);
|
||||
while (!IsNull (&DriverHealthList, Link)) {
|
||||
DriverHealthInfo = DEVICE_MANAGER_HEALTH_INFO_FROM_LINK (Link);
|
||||
|
||||
Status = DriverHealthGetDriverName (DriverHealthInfo->DriverHandle, &DriverName);
|
||||
if (EFI_ERROR (Status)) {
|
||||
@@ -1366,9 +1366,9 @@ CallDriverHealth (
|
||||
StringSize = StrSize (DriverName);
|
||||
|
||||
Status = DriverHealthGetControllerName (
|
||||
DriverHealthInfo->DriverHandle,
|
||||
DriverHealthInfo->ControllerHandle,
|
||||
DriverHealthInfo->ChildHandle,
|
||||
DriverHealthInfo->DriverHandle,
|
||||
DriverHealthInfo->ControllerHandle,
|
||||
DriverHealthInfo->ChildHandle,
|
||||
&ControllerName
|
||||
);
|
||||
|
||||
@@ -1379,24 +1379,24 @@ CallDriverHealth (
|
||||
} else {
|
||||
IsControllerNameEmpty = TRUE;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Add the message of the Module itself provided after the string item.
|
||||
//
|
||||
if ((DriverHealthInfo->MessageList != NULL) && (DriverHealthInfo->MessageList->StringId != 0)) {
|
||||
TmpString = HiiGetString (
|
||||
DriverHealthInfo->MessageList->HiiHandle,
|
||||
DriverHealthInfo->MessageList->StringId,
|
||||
DriverHealthInfo->MessageList->HiiHandle,
|
||||
DriverHealthInfo->MessageList->StringId,
|
||||
NULL
|
||||
);
|
||||
ASSERT (TmpString != NULL);
|
||||
|
||||
|
||||
StringSize += StrLen (L" ") * sizeof(CHAR16);
|
||||
StringSize += StrLen (TmpString) * sizeof(CHAR16);
|
||||
|
||||
String = (EFI_STRING) AllocateZeroPool (StringSize);
|
||||
ASSERT (String != NULL);
|
||||
|
||||
|
||||
StrCpyS (String, StringSize / sizeof(CHAR16), DriverName);
|
||||
if (!IsControllerNameEmpty) {
|
||||
StrCatS (String, StringSize / sizeof(CHAR16), L" ");
|
||||
@@ -1436,7 +1436,7 @@ CallDriverHealth (
|
||||
|
||||
String = (EFI_STRING) AllocateZeroPool (StringSize);
|
||||
ASSERT (String != NULL);
|
||||
|
||||
|
||||
StrCpyS (String, StringSize / sizeof (CHAR16), DriverName);
|
||||
if (!IsControllerNameEmpty) {
|
||||
StrCatS (String, StringSize / sizeof (CHAR16), L" ");
|
||||
@@ -1464,14 +1464,14 @@ CallDriverHealth (
|
||||
Index++;
|
||||
Link = GetNextNode (&DriverHealthList, Link);
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Add End Opcode for Subtitle
|
||||
//
|
||||
//
|
||||
HiiCreateEndOpCode (StartOpCodeHandle);
|
||||
|
||||
HiiCreateSubTitleOpCode (StartOpCodeHandleRepair, STRING_TOKEN (STR_DRIVER_HEALTH_REPAIR_ALL), 0, 0, 1);
|
||||
TokenHelp = HiiSetString (HiiHandle, 0, GetStringById( STRING_TOKEN (STR_DH_REPAIR_ALL_HELP)), NULL);
|
||||
TokenHelp = HiiSetString (HiiHandle, 0, GetStringById( STRING_TOKEN (STR_DH_REPAIR_ALL_HELP)), NULL);
|
||||
|
||||
if (PlaformHealthStatusCheck ()) {
|
||||
//
|
||||
@@ -1541,7 +1541,7 @@ CallDriverHealth (
|
||||
// We will have returned from processing a callback - user either hit ESC to exit, or selected
|
||||
// a target to display.
|
||||
// Process the diver health status states here.
|
||||
//
|
||||
//
|
||||
if (gCallbackKey >= DRIVER_HEALTH_KEY_OFFSET && gCallbackKey != DRIVER_HEALTH_REPAIR_ALL_KEY) {
|
||||
ActionRequest = EFI_BROWSER_ACTION_REQUEST_NONE;
|
||||
|
||||
@@ -1552,7 +1552,7 @@ CallDriverHealth (
|
||||
//
|
||||
// Got the item relative node in the List
|
||||
//
|
||||
if (Index == (gCallbackKey - DRIVER_HEALTH_KEY_OFFSET)) {
|
||||
if (Index == (gCallbackKey - DRIVER_HEALTH_KEY_OFFSET)) {
|
||||
DriverHealthInfo = DEVICE_MANAGER_HEALTH_INFO_FROM_LINK (Link);
|
||||
//
|
||||
// Process the driver's healthy status for the specify module
|
||||
@@ -1560,7 +1560,7 @@ CallDriverHealth (
|
||||
RebootRequired = FALSE;
|
||||
ProcessSingleControllerHealth (
|
||||
DriverHealthInfo->DriverHealth,
|
||||
DriverHealthInfo->ControllerHandle,
|
||||
DriverHealthInfo->ControllerHandle,
|
||||
DriverHealthInfo->ChildHandle,
|
||||
DriverHealthInfo->HealthStatus,
|
||||
&(DriverHealthInfo->MessageList),
|
||||
@@ -1579,9 +1579,9 @@ CallDriverHealth (
|
||||
if (ActionRequest == EFI_BROWSER_ACTION_REQUEST_RESET) {
|
||||
EnableResetRequired ();
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Force return to the form of Driver Health in Device Manager
|
||||
// Force return to the form of Driver Health in Device Manager
|
||||
//
|
||||
gCallbackKey = DRIVER_HEALTH_RETURN_KEY;
|
||||
}
|
||||
@@ -1591,12 +1591,12 @@ CallDriverHealth (
|
||||
//
|
||||
if (gCallbackKey == DRIVER_HEALTH_REPAIR_ALL_KEY) {
|
||||
ActionRequest = EFI_BROWSER_ACTION_REQUEST_NONE;
|
||||
|
||||
|
||||
PlatformRepairAll (&DriverHealthList);
|
||||
|
||||
gCallbackKey = DRIVER_HEALTH_RETURN_KEY;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Remove driver health packagelist from HII database.
|
||||
//
|
||||
@@ -1615,13 +1615,13 @@ CallDriverHealth (
|
||||
if (DriverHealthInfo->MessageList != NULL) {
|
||||
FreePool(DriverHealthInfo->MessageList);
|
||||
FreePool (DriverHealthInfo);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
HiiFreeOpCodeHandle (StartOpCodeHandle);
|
||||
HiiFreeOpCodeHandle (EndOpCodeHandle);
|
||||
HiiFreeOpCodeHandle (EndOpCodeHandle);
|
||||
HiiFreeOpCodeHandle (StartOpCodeHandleRepair);
|
||||
HiiFreeOpCodeHandle (EndOpCodeHandleRepair);
|
||||
HiiFreeOpCodeHandle (EndOpCodeHandleRepair);
|
||||
|
||||
if (gCallbackKey == DRIVER_HEALTH_RETURN_KEY) {
|
||||
//
|
||||
@@ -1639,11 +1639,11 @@ CallDriverHealth (
|
||||
This function called by CheckAllControllersHealthStatus () function in order to process a specify
|
||||
contoller's health state.
|
||||
|
||||
@param DriverHealthList A Pointer to the list contain all of the platform driver health information.
|
||||
@param DriverHealthList A Pointer to the list contain all of the platform driver health information.
|
||||
@param DriverHandle The handle of driver.
|
||||
@param ControllerHandle The class guid specifies which form set will be displayed.
|
||||
@param ChildHandle The handle of the child controller to retrieve the health
|
||||
status on. This is an optional parameter that may be NULL.
|
||||
@param ChildHandle The handle of the child controller to retrieve the health
|
||||
status on. This is an optional parameter that may be NULL.
|
||||
@param DriverHealth A pointer to the EFI_DRIVER_HEALTH_PROTOCOL instance.
|
||||
@param HealthStatus The health status of the controller.
|
||||
|
||||
@@ -1740,7 +1740,7 @@ GetSingleControllerHealthStatus (
|
||||
return EFI_OUT_OF_RESOURCES;
|
||||
}
|
||||
|
||||
DriverHealthInfo->Signature = DEVICE_MANAGER_DRIVER_HEALTH_INFO_SIGNATURE;
|
||||
DriverHealthInfo->Signature = DEVICE_MANAGER_DRIVER_HEALTH_INFO_SIGNATURE;
|
||||
DriverHealthInfo->DriverHandle = DriverHandle;
|
||||
DriverHealthInfo->ControllerHandle = ControllerHandle;
|
||||
DriverHealthInfo->ChildHandle = ChildHandle;
|
||||
@@ -1755,12 +1755,12 @@ GetSingleControllerHealthStatus (
|
||||
}
|
||||
|
||||
/**
|
||||
Collects all the EFI Driver Health Protocols currently present in the EFI Handle Database,
|
||||
and queries each EFI Driver Health Protocol to determine if one or more of the controllers
|
||||
managed by each EFI Driver Health Protocol instance are not healthy.
|
||||
Collects all the EFI Driver Health Protocols currently present in the EFI Handle Database,
|
||||
and queries each EFI Driver Health Protocol to determine if one or more of the controllers
|
||||
managed by each EFI Driver Health Protocol instance are not healthy.
|
||||
|
||||
@param DriverHealthList A Pointer to the list contain all of the platform driver health
|
||||
information.
|
||||
information.
|
||||
|
||||
@retval EFI_NOT_FOUND No controller in the platform install Driver Health Protocol.
|
||||
@retval EFI_SUCCESS All the controllers in the platform are healthy.
|
||||
@@ -1772,7 +1772,7 @@ GetAllControllersHealthStatus (
|
||||
IN OUT LIST_ENTRY *DriverHealthList
|
||||
)
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
EFI_STATUS Status;
|
||||
UINTN NumHandles;
|
||||
EFI_HANDLE *DriverHealthHandles;
|
||||
EFI_DRIVER_HEALTH_PROTOCOL *DriverHealth;
|
||||
@@ -1782,7 +1782,7 @@ GetAllControllersHealthStatus (
|
||||
UINTN HandleCount;
|
||||
UINTN ControllerIndex;
|
||||
UINTN ChildIndex;
|
||||
|
||||
|
||||
//
|
||||
// Initialize local variables
|
||||
//
|
||||
@@ -1810,7 +1810,7 @@ GetAllControllersHealthStatus (
|
||||
|
||||
if (EFI_ERROR (Status) || DriverHealthHandles == NULL) {
|
||||
//
|
||||
// If the list of Driver Health Protocol handles can not be retrieved, then
|
||||
// If the list of Driver Health Protocol handles can not be retrieved, then
|
||||
// return EFI_OUT_OF_RESOURCES
|
||||
//
|
||||
return EFI_OUT_OF_RESOURCES;
|
||||
@@ -1831,7 +1831,7 @@ GetAllControllersHealthStatus (
|
||||
//
|
||||
// Retrieve the Driver Health Protocol from DriverHandle
|
||||
//
|
||||
Status = gBS->HandleProtocol (
|
||||
Status = gBS->HandleProtocol (
|
||||
DriverHealthHandles[DriverHealthIndex],
|
||||
&gEfiDriverHealthProtocolGuid,
|
||||
(VOID **)&DriverHealth
|
||||
@@ -1858,7 +1858,7 @@ GetAllControllersHealthStatus (
|
||||
}
|
||||
|
||||
//
|
||||
// If all the controllers managed by this Driver Health Protocol are healthy, then skip to the next
|
||||
// If all the controllers managed by this Driver Health Protocol are healthy, then skip to the next
|
||||
// Driver Health Protocol handle
|
||||
//
|
||||
if (HealthStatus == EfiDriverHealthStatusHealthy) {
|
||||
@@ -1882,7 +1882,7 @@ GetAllControllersHealthStatus (
|
||||
);
|
||||
if (EFI_ERROR (Status) || Handles == NULL) {
|
||||
//
|
||||
// If all the handles in the handle database can not be retrieved, then
|
||||
// If all the handles in the handle database can not be retrieved, then
|
||||
// return EFI_OUT_OF_RESOURCES
|
||||
//
|
||||
Status = EFI_OUT_OF_RESOURCES;
|
||||
@@ -1959,7 +1959,7 @@ Done:
|
||||
|
||||
|
||||
/**
|
||||
Check the healthy status of the platform, this function will return immediately while found one driver
|
||||
Check the healthy status of the platform, this function will return immediately while found one driver
|
||||
in the platform are not healthy.
|
||||
|
||||
@retval FALSE at least one driver in the platform are not healthy.
|
||||
@@ -2002,13 +2002,13 @@ PlaformHealthStatusCheck (
|
||||
}
|
||||
//
|
||||
// Assume all modules are healthy.
|
||||
//
|
||||
//
|
||||
AllHealthy = TRUE;
|
||||
|
||||
//
|
||||
// Found one or more Handles.
|
||||
//
|
||||
if (!EFI_ERROR (Status)) {
|
||||
if (!EFI_ERROR (Status)) {
|
||||
for (Index = 0; Index < NoHandles; Index++) {
|
||||
Status = gBS->HandleProtocol (
|
||||
DriverHealthHandles[Index],
|
||||
@@ -2033,7 +2033,7 @@ PlaformHealthStatusCheck (
|
||||
//
|
||||
// Return immediately one driver's status not in healthy.
|
||||
//
|
||||
return FALSE;
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -2042,20 +2042,20 @@ PlaformHealthStatusCheck (
|
||||
}
|
||||
|
||||
/**
|
||||
Processes a single controller using the EFI Driver Health Protocol associated with
|
||||
Processes a single controller using the EFI Driver Health Protocol associated with
|
||||
that controller. This algorithm continues to query the GetHealthStatus() service until
|
||||
one of the legal terminal states of the EFI Driver Health Protocol is reached. This may
|
||||
one of the legal terminal states of the EFI Driver Health Protocol is reached. This may
|
||||
require the processing of HII Messages, HII Form, and invocation of repair operations.
|
||||
|
||||
@param DriverHealth A pointer to the EFI_DRIVER_HEALTH_PROTOCOL instance.
|
||||
@param ControllerHandle The class guid specifies which form set will be displayed.
|
||||
@param ChildHandle The handle of the child controller to retrieve the health
|
||||
status on. This is an optional parameter that may be NULL.
|
||||
@param ChildHandle The handle of the child controller to retrieve the health
|
||||
status on. This is an optional parameter that may be NULL.
|
||||
@param HealthStatus The health status of the controller.
|
||||
@param MessageList An array of warning or error messages associated
|
||||
with the controller specified by ControllerHandle and
|
||||
@param MessageList An array of warning or error messages associated
|
||||
with the controller specified by ControllerHandle and
|
||||
ChildHandle. This is an optional parameter that may be NULL.
|
||||
@param FormHiiHandle The HII handle for an HII form associated with the
|
||||
@param FormHiiHandle The HII handle for an HII form associated with the
|
||||
controller specified by ControllerHandle and ChildHandle.
|
||||
@param RebootRequired Indicate whether a reboot is required to repair the controller.
|
||||
**/
|
||||
@@ -2072,11 +2072,11 @@ ProcessSingleControllerHealth (
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
EFI_DRIVER_HEALTH_STATUS LocalHealthStatus;
|
||||
|
||||
|
||||
LocalHealthStatus = HealthStatus;
|
||||
//
|
||||
// If the module need to be repaired or reconfiguration, will process it until
|
||||
// reach a terminal status. The status from EfiDriverHealthStatusRepairRequired after repair
|
||||
// reach a terminal status. The status from EfiDriverHealthStatusRepairRequired after repair
|
||||
// will be in (Health, Failed, Configuration Required).
|
||||
//
|
||||
while(LocalHealthStatus == EfiDriverHealthStatusConfigurationRequired ||
|
||||
@@ -2091,9 +2091,9 @@ ProcessSingleControllerHealth (
|
||||
);
|
||||
}
|
||||
//
|
||||
// Via a form of the driver need to do configuration provided to process of status in
|
||||
// Via a form of the driver need to do configuration provided to process of status in
|
||||
// EfiDriverHealthStatusConfigurationRequired. The status after configuration should be in
|
||||
// (Healthy, Reboot Required, Failed, Reconnect Required, Repair Required).
|
||||
// (Healthy, Reboot Required, Failed, Reconnect Required, Repair Required).
|
||||
//
|
||||
if (LocalHealthStatus == EfiDriverHealthStatusConfigurationRequired) {
|
||||
if (FormHiiHandle != NULL) {
|
||||
@@ -2127,9 +2127,9 @@ ProcessSingleControllerHealth (
|
||||
|
||||
if (*MessageList != NULL) {
|
||||
ProcessMessages (*MessageList);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Health status in {Healthy, Failed} may also have Messages need to process
|
||||
//
|
||||
@@ -2144,7 +2144,7 @@ ProcessSingleControllerHealth (
|
||||
if (LocalHealthStatus == EfiDriverHealthStatusRebootRequired) {
|
||||
*RebootRequired = TRUE;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Do reconnect if need.
|
||||
//
|
||||
@@ -2165,11 +2165,11 @@ ProcessSingleControllerHealth (
|
||||
/**
|
||||
Reports the progress of a repair operation.
|
||||
|
||||
@param[in] Value A value between 0 and Limit that identifies the current
|
||||
@param[in] Value A value between 0 and Limit that identifies the current
|
||||
progress of the repair operation.
|
||||
|
||||
@param[in] Limit The maximum value of Value for the current repair operation.
|
||||
For example, a driver that wants to specify progress in
|
||||
For example, a driver that wants to specify progress in
|
||||
percent would use a Limit value of 100.
|
||||
|
||||
@retval EFI_SUCCESS The progress of a repair operation is reported successfully.
|
||||
@@ -2197,7 +2197,7 @@ RepairNotify (
|
||||
Processes a set of messages returned by the GetHealthStatus ()
|
||||
service of the EFI Driver Health Protocol
|
||||
|
||||
@param MessageList The MessageList point to messages need to processed.
|
||||
@param MessageList The MessageList point to messages need to processed.
|
||||
|
||||
**/
|
||||
VOID
|
||||
@@ -2219,9 +2219,9 @@ ProcessMessages (
|
||||
);
|
||||
if (MessageString != NULL) {
|
||||
//
|
||||
// User can customize the output. Just simply print out the MessageString like below.
|
||||
// User can customize the output. Just simply print out the MessageString like below.
|
||||
// Also can use the HiiHandle to display message on the front page.
|
||||
//
|
||||
//
|
||||
// Print(L"%s\n",MessageString);
|
||||
// gBS->Stall (100000);
|
||||
}
|
||||
@@ -2233,7 +2233,7 @@ ProcessMessages (
|
||||
Repair the whole platform.
|
||||
|
||||
This function is the main entry for user choose "Repair All" in the front page.
|
||||
It will try to do recovery job till all the driver health protocol installed modules
|
||||
It will try to do recovery job till all the driver health protocol installed modules
|
||||
reach a terminal state.
|
||||
|
||||
@param DriverHealthList A Pointer to the list contain all of the platform driver health
|
||||
@@ -2244,7 +2244,7 @@ VOID
|
||||
PlatformRepairAll (
|
||||
IN LIST_ENTRY *DriverHealthList
|
||||
)
|
||||
{
|
||||
{
|
||||
DRIVER_HEALTH_INFO *DriverHealthInfo;
|
||||
LIST_ENTRY *Link;
|
||||
BOOLEAN RebootRequired;
|
||||
@@ -2263,7 +2263,7 @@ PlatformRepairAll (
|
||||
//
|
||||
ASSERT (DriverHealthInfo != NULL);
|
||||
|
||||
ProcessSingleControllerHealth (
|
||||
ProcessSingleControllerHealth (
|
||||
DriverHealthInfo->DriverHealth,
|
||||
DriverHealthInfo->ControllerHandle,
|
||||
DriverHealthInfo->ChildHandle,
|
||||
@@ -2281,22 +2281,22 @@ PlatformRepairAll (
|
||||
|
||||
/**
|
||||
|
||||
Select the best matching language according to front page policy for best user experience.
|
||||
|
||||
This function supports both ISO 639-2 and RFC 4646 language codes, but language
|
||||
code types may not be mixed in a single call to this function.
|
||||
Select the best matching language according to front page policy for best user experience.
|
||||
|
||||
This function supports both ISO 639-2 and RFC 4646 language codes, but language
|
||||
code types may not be mixed in a single call to this function.
|
||||
|
||||
@param SupportedLanguages A pointer to a Null-terminated ASCII string that
|
||||
contains a set of language codes in the format
|
||||
contains a set of language codes in the format
|
||||
specified by Iso639Language.
|
||||
@param Iso639Language If TRUE, then all language codes are assumed to be
|
||||
in ISO 639-2 format. If FALSE, then all language
|
||||
codes are assumed to be in RFC 4646 language format.
|
||||
|
||||
@retval NULL The best matching language could not be found in SupportedLanguages.
|
||||
@retval NULL There are not enough resources available to return the best matching
|
||||
@retval NULL There are not enough resources available to return the best matching
|
||||
language.
|
||||
@retval Other A pointer to a Null-terminated ASCII string that is the best matching
|
||||
@retval Other A pointer to a Null-terminated ASCII string that is the best matching
|
||||
language in SupportedLanguages.
|
||||
**/
|
||||
CHAR8 *
|
||||
@@ -2334,7 +2334,7 @@ DriverHealthSelectBestLanguage (
|
||||
@param ProtocolGuid A pointer to an EFI_GUID. It points to Component Name (2) protocol GUID.
|
||||
@param DriverBindingHandle The handle on which the Component Name (2) protocol instance is retrieved.
|
||||
@param ComponentName A pointer to the Component Name (2) protocol interface.
|
||||
@param SupportedLanguage The best suitable language that matches the SupportedLangues interface for the
|
||||
@param SupportedLanguage The best suitable language that matches the SupportedLangues interface for the
|
||||
located Component Name (2) instance.
|
||||
|
||||
@retval EFI_SUCCESS The Component Name (2) protocol instance is successfully located and we find
|
||||
@@ -2411,8 +2411,8 @@ GetDriverNameWorker (
|
||||
EFI_COMPONENT_NAME_PROTOCOL *ComponentName;
|
||||
|
||||
//
|
||||
// Retrieve Component Name (2) protocol instance on the driver binding handle and
|
||||
// find the best language this instance supports.
|
||||
// Retrieve Component Name (2) protocol instance on the driver binding handle and
|
||||
// find the best language this instance supports.
|
||||
//
|
||||
Status = GetComponentNameWorker (
|
||||
ProtocolGuid,
|
||||
@@ -2423,7 +2423,7 @@ GetDriverNameWorker (
|
||||
if (EFI_ERROR (Status)) {
|
||||
return Status;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Get the driver name from Component Name (2) protocol instance on the driver binging handle.
|
||||
//
|
||||
@@ -2433,7 +2433,7 @@ GetDriverNameWorker (
|
||||
DriverName
|
||||
);
|
||||
FreePool (BestLanguage);
|
||||
|
||||
|
||||
return Status;
|
||||
}
|
||||
|
||||
@@ -2442,7 +2442,7 @@ GetDriverNameWorker (
|
||||
This function gets driver name from Component Name 2 protocol interface and Component Name protocol interface
|
||||
in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the driver name.
|
||||
If the attempt fails, it then gets the driver name from EFI 1.1 Component Name protocol for backward
|
||||
compatibility support.
|
||||
compatibility support.
|
||||
|
||||
@param DriverBindingHandle The handle on which the Component Name (2) protocol instance is retrieved.
|
||||
@param DriverName A pointer to the Unicode string to return. This Unicode string is the name
|
||||
@@ -2483,7 +2483,7 @@ DriverHealthGetDriverName (
|
||||
This function gets controller name from Component Name 2 protocol interface and Component Name protocol interface
|
||||
in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name.
|
||||
If the attempt fails, it then gets the controller name from EFI 1.1 Component Name protocol for backward
|
||||
compatibility support.
|
||||
compatibility support.
|
||||
|
||||
@param ProtocolGuid A pointer to an EFI_GUID. It points to Component Name (2) protocol GUID.
|
||||
@param DriverBindingHandle The handle on which the Component Name (2) protocol instance is retrieved.
|
||||
@@ -2516,8 +2516,8 @@ GetControllerNameWorker (
|
||||
EFI_COMPONENT_NAME_PROTOCOL *ComponentName;
|
||||
|
||||
//
|
||||
// Retrieve Component Name (2) protocol instance on the driver binding handle and
|
||||
// find the best language this instance supports.
|
||||
// Retrieve Component Name (2) protocol instance on the driver binding handle and
|
||||
// find the best language this instance supports.
|
||||
//
|
||||
Status = GetComponentNameWorker (
|
||||
ProtocolGuid,
|
||||
@@ -2547,9 +2547,9 @@ GetControllerNameWorker (
|
||||
/**
|
||||
|
||||
This function gets controller name from Component Name 2 protocol interface and Component Name protocol interface
|
||||
in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name.
|
||||
in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name.
|
||||
If the attempt fails, it then gets the controller name from EFI 1.1 Component Name protocol for backward
|
||||
compatibility support.
|
||||
compatibility support.
|
||||
|
||||
@param DriverBindingHandle The handle on which the Component Name (2) protocol instance is retrieved.
|
||||
@param ControllerHandle The handle of a controller that the driver specified by This is managing.
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
The platform device manager reference implement
|
||||
|
||||
Copyright (c) 2004 - 2013, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -75,7 +75,7 @@ typedef struct {
|
||||
|
||||
EFI_DRIVER_HEALTH_PROTOCOL *DriverHealth;
|
||||
///
|
||||
/// Driver health messages of the specify Driver
|
||||
/// Driver health messages of the specify Driver
|
||||
///
|
||||
EFI_DRIVER_HEALTH_HII_MESSAGE *MessageList;
|
||||
|
||||
@@ -192,7 +192,7 @@ InitializeDeviceManager (
|
||||
|
||||
This function create the dynamic content for device manager. It includes
|
||||
section header for all class of devices, one-of opcode to set VBIOS.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS Operation is successful.
|
||||
@retval Other values if failed to clean up the dynamic content from HII
|
||||
database.
|
||||
@@ -210,11 +210,11 @@ CallDeviceManager (
|
||||
This function called by CheckAllControllersHealthStatus () function in order to process a specify
|
||||
contoller's health state.
|
||||
|
||||
@param DriverHealthList A Pointer to the list contain all of the platform driver health information.
|
||||
@param DriverHealthList A Pointer to the list contain all of the platform driver health information.
|
||||
@param DriverHandle The handle of driver.
|
||||
@param ControllerHandle The class guid specifies which form set will be displayed.
|
||||
@param ChildHandle The handle of the child controller to retrieve the health
|
||||
status on. This is an optional parameter that may be NULL.
|
||||
@param ChildHandle The handle of the child controller to retrieve the health
|
||||
status on. This is an optional parameter that may be NULL.
|
||||
@param DriverHealth A pointer to the EFI_DRIVER_HEALTH_PROTOCOL instance.
|
||||
@param HealthStatus The health status of the controller.
|
||||
|
||||
@@ -237,9 +237,9 @@ GetSingleControllerHealthStatus (
|
||||
);
|
||||
|
||||
/**
|
||||
Collects all the EFI Driver Health Protocols currently present in the EFI Handle Database,
|
||||
and queries each EFI Driver Health Protocol to determine if one or more of the controllers
|
||||
managed by each EFI Driver Health Protocol instance are not healthy.
|
||||
Collects all the EFI Driver Health Protocols currently present in the EFI Handle Database,
|
||||
and queries each EFI Driver Health Protocol to determine if one or more of the controllers
|
||||
managed by each EFI Driver Health Protocol instance are not healthy.
|
||||
|
||||
@param DriverHealthList A Pointer to the list contain all of the platform driver health
|
||||
information.
|
||||
@@ -255,7 +255,7 @@ GetAllControllersHealthStatus (
|
||||
);
|
||||
|
||||
/**
|
||||
Check the healthy status of the platform, this function will return immediately while found one driver
|
||||
Check the healthy status of the platform, this function will return immediately while found one driver
|
||||
in the platform are not healthy.
|
||||
|
||||
@retval FALSE at least one driver in the platform are not healthy.
|
||||
@@ -271,7 +271,7 @@ PlaformHealthStatusCheck (
|
||||
Repair the whole platform.
|
||||
|
||||
This function is the main entry for user choose "Repair All" in the front page.
|
||||
It will try to do recovery job till all the driver health protocol installed modules
|
||||
It will try to do recovery job till all the driver health protocol installed modules
|
||||
reach a terminal state.
|
||||
|
||||
@param DriverHealthList A Pointer to the list contain all of the platform driver health
|
||||
@@ -284,20 +284,20 @@ PlatformRepairAll (
|
||||
);
|
||||
|
||||
/**
|
||||
Processes a single controller using the EFI Driver Health Protocol associated with
|
||||
Processes a single controller using the EFI Driver Health Protocol associated with
|
||||
that controller. This algorithm continues to query the GetHealthStatus() service until
|
||||
one of the legal terminal states of the EFI Driver Health Protocol is reached. This may
|
||||
one of the legal terminal states of the EFI Driver Health Protocol is reached. This may
|
||||
require the processing of HII Messages, HII Form, and invocation of repair operations.
|
||||
|
||||
@param DriverHealth A pointer to the EFI_DRIVER_HEALTH_PROTOCOL instance.
|
||||
@param ControllerHandle The class guid specifies which form set will be displayed.
|
||||
@param ChildHandle The handle of the child controller to retrieve the health
|
||||
status on. This is an optional parameter that may be NULL.
|
||||
@param ChildHandle The handle of the child controller to retrieve the health
|
||||
status on. This is an optional parameter that may be NULL.
|
||||
@param HealthStatus The health status of the controller.
|
||||
@param MessageList An array of warning or error messages associated
|
||||
with the controller specified by ControllerHandle and
|
||||
@param MessageList An array of warning or error messages associated
|
||||
with the controller specified by ControllerHandle and
|
||||
ChildHandle. This is an optional parameter that may be NULL.
|
||||
@param FormHiiHandle The HII handle for an HII form associated with the
|
||||
@param FormHiiHandle The HII handle for an HII form associated with the
|
||||
controller specified by ControllerHandle and ChildHandle.
|
||||
@param RebootRequired Indicate whether a reboot is required to repair the controller.
|
||||
**/
|
||||
@@ -315,11 +315,11 @@ ProcessSingleControllerHealth (
|
||||
/**
|
||||
Reports the progress of a repair operation.
|
||||
|
||||
@param[in] Value A value between 0 and Limit that identifies the current
|
||||
@param[in] Value A value between 0 and Limit that identifies the current
|
||||
progress of the repair operation.
|
||||
|
||||
@param[in] Limit The maximum value of Value for the current repair operation.
|
||||
For example, a driver that wants to specify progress in
|
||||
For example, a driver that wants to specify progress in
|
||||
percent would use a Limit value of 100.
|
||||
|
||||
@retval EFI_SUCCESS The progress of a repair operation is reported successfully.
|
||||
@@ -336,7 +336,7 @@ RepairNotify (
|
||||
Processes a set of messages returned by the GetHealthStatus ()
|
||||
service of the EFI Driver Health Protocol
|
||||
|
||||
@param MessageList The MessageList point to messages need to processed.
|
||||
@param MessageList The MessageList point to messages need to processed.
|
||||
|
||||
**/
|
||||
VOID
|
||||
@@ -346,10 +346,10 @@ ProcessMessages (
|
||||
|
||||
|
||||
/**
|
||||
Collect and display the platform's driver health relative information, allow user to do interactive
|
||||
Collect and display the platform's driver health relative information, allow user to do interactive
|
||||
operation while the platform is unhealthy.
|
||||
|
||||
This function display a form which divided into two parts. The one list all modules which has installed
|
||||
This function display a form which divided into two parts. The one list all modules which has installed
|
||||
driver health protocol. The list usually contain driver name, controller name, and it's health info.
|
||||
While the driver name can't be retrieved, will use device path as backup. The other part of the form provide
|
||||
a choice to the user to repair all platform.
|
||||
@@ -362,22 +362,22 @@ CallDriverHealth (
|
||||
|
||||
/**
|
||||
|
||||
Select the best matching language according to front page policy for best user experience.
|
||||
|
||||
This function supports both ISO 639-2 and RFC 4646 language codes, but language
|
||||
code types may not be mixed in a single call to this function.
|
||||
Select the best matching language according to front page policy for best user experience.
|
||||
|
||||
This function supports both ISO 639-2 and RFC 4646 language codes, but language
|
||||
code types may not be mixed in a single call to this function.
|
||||
|
||||
@param SupportedLanguages A pointer to a Null-terminated ASCII string that
|
||||
contains a set of language codes in the format
|
||||
contains a set of language codes in the format
|
||||
specified by Iso639Language.
|
||||
@param Iso639Language If TRUE, then all language codes are assumed to be
|
||||
in ISO 639-2 format. If FALSE, then all language
|
||||
codes are assumed to be in RFC 4646 language format.
|
||||
|
||||
@retval NULL The best matching language could not be found in SupportedLanguages.
|
||||
@retval NULL There are not enough resources available to return the best matching
|
||||
@retval NULL There are not enough resources available to return the best matching
|
||||
language.
|
||||
@retval Other A pointer to a Null-terminated ASCII string that is the best matching
|
||||
@retval Other A pointer to a Null-terminated ASCII string that is the best matching
|
||||
language in SupportedLanguages.
|
||||
**/
|
||||
CHAR8 *
|
||||
@@ -394,7 +394,7 @@ DriverHealthSelectBestLanguage (
|
||||
@param ProtocolGuid A pointer to an EFI_GUID. It points to Component Name (2) protocol GUID.
|
||||
@param DriverBindingHandle The handle on which the Component Name (2) protocol instance is retrieved.
|
||||
@param ComponentName A pointer to the Component Name (2) protocol interface.
|
||||
@param SupportedLanguage The best suitable language that matches the SupportedLangues interface for the
|
||||
@param SupportedLanguage The best suitable language that matches the SupportedLangues interface for the
|
||||
located Component Name (2) instance.
|
||||
|
||||
@retval EFI_SUCCESS The Component Name (2) protocol instance is successfully located and we find
|
||||
@@ -440,7 +440,7 @@ GetDriverNameWorker (
|
||||
This function gets driver name from Component Name 2 protocol interface and Component Name protocol interface
|
||||
in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the driver name.
|
||||
If the attempt fails, it then gets the driver name from EFI 1.1 Component Name protocol for backward
|
||||
compatibility support.
|
||||
compatibility support.
|
||||
|
||||
@param DriverBindingHandle The handle on which the Component Name (2) protocol instance is retrieved.
|
||||
@param DriverName A pointer to the Unicode string to return. This Unicode string is the name
|
||||
@@ -462,7 +462,7 @@ DriverHealthGetDriverName (
|
||||
This function gets controller name from Component Name 2 protocol interface and Component Name protocol interface
|
||||
in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name.
|
||||
If the attempt fails, it then gets the controller name from EFI 1.1 Component Name protocol for backward
|
||||
compatibility support.
|
||||
compatibility support.
|
||||
|
||||
@param ProtocolGuid A pointer to an EFI_GUID. It points to Component Name (2) protocol GUID.
|
||||
@param DriverBindingHandle The handle on which the Component Name (2) protocol instance is retrieved.
|
||||
@@ -492,9 +492,9 @@ GetControllerNameWorker (
|
||||
|
||||
/**
|
||||
This function gets controller name from Component Name 2 protocol interface and Component Name protocol interface
|
||||
in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name.
|
||||
in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name.
|
||||
If the attempt fails, it then gets the controller name from EFI 1.1 Component Name protocol for backward
|
||||
compatibility support.
|
||||
compatibility support.
|
||||
|
||||
@param DriverBindingHandle The handle on which the Component Name (2) protocol instance is retrieved.
|
||||
@param ControllerHandle The handle of a controller that the driver specified by This is managing.
|
||||
|
@@ -1,16 +1,16 @@
|
||||
///** @file
|
||||
//
|
||||
//
|
||||
// String definitions for the Device Manager.
|
||||
//
|
||||
// Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
//
|
||||
//**/
|
||||
|
||||
/=#
|
||||
@@ -49,13 +49,13 @@
|
||||
#string STR_DH_STATUS_LIST #language en-US "All Driver Health Status List"
|
||||
#language fr-FR "All Driver Health Status List"
|
||||
#string STR_DRIVER_HEALTH_REPAIR_ALL #language en-US "Repair All"
|
||||
#language fr-FR "Repair All"
|
||||
#language fr-FR "Repair All"
|
||||
#string STR_DH_REPAIR_ALL_TITLE #language en-US "Repair the whole platform"
|
||||
#language fr-FR "Repair the whole platform"
|
||||
#string STR_DH_REPAIR_ALL_HELP #language en-US "Repair the whole platform until all modules reach terminal status"
|
||||
#language fr-FR "Repair the whole platform until all modules reach terminal status"
|
||||
#string STR_DH_REPAIR_SINGLE_TITLE #language en-US "Item cannot get name"
|
||||
#language fr-FR "Item cannot get name"
|
||||
#language fr-FR "Item cannot get name"
|
||||
#string STR_DH_REPAIR_SINGLE_HELP #language en-US "Repair single driver with specify controller"
|
||||
#language fr-FR "Repair single driver with specify controller"
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
FrontPage routines to handle the callbacks and browser calls
|
||||
|
||||
Copyright (c) 2004 - 2017, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -189,7 +189,7 @@ FrontPageCallback (
|
||||
//
|
||||
return EFI_UNSUPPORTED;
|
||||
}
|
||||
|
||||
|
||||
gCallbackKey = QuestionId;
|
||||
|
||||
if (Action == EFI_BROWSER_ACTION_CHANGED) {
|
||||
@@ -210,7 +210,7 @@ FrontPageCallback (
|
||||
// Allocate working buffer for RFC 4646 language in supported LanguageString.
|
||||
//
|
||||
Lang = AllocatePool (AsciiStrSize (mLanguageString));
|
||||
ASSERT (Lang != NULL);
|
||||
ASSERT (Lang != NULL);
|
||||
|
||||
Index = 0;
|
||||
LangCode = mLanguageString;
|
||||
@@ -279,7 +279,7 @@ FrontPageCallback (
|
||||
}
|
||||
}
|
||||
|
||||
return EFI_SUCCESS;
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -415,7 +415,7 @@ InitializeFrontPage (
|
||||
if (gFrontPagePrivate.LanguageToken == NULL) {
|
||||
//
|
||||
// Count the language list number.
|
||||
//
|
||||
//
|
||||
LangCode = mLanguageString;
|
||||
Lang = AllocatePool (AsciiStrSize (mLanguageString));
|
||||
ASSERT (Lang != NULL);
|
||||
@@ -739,7 +739,7 @@ UpdateFrontPageStrings (
|
||||
SMBIOS_TABLE_TYPE19 *Type19Record;
|
||||
EFI_SMBIOS_TABLE_HEADER *Record;
|
||||
UINT64 InstalledMemory;
|
||||
|
||||
|
||||
InstalledMemory = 0;
|
||||
|
||||
//
|
||||
@@ -906,7 +906,7 @@ ShowProgress (
|
||||
SetMem (&Foreground, sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL), 0xff);
|
||||
SetMem (&Background, sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL), 0x0);
|
||||
SetMem (&Color, sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL), 0xff);
|
||||
|
||||
|
||||
TmpStr = GetStringById (STRING_TOKEN (STR_START_BOOT_OPTION));
|
||||
|
||||
if (!FeaturePcdGet(PcdBootlogoOnlyEnable)) {
|
||||
@@ -917,7 +917,7 @@ ShowProgress (
|
||||
PlatformBdsShowProgress (Foreground, Background, TmpStr, Color, 0, 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
TimeoutRemain = TimeoutDefault;
|
||||
while (TimeoutRemain != 0) {
|
||||
@@ -928,7 +928,7 @@ ShowProgress (
|
||||
break;
|
||||
}
|
||||
TimeoutRemain--;
|
||||
|
||||
|
||||
if (!FeaturePcdGet(PcdBootlogoOnlyEnable)) {
|
||||
//
|
||||
// Show progress
|
||||
@@ -945,7 +945,7 @@ ShowProgress (
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (TmpStr != NULL) {
|
||||
gBS->FreePool (TmpStr);
|
||||
}
|
||||
@@ -997,7 +997,7 @@ PlatformBdsEnterFrontPage (
|
||||
)
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
EFI_STATUS StatusHotkey;
|
||||
EFI_STATUS StatusHotkey;
|
||||
EFI_BOOT_LOGO_PROTOCOL *BootLogo;
|
||||
EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput;
|
||||
EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *SimpleTextOut;
|
||||
@@ -1020,7 +1020,7 @@ PlatformBdsEnterFrontPage (
|
||||
|
||||
if (!mModeInitialized) {
|
||||
//
|
||||
// After the console is ready, get current video resolution
|
||||
// After the console is ready, get current video resolution
|
||||
// and text mode before launching setup at first time.
|
||||
//
|
||||
Status = gBS->HandleProtocol (
|
||||
@@ -1031,7 +1031,7 @@ PlatformBdsEnterFrontPage (
|
||||
if (EFI_ERROR (Status)) {
|
||||
GraphicsOutput = NULL;
|
||||
}
|
||||
|
||||
|
||||
Status = gBS->HandleProtocol (
|
||||
gST->ConsoleOutHandle,
|
||||
&gEfiSimpleTextOutProtocolGuid,
|
||||
@@ -1039,7 +1039,7 @@ PlatformBdsEnterFrontPage (
|
||||
);
|
||||
if (EFI_ERROR (Status)) {
|
||||
SimpleTextOut = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
if (GraphicsOutput != NULL) {
|
||||
//
|
||||
@@ -1062,9 +1062,9 @@ PlatformBdsEnterFrontPage (
|
||||
|
||||
//
|
||||
// Get user defined text mode for setup.
|
||||
//
|
||||
//
|
||||
mSetupHorizontalResolution = PcdGet32 (PcdSetupVideoHorizontalResolution);
|
||||
mSetupVerticalResolution = PcdGet32 (PcdSetupVideoVerticalResolution);
|
||||
mSetupVerticalResolution = PcdGet32 (PcdSetupVideoVerticalResolution);
|
||||
mSetupTextModeColumn = PcdGet32 (PcdSetupConOutColumn);
|
||||
mSetupTextModeRow = PcdGet32 (PcdSetupConOutRow);
|
||||
|
||||
@@ -1091,7 +1091,7 @@ PlatformBdsEnterFrontPage (
|
||||
if (!EFI_ERROR(Status) && ((OsIndication & EFI_OS_INDICATIONS_BOOT_TO_FW_UI) != 0)) {
|
||||
//
|
||||
// Clear EFI_OS_INDICATIONS_BOOT_TO_FW_UI to acknowledge OS
|
||||
//
|
||||
//
|
||||
OsIndication &= ~((UINT64)EFI_OS_INDICATIONS_BOOT_TO_FW_UI);
|
||||
Status = gRT->SetVariable (
|
||||
L"OsIndications",
|
||||
@@ -1128,7 +1128,7 @@ PlatformBdsEnterFrontPage (
|
||||
if (!FeaturePcdGet(PcdBootlogoOnlyEnable) || !EFI_ERROR(Status) || !EFI_ERROR(StatusHotkey)){
|
||||
//
|
||||
// Ensure screen is clear when switch Console from Graphics mode to Text mode
|
||||
// Skip it in normal boot
|
||||
// Skip it in normal boot
|
||||
//
|
||||
gST->ConOut->EnableCursor (gST->ConOut, TRUE);
|
||||
gST->ConOut->ClearScreen (gST->ConOut);
|
||||
@@ -1152,8 +1152,8 @@ PlatformBdsEnterFrontPage (
|
||||
}
|
||||
|
||||
//
|
||||
// Install BM HiiPackages.
|
||||
// Keep BootMaint HiiPackage, so that it can be covered by global setting.
|
||||
// Install BM HiiPackages.
|
||||
// Keep BootMaint HiiPackage, so that it can be covered by global setting.
|
||||
//
|
||||
InitBMPackage ();
|
||||
|
||||
@@ -1163,7 +1163,7 @@ PlatformBdsEnterFrontPage (
|
||||
// Set proper video resolution and text mode for setup
|
||||
//
|
||||
BdsSetConsoleMode (TRUE);
|
||||
|
||||
|
||||
InitializeFrontPage (FALSE);
|
||||
|
||||
//
|
||||
@@ -1272,9 +1272,9 @@ Exit:
|
||||
|
||||
/**
|
||||
This function will change video resolution and text mode
|
||||
according to defined setup mode or defined boot mode
|
||||
according to defined setup mode or defined boot mode
|
||||
|
||||
@param IsSetupMode Indicate mode is changed to setup mode or boot mode.
|
||||
@param IsSetupMode Indicate mode is changed to setup mode or boot mode.
|
||||
|
||||
@retval EFI_SUCCESS Mode is changed successfully.
|
||||
@retval Others Mode failed to be changed.
|
||||
@@ -1302,13 +1302,13 @@ BdsSetConsoleMode (
|
||||
EFI_STATUS Status;
|
||||
UINTN Index;
|
||||
UINTN CurrentColumn;
|
||||
UINTN CurrentRow;
|
||||
UINTN CurrentRow;
|
||||
|
||||
MaxGopMode = 0;
|
||||
MaxTextMode = 0;
|
||||
|
||||
//
|
||||
// Get current video resolution and text mode
|
||||
// Get current video resolution and text mode
|
||||
//
|
||||
Status = gBS->HandleProtocol (
|
||||
gST->ConsoleOutHandle,
|
||||
@@ -1326,7 +1326,7 @@ BdsSetConsoleMode (
|
||||
);
|
||||
if (EFI_ERROR (Status)) {
|
||||
SimpleTextOut = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
if ((GraphicsOutput == NULL) || (SimpleTextOut == NULL)) {
|
||||
return EFI_UNSUPPORTED;
|
||||
@@ -1347,12 +1347,12 @@ BdsSetConsoleMode (
|
||||
NewHorizontalResolution = mBootHorizontalResolution;
|
||||
NewVerticalResolution = mBootVerticalResolution;
|
||||
NewColumns = mBootTextModeColumn;
|
||||
NewRows = mBootTextModeRow;
|
||||
NewRows = mBootTextModeRow;
|
||||
}
|
||||
|
||||
|
||||
if (GraphicsOutput != NULL) {
|
||||
MaxGopMode = GraphicsOutput->Mode->MaxMode;
|
||||
}
|
||||
}
|
||||
|
||||
if (SimpleTextOut != NULL) {
|
||||
MaxTextMode = SimpleTextOut->Mode->MaxMode;
|
||||
@@ -1456,8 +1456,8 @@ BdsSetConsoleMode (
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
Status = PcdSet32S (PcdConOutRow, NewRows);
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
|
||||
|
||||
|
||||
|
||||
//
|
||||
// Video mode is changed, so restart graphics console driver and higher level driver.
|
||||
// Reconnect graphics console driver and higher level driver.
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
FrontPage routines to handle the callbacks and browser calls
|
||||
|
||||
Copyright (c) 2004 - 2012, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -236,9 +236,9 @@ PlatformBdsEnterFrontPage (
|
||||
|
||||
/**
|
||||
This function will change video resolution and text mode
|
||||
according to defined setup mode or defined boot mode
|
||||
according to defined setup mode or defined boot mode
|
||||
|
||||
@param IsSetupMode Indicate mode is changed to setup mode or boot mode.
|
||||
@param IsSetupMode Indicate mode is changed to setup mode or boot mode.
|
||||
|
||||
@retval EFI_SUCCESS Mode is changed successfully.
|
||||
@retval Others Mode failed to be changed.
|
||||
|
@@ -1,16 +1,16 @@
|
||||
///** @file
|
||||
//
|
||||
//
|
||||
// String definitions for BdsPlatform formset.
|
||||
//
|
||||
// Copyright (c) 2004 - 2013, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
//
|
||||
//**/
|
||||
|
||||
/=#
|
||||
|
@@ -2,7 +2,7 @@
|
||||
Provides a way for 3rd party applications to register themselves for launch by the
|
||||
Boot Manager based on hot key
|
||||
|
||||
Copyright (c) 2007 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -73,15 +73,15 @@ EFI_STATUS
|
||||
HotkeyBoot (
|
||||
VOID
|
||||
)
|
||||
{
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
UINTN ExitDataSize;
|
||||
CHAR16 *ExitData;
|
||||
|
||||
if (mHotkeyBootOption == NULL) {
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
BdsLibConnectDevicePath (mHotkeyBootOption->DevicePath);
|
||||
|
||||
//
|
||||
@@ -162,7 +162,7 @@ HotkeyCallback (
|
||||
HotkeyData = &Hotkey->KeyData[Hotkey->WaitingKey];
|
||||
if ((KeyData->Key.ScanCode == HotkeyData->Key.ScanCode) &&
|
||||
(KeyData->Key.UnicodeChar == HotkeyData->Key.UnicodeChar) &&
|
||||
(((KeyData->KeyState.KeyShiftState & EFI_SHIFT_STATE_VALID) != 0) ?
|
||||
(((KeyData->KeyState.KeyShiftState & EFI_SHIFT_STATE_VALID) != 0) ?
|
||||
(KeyData->KeyState.KeyShiftState == HotkeyData->KeyState.KeyShiftState) : TRUE
|
||||
)
|
||||
) {
|
||||
@@ -421,7 +421,7 @@ IsKeyOptionVariable (
|
||||
)
|
||||
{
|
||||
UINTN Index;
|
||||
|
||||
|
||||
if (!CompareGuid (Guid, &gEfiGlobalVariableGuid) ||
|
||||
(StrSize (Name) != sizeof (L"Key####")) ||
|
||||
(StrnCmp (Name, L"Key", 3) != 0)
|
||||
|
@@ -2,7 +2,7 @@
|
||||
Set the level of support for Hardware Error Record Persistence that is
|
||||
implemented by the platform.
|
||||
|
||||
Copyright (c) 2007 - 2013, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -28,9 +28,9 @@ InitializeHwErrRecSupport (
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
UINT16 HardwareErrorRecordLevel;
|
||||
|
||||
|
||||
HardwareErrorRecordLevel = PcdGet16 (PcdHardwareErrorRecordLevel);
|
||||
|
||||
|
||||
if (HardwareErrorRecordLevel != 0) {
|
||||
//
|
||||
// If level value equal 0, no need set to 0 to variable area because UEFI specification
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Language settings
|
||||
|
||||
Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -343,7 +343,7 @@ IsLangInSupportedLangCodes(
|
||||
IN CHAR8 *SupportedLang,
|
||||
IN CHAR8 *Lang,
|
||||
IN BOOLEAN Iso639Language
|
||||
)
|
||||
)
|
||||
{
|
||||
UINTN Index;
|
||||
UINTN CompareLength;
|
||||
@@ -375,8 +375,8 @@ IsLangInSupportedLangCodes(
|
||||
// Determine the length of the next language code in SupportedLang
|
||||
//
|
||||
for (CompareLength = 0; SupportedLang[CompareLength] != '\0' && SupportedLang[CompareLength] != ';'; CompareLength++);
|
||||
|
||||
if ((CompareLength == LanguageLength) &&
|
||||
|
||||
if ((CompareLength == LanguageLength) &&
|
||||
(AsciiStrnCmp (Lang, SupportedLang, CompareLength) == 0)) {
|
||||
//
|
||||
// Successfully find the Lang string in SupportedLang string.
|
||||
@@ -404,7 +404,7 @@ VOID
|
||||
InitializeLangVariable (
|
||||
IN CHAR16 *LangName,
|
||||
IN CHAR8 *SupportedLang,
|
||||
IN CHAR8 *DefaultLang,
|
||||
IN CHAR8 *DefaultLang,
|
||||
IN BOOLEAN Iso639Language
|
||||
)
|
||||
{
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Perform the platform memory test
|
||||
|
||||
Copyright (c) 2004 - 2017, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -282,7 +282,7 @@ BdsMemoryTest (
|
||||
FreePool (Pos);
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
if (!FeaturePcdGet(PcdBootlogoOnlyEnable)) {
|
||||
TmpStr = GetStringById (STRING_TOKEN (STR_ESC_TO_SKIP_MEM_TEST));
|
||||
|
||||
@@ -310,7 +310,7 @@ BdsMemoryTest (
|
||||
|
||||
ASSERT (0);
|
||||
}
|
||||
|
||||
|
||||
if (!FeaturePcdGet(PcdBootlogoOnlyEnable)) {
|
||||
TempData = (UINT32) DivU64x32 (TotalMemorySize, 16);
|
||||
TestPercent = (UINTN) DivU64x32 (
|
||||
@@ -326,7 +326,7 @@ BdsMemoryTest (
|
||||
//
|
||||
StrnCatS (
|
||||
StrPercent,
|
||||
sizeof (StrPercent) / sizeof (CHAR16),
|
||||
sizeof (StrPercent) / sizeof (CHAR16),
|
||||
TmpStr,
|
||||
sizeof (StrPercent) / sizeof (CHAR16) - StrLen (StrPercent) - 1
|
||||
);
|
||||
@@ -412,11 +412,11 @@ Done:
|
||||
100,
|
||||
(UINTN) PreviousValue
|
||||
);
|
||||
|
||||
|
||||
} else {
|
||||
DEBUG ((EFI_D_INFO, "%d bytes of system memory tested OK\r\n", TotalMemorySize));
|
||||
}
|
||||
|
||||
|
||||
FreePool (Pos);
|
||||
|
||||
|
||||
|
@@ -1,16 +1,16 @@
|
||||
///** @file
|
||||
//
|
||||
//
|
||||
// String definitions for BdsPlatform formset.
|
||||
//
|
||||
// Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
//
|
||||
//**/
|
||||
|
||||
/=#
|
||||
@@ -52,4 +52,4 @@
|
||||
#language fr-FR "le Système rencontre les erreurs de mémoire"
|
||||
#string STR_START_BOOT_OPTION #language en-US "Start boot option"
|
||||
#language fr-FR "l'option de botte de Début"
|
||||
|
||||
|
||||
|
@@ -1,14 +1,14 @@
|
||||
/** @file
|
||||
UEFI Component Name(2) protocol implementation for VGA Class Driver.
|
||||
UEFI Component Name(2) protocol implementation for VGA Class Driver.
|
||||
|
||||
Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
**/
|
||||
|
||||
|
@@ -1,14 +1,14 @@
|
||||
/** @file
|
||||
VGA Class Driver that managers VGA devices and produces Simple Text Output Protocol.
|
||||
|
||||
Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
**/
|
||||
|
||||
@@ -310,7 +310,7 @@ UNICODE_TO_CHAR UnicodeToPcAnsiOrAscii[] = {
|
||||
|
||||
@param ImageHandle The firmware allocated handle for the EFI image.
|
||||
@param SystemTable A pointer to the EFI System Table.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The entry point is executed successfully.
|
||||
|
||||
**/
|
||||
@@ -341,7 +341,7 @@ InitializeVgaClass(
|
||||
|
||||
/**
|
||||
Internal worker function to program CRTC register via PCI I/O Protocol.
|
||||
|
||||
|
||||
@param VgaClassDev device instance object
|
||||
@param Address Address of register to write
|
||||
@param Data Data to write to register.
|
||||
@@ -375,12 +375,12 @@ WriteCrtc (
|
||||
|
||||
/**
|
||||
Internal worker function to set cursor's position to VgaClass device
|
||||
|
||||
|
||||
@param VgaClassDev Private data structure for device instance.
|
||||
@param Column Colomn of position to set cursor to.
|
||||
@param Row Row of position to set cursor to.
|
||||
@param MaxColumn Max value of column.
|
||||
|
||||
|
||||
**/
|
||||
VOID
|
||||
SetVideoCursorPosition (
|
||||
@@ -461,7 +461,7 @@ LibIsValidTextGraphics (
|
||||
|
||||
/**
|
||||
Internal worker function to check whether input value is an ASCII char.
|
||||
|
||||
|
||||
@param Char Character to check.
|
||||
|
||||
@retval TRUE Input value is an ASCII char.
|
||||
@@ -482,7 +482,7 @@ IsValidAscii (
|
||||
|
||||
/**
|
||||
Internal worker function to check whether input value is a unicode control char.
|
||||
|
||||
|
||||
@param Char Character to check.
|
||||
|
||||
@retval TRUE Input value is a unicode control char.
|
||||
@@ -712,7 +712,7 @@ ErrorExit:
|
||||
|
||||
/**
|
||||
Starts the device controller.
|
||||
|
||||
|
||||
This function implments EFI_DRIVER_BINDING_PROTOCOL.Stop().
|
||||
It stops this driver on Controller. Support stopping any child handles
|
||||
created by this driver.
|
||||
@@ -798,7 +798,7 @@ VgaClassDriverBindingStop (
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.Reset().
|
||||
It resets the text output device hardware. The cursor position is set to (0, 0),
|
||||
and the screen is cleared to the default background color for the output device.
|
||||
|
||||
|
||||
@param This Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
|
||||
@param ExtendedVerification Indicates that the driver may perform a more exhaustive
|
||||
verification operation of the device during reset.
|
||||
@@ -837,7 +837,7 @@ VgaClassReset (
|
||||
|
||||
/**
|
||||
Writes a Unicode string to the output device.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.OutputString().
|
||||
It writes a Unicode string to the output device. This is the most basic output mechanism
|
||||
on an output device.
|
||||
@@ -977,7 +977,7 @@ VgaClassOutputString (
|
||||
|
||||
/**
|
||||
Verifies that all characters in a Unicode string can be output to the target device.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.TestString().
|
||||
It verifies that all characters in a Unicode string can be output to the target device.
|
||||
|
||||
@@ -1009,13 +1009,13 @@ VgaClassTestString (
|
||||
|
||||
/**
|
||||
Clears the output device(s) display to the currently selected background color.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.ClearScreen().
|
||||
The ClearScreen() function clears the output device(s) display to the currently
|
||||
selected background color. The cursor position is set to (0, 0).
|
||||
|
||||
@param This Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
|
||||
|
||||
|
||||
@retval EFI_SUCESS The operation completed successfully.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.
|
||||
@retval EFI_UNSUPPORTED The output device is not in a valid text mode.
|
||||
@@ -1063,7 +1063,7 @@ VgaClassClearScreen (
|
||||
|
||||
/**
|
||||
Sets the background and foreground colors for theOutputString() and ClearScreen() functions.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetAttribute().
|
||||
It sets the background and foreground colors for the OutputString() and ClearScreen() functions.
|
||||
The color mask can be set even when the device is in an invalid text mode.
|
||||
@@ -1074,7 +1074,7 @@ VgaClassClearScreen (
|
||||
@param Attribute The attribute to set.
|
||||
Bits 0..3 are the foreground color,
|
||||
and bits 4..6 are the background color.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The requested attributes were set.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.
|
||||
|
||||
@@ -1096,15 +1096,15 @@ VgaClassSetAttribute (
|
||||
|
||||
/**
|
||||
Sets the current coordinates of the cursor position.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetCursorPosition().
|
||||
It sets the current coordinates of the cursor position.
|
||||
The upper left corner of the screen is defined as coordinate (0, 0).
|
||||
|
||||
|
||||
@param This Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
|
||||
@param Column Column of position to set the cursor to.
|
||||
@param Row Row of position to set the cursor to.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The operation completed successfully.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.
|
||||
@retval EFI_UNSUPPORTED The output device is not in a valid text mode, or the cursor
|
||||
@@ -1150,14 +1150,14 @@ VgaClassSetCursorPosition (
|
||||
|
||||
/**
|
||||
Makes the cursor visible or invisible.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.EnableCursor().
|
||||
It makes the cursor visible or invisible.
|
||||
|
||||
@param This Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
|
||||
@param Visible If TRUE, the cursor is set to be visible.
|
||||
If FALSE, the cursor is set to be invisible.
|
||||
|
||||
|
||||
@retval EFI_SUCESS The operation completed successfully.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request or the
|
||||
device does not support changing the cursor mode.
|
||||
@@ -1208,7 +1208,7 @@ VgaClassEnableCursor (
|
||||
@param ModeNumber The mode number to return information on.
|
||||
@param Columns Columen in current mode number
|
||||
@param Rows Row in current mode number.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The requested mode information was returned.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.
|
||||
@retval EFI_UNSUPPORTED The mode number was not valid.
|
||||
@@ -1251,7 +1251,7 @@ VgaClassQueryMode (
|
||||
|
||||
/**
|
||||
Sets the output device(s) to a specified mode.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.QueryMode().
|
||||
It sets the output device(s) to the requested mode.
|
||||
On success the device is in the geometry for the requested mode,
|
||||
@@ -1259,7 +1259,7 @@ VgaClassQueryMode (
|
||||
|
||||
@param This Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
|
||||
@param ModeNumber The text mode to set.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The requested text mode was set.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.
|
||||
@retval EFI_UNSUPPORTED The mode number was not valid.
|
||||
|
@@ -1,14 +1,14 @@
|
||||
/** @file
|
||||
Internal include file of the VGA Class Driver.
|
||||
|
||||
Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
**/
|
||||
|
||||
@@ -132,7 +132,7 @@ VgaClassDriverBindingStart (
|
||||
|
||||
/**
|
||||
Starts the device controller.
|
||||
|
||||
|
||||
This function implments EFI_DRIVER_BINDING_PROTOCOL.Stop().
|
||||
It stops this driver on Controller. Support stopping any child handles
|
||||
created by this driver.
|
||||
@@ -278,7 +278,7 @@ VgaClassComponentNameGetControllerName (
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.Reset().
|
||||
It resets the text output device hardware. The cursor position is set to (0, 0),
|
||||
and the screen is cleared to the default background color for the output device.
|
||||
|
||||
|
||||
@param This Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
|
||||
@param ExtendedVerification Indicates that the driver may perform a more exhaustive
|
||||
verification operation of the device during reset.
|
||||
@@ -296,7 +296,7 @@ VgaClassReset (
|
||||
|
||||
/**
|
||||
Writes a Unicode string to the output device.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.OutputString().
|
||||
It writes a Unicode string to the output device. This is the most basic output mechanism
|
||||
on an output device.
|
||||
@@ -319,7 +319,7 @@ VgaClassOutputString (
|
||||
|
||||
/**
|
||||
Verifies that all characters in a Unicode string can be output to the target device.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.TestString().
|
||||
It verifies that all characters in a Unicode string can be output to the target device.
|
||||
|
||||
@@ -340,13 +340,13 @@ VgaClassTestString (
|
||||
|
||||
/**
|
||||
Clears the output device(s) display to the currently selected background color.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.ClearScreen().
|
||||
The ClearScreen() function clears the output device(s) display to the currently
|
||||
selected background color. The cursor position is set to (0, 0).
|
||||
|
||||
@param This Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
|
||||
|
||||
|
||||
@retval EFI_SUCESS The operation completed successfully.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.
|
||||
@retval EFI_UNSUPPORTED The output device is not in a valid text mode.
|
||||
@@ -360,7 +360,7 @@ VgaClassClearScreen (
|
||||
|
||||
/**
|
||||
Sets the background and foreground colors for theOutputString() and ClearScreen() functions.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetAttribute().
|
||||
It sets the background and foreground colors for the OutputString() and ClearScreen() functions.
|
||||
The color mask can be set even when the device is in an invalid text mode.
|
||||
@@ -371,7 +371,7 @@ VgaClassClearScreen (
|
||||
@param Attribute The attribute to set.
|
||||
Bits 0..3 are the foreground color,
|
||||
and bits 4..6 are the background color.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The requested attributes were set.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.
|
||||
|
||||
@@ -385,15 +385,15 @@ VgaClassSetAttribute (
|
||||
|
||||
/**
|
||||
Sets the current coordinates of the cursor position.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetCursorPosition().
|
||||
It sets the current coordinates of the cursor position.
|
||||
The upper left corner of the screen is defined as coordinate (0, 0).
|
||||
|
||||
|
||||
@param This Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
|
||||
@param Column Column of position to set the cursor to.
|
||||
@param Row Row of position to set the cursor to.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The operation completed successfully.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.
|
||||
@retval EFI_UNSUPPORTED The output device is not in a valid text mode, or the cursor
|
||||
@@ -410,14 +410,14 @@ VgaClassSetCursorPosition (
|
||||
|
||||
/**
|
||||
Makes the cursor visible or invisible.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.EnableCursor().
|
||||
It makes the cursor visible or invisible.
|
||||
|
||||
@param This Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
|
||||
@param Visible If TRUE, the cursor is set to be visible.
|
||||
If FALSE, the cursor is set to be invisible.
|
||||
|
||||
|
||||
@retval EFI_SUCESS The operation completed successfully.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request or the
|
||||
device does not support changing the cursor mode.
|
||||
@@ -443,7 +443,7 @@ VgaClassEnableCursor (
|
||||
@param ModeNumber The mode number to return information on.
|
||||
@param Columns Columen in current mode number
|
||||
@param Rows Row in current mode number.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The requested mode information was returned.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.
|
||||
@retval EFI_UNSUPPORTED The mode number was not valid.
|
||||
@@ -460,7 +460,7 @@ VgaClassQueryMode (
|
||||
|
||||
/**
|
||||
Sets the output device(s) to a specified mode.
|
||||
|
||||
|
||||
This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.QueryMode().
|
||||
It sets the output device(s) to the requested mode.
|
||||
On success the device is in the geometry for the requested mode,
|
||||
@@ -468,7 +468,7 @@ VgaClassQueryMode (
|
||||
|
||||
@param This Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
|
||||
@param ModeNumber The text mode to set.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The requested text mode was set.
|
||||
@retval EFI_DEVICE_ERROR The device had an error and could not complete the request.
|
||||
@retval EFI_UNSUPPORTED The mode number was not valid.
|
||||
|
@@ -1,15 +1,15 @@
|
||||
## @file
|
||||
# VGA Class Driver that managers VGA devices and produces Simple Text Output Protocol.
|
||||
#
|
||||
# Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
#
|
||||
# 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
|
||||
# http://opensource.org/licenses/bsd-license.php
|
||||
#
|
||||
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
# 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
|
||||
# http://opensource.org/licenses/bsd-license.php
|
||||
#
|
||||
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#
|
||||
#
|
||||
##
|
||||
@@ -28,9 +28,9 @@
|
||||
#
|
||||
# VALID_ARCHITECTURES = IA32 X64 IPF EBC
|
||||
#
|
||||
# DRIVER_BINDING = gVgaClassDriverBinding
|
||||
# DRIVER_BINDING = gVgaClassDriverBinding
|
||||
# COMPONENT_NAME = gVgaClassComponentName
|
||||
# COMPONENT_NAME2 = gVgaClassComponentName2
|
||||
# COMPONENT_NAME2 = gVgaClassComponentName2
|
||||
#
|
||||
|
||||
[Sources]
|
||||
|
@@ -3,13 +3,13 @@
|
||||
//
|
||||
// The VGA Class Driver that manages VGA devices and produces Simple Text Output Protocol.
|
||||
//
|
||||
// Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// VgaClassDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials
|
||||
// are licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -13,8 +13,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"VGA Class DXE Driver"
|
||||
|
||||
|
||||
|
@@ -1,16 +1,16 @@
|
||||
/** @file
|
||||
Uses the services of the I/O Library to produce the CPU I/O Protocol
|
||||
|
||||
Copyright (c) 2004 - 2017, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2017, AMD Incorporated. All rights reserved.<BR>
|
||||
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
**/
|
||||
|
||||
@@ -74,16 +74,16 @@ UINT8 mOutStride[] = {
|
||||
/**
|
||||
Check parameters to a CPU I/O Protocol service request.
|
||||
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
be handled by the driver.
|
||||
|
||||
|
||||
@param[in] MmioOperation TRUE for an MMIO operation, FALSE for I/O Port operation.
|
||||
@param[in] Width Signifies the width of the I/O or Memory operation.
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
bytes moved is Width size * Count, starting at Address.
|
||||
@param[in] Buffer For read operations, the destination buffer to store the results.
|
||||
For write operations, the source buffer from which to write data.
|
||||
@@ -92,7 +92,7 @@ UINT8 mOutStride[] = {
|
||||
@retval EFI_INVALID_PARAMETER Width is invalid for this PI system.
|
||||
@retval EFI_INVALID_PARAMETER Buffer is NULL.
|
||||
@retval EFI_UNSUPPORTED The Buffer is not aligned for the given Width.
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
and Count is not valid for this PI system.
|
||||
|
||||
**/
|
||||
@@ -137,7 +137,7 @@ CpuIoCheckParameter (
|
||||
if (!MmioOperation && (Width == EfiCpuIoWidthUint64)) {
|
||||
return EFI_INVALID_PARAMETER;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Check to see if Address is aligned
|
||||
//
|
||||
@@ -146,18 +146,18 @@ CpuIoCheckParameter (
|
||||
}
|
||||
|
||||
//
|
||||
// Check to see if any address associated with this transfer exceeds the maximum
|
||||
// Check to see if any address associated with this transfer exceeds the maximum
|
||||
// allowed address. The maximum address implied by the parameters passed in is
|
||||
// Address + Size * Count. If the following condition is met, then the transfer
|
||||
// is not supported.
|
||||
//
|
||||
// Address + Size * Count > (MmioOperation ? MAX_ADDRESS : MAX_IO_PORT_ADDRESS) + 1
|
||||
//
|
||||
// Since MAX_ADDRESS can be the maximum integer value supported by the CPU and Count
|
||||
// Since MAX_ADDRESS can be the maximum integer value supported by the CPU and Count
|
||||
// can also be the maximum integer value supported by the CPU, this range
|
||||
// check must be adjusted to avoid all overflow conditions.
|
||||
//
|
||||
// The following form of the range check is equivalent but assumes that
|
||||
//
|
||||
// The following form of the range check is equivalent but assumes that
|
||||
// MAX_ADDRESS and MAX_IO_PORT_ADDRESS are of the form (2^n - 1).
|
||||
//
|
||||
Limit = (MmioOperation ? MAX_ADDRESS : MAX_IO_PORT_ADDRESS);
|
||||
@@ -165,7 +165,7 @@ CpuIoCheckParameter (
|
||||
if (Address > Limit) {
|
||||
return EFI_UNSUPPORTED;
|
||||
}
|
||||
} else {
|
||||
} else {
|
||||
MaxCount = RShiftU64 (Limit, Width);
|
||||
if (MaxCount < (Count - 1)) {
|
||||
return EFI_UNSUPPORTED;
|
||||
@@ -189,30 +189,30 @@ CpuIoCheckParameter (
|
||||
/**
|
||||
Reads memory-mapped registers.
|
||||
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
be handled by the driver.
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
each of the Count operations that is performed.
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times on the same Address.
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times from the first element of Buffer.
|
||||
|
||||
|
||||
@param[in] This A pointer to the EFI_CPU_IO_PROTOCOL instance.
|
||||
@param[in] Width Signifies the width of the I/O or Memory operation.
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
bytes moved is Width size * Count, starting at Address.
|
||||
@param[out] Buffer For read operations, the destination buffer to store the results.
|
||||
For write operations, the source buffer from which to write data.
|
||||
@@ -221,7 +221,7 @@ CpuIoCheckParameter (
|
||||
@retval EFI_INVALID_PARAMETER Width is invalid for this PI system.
|
||||
@retval EFI_INVALID_PARAMETER Buffer is NULL.
|
||||
@retval EFI_UNSUPPORTED The Buffer is not aligned for the given Width.
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
and Count is not valid for this PI system.
|
||||
|
||||
**/
|
||||
@@ -269,30 +269,30 @@ CpuMemoryServiceRead (
|
||||
/**
|
||||
Writes memory-mapped registers.
|
||||
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
be handled by the driver.
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
each of the Count operations that is performed.
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times on the same Address.
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times from the first element of Buffer.
|
||||
|
||||
|
||||
@param[in] This A pointer to the EFI_CPU_IO_PROTOCOL instance.
|
||||
@param[in] Width Signifies the width of the I/O or Memory operation.
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
bytes moved is Width size * Count, starting at Address.
|
||||
@param[in] Buffer For read operations, the destination buffer to store the results.
|
||||
For write operations, the source buffer from which to write data.
|
||||
@@ -301,7 +301,7 @@ CpuMemoryServiceRead (
|
||||
@retval EFI_INVALID_PARAMETER Width is invalid for this PI system.
|
||||
@retval EFI_INVALID_PARAMETER Buffer is NULL.
|
||||
@retval EFI_UNSUPPORTED The Buffer is not aligned for the given Width.
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
and Count is not valid for this PI system.
|
||||
|
||||
**/
|
||||
@@ -349,30 +349,30 @@ CpuMemoryServiceWrite (
|
||||
/**
|
||||
Reads I/O registers.
|
||||
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
be handled by the driver.
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
each of the Count operations that is performed.
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times on the same Address.
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times from the first element of Buffer.
|
||||
|
||||
|
||||
@param[in] This A pointer to the EFI_CPU_IO_PROTOCOL instance.
|
||||
@param[in] Width Signifies the width of the I/O or Memory operation.
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
bytes moved is Width size * Count, starting at Address.
|
||||
@param[out] Buffer For read operations, the destination buffer to store the results.
|
||||
For write operations, the source buffer from which to write data.
|
||||
@@ -381,7 +381,7 @@ CpuMemoryServiceWrite (
|
||||
@retval EFI_INVALID_PARAMETER Width is invalid for this PI system.
|
||||
@retval EFI_INVALID_PARAMETER Buffer is NULL.
|
||||
@retval EFI_UNSUPPORTED The Buffer is not aligned for the given Width.
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
and Count is not valid for this PI system.
|
||||
|
||||
**/
|
||||
@@ -453,30 +453,30 @@ CpuIoServiceRead (
|
||||
/**
|
||||
Write I/O registers.
|
||||
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
be handled by the driver.
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
each of the Count operations that is performed.
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times on the same Address.
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times from the first element of Buffer.
|
||||
|
||||
|
||||
@param[in] This A pointer to the EFI_CPU_IO_PROTOCOL instance.
|
||||
@param[in] Width Signifies the width of the I/O or Memory operation.
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
bytes moved is Width size * Count, starting at Address.
|
||||
@param[in] Buffer For read operations, the destination buffer to store the results.
|
||||
For write operations, the source buffer from which to write data.
|
||||
@@ -485,9 +485,9 @@ CpuIoServiceRead (
|
||||
@retval EFI_INVALID_PARAMETER Width is invalid for this PI system.
|
||||
@retval EFI_INVALID_PARAMETER Buffer is NULL.
|
||||
@retval EFI_UNSUPPORTED The Buffer is not aligned for the given Width.
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
and Count is not valid for this PI system.
|
||||
|
||||
|
||||
**/
|
||||
EFI_STATUS
|
||||
EFIAPI
|
||||
@@ -553,16 +553,16 @@ CpuIoServiceWrite (
|
||||
IoWrite32 ((UINTN)Address, *((UINT32 *)Uint8Buffer));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
/**
|
||||
The user Entry Point for module CpuIo. The user code starts with this function.
|
||||
|
||||
@param[in] ImageHandle The firmware allocated handle for the EFI image.
|
||||
@param[in] ImageHandle The firmware allocated handle for the EFI image.
|
||||
@param[in] SystemTable A pointer to the EFI System Table.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The entry point is executed successfully.
|
||||
@retval other Some error occurs when executing this entry point.
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Internal include file of CPU I/O DXE Driver.
|
||||
|
||||
Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -30,30 +30,30 @@
|
||||
/**
|
||||
Reads memory-mapped registers.
|
||||
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
be handled by the driver.
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
each of the Count operations that is performed.
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times on the same Address.
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times from the first element of Buffer.
|
||||
|
||||
|
||||
@param[in] This A pointer to the EFI_CPU_IO_PROTOCOL instance.
|
||||
@param[in] Width Signifies the width of the I/O or Memory operation.
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
bytes moved is Width size * Count, starting at Address.
|
||||
@param[out] Buffer For read operations, the destination buffer to store the results.
|
||||
For write operations, the source buffer from which to write data.
|
||||
@@ -62,7 +62,7 @@
|
||||
@retval EFI_INVALID_PARAMETER Width is invalid for this PI system.
|
||||
@retval EFI_INVALID_PARAMETER Buffer is NULL.
|
||||
@retval EFI_UNSUPPORTED The Buffer is not aligned for the given Width.
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
and Count is not valid for this PI system.
|
||||
|
||||
**/
|
||||
@@ -79,30 +79,30 @@ CpuMemoryServiceRead (
|
||||
/**
|
||||
Writes memory-mapped registers.
|
||||
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
be handled by the driver.
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
each of the Count operations that is performed.
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times on the same Address.
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times from the first element of Buffer.
|
||||
|
||||
|
||||
@param[in] This A pointer to the EFI_CPU_IO_PROTOCOL instance.
|
||||
@param[in] Width Signifies the width of the I/O or Memory operation.
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
bytes moved is Width size * Count, starting at Address.
|
||||
@param[in] Buffer For read operations, the destination buffer to store the results.
|
||||
For write operations, the source buffer from which to write data.
|
||||
@@ -111,7 +111,7 @@ CpuMemoryServiceRead (
|
||||
@retval EFI_INVALID_PARAMETER Width is invalid for this PI system.
|
||||
@retval EFI_INVALID_PARAMETER Buffer is NULL.
|
||||
@retval EFI_UNSUPPORTED The Buffer is not aligned for the given Width.
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
and Count is not valid for this PI system.
|
||||
|
||||
**/
|
||||
@@ -128,30 +128,30 @@ CpuMemoryServiceWrite (
|
||||
/**
|
||||
Reads I/O registers.
|
||||
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
be handled by the driver.
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
each of the Count operations that is performed.
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times on the same Address.
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times from the first element of Buffer.
|
||||
|
||||
|
||||
@param[in] This A pointer to the EFI_CPU_IO_PROTOCOL instance.
|
||||
@param[in] Width Signifies the width of the I/O or Memory operation.
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
bytes moved is Width size * Count, starting at Address.
|
||||
@param[out] Buffer For read operations, the destination buffer to store the results.
|
||||
For write operations, the source buffer from which to write data.
|
||||
@@ -160,7 +160,7 @@ CpuMemoryServiceWrite (
|
||||
@retval EFI_INVALID_PARAMETER Width is invalid for this PI system.
|
||||
@retval EFI_INVALID_PARAMETER Buffer is NULL.
|
||||
@retval EFI_UNSUPPORTED The Buffer is not aligned for the given Width.
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
and Count is not valid for this PI system.
|
||||
|
||||
**/
|
||||
@@ -177,30 +177,30 @@ CpuIoServiceRead (
|
||||
/**
|
||||
Write I/O registers.
|
||||
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
The I/O operations are carried out exactly as requested. The caller is responsible
|
||||
for satisfying any alignment and I/O width restrictions that a PI System on a
|
||||
platform might require. For example on some platforms, width requests of
|
||||
EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
|
||||
be handled by the driver.
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
|
||||
If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
|
||||
or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
|
||||
each of the Count operations that is performed.
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
|
||||
EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times on the same Address.
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
|
||||
If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
|
||||
EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
|
||||
incremented for each of the Count operations that is performed. The read or
|
||||
write operation is performed Count times from the first element of Buffer.
|
||||
|
||||
|
||||
@param[in] This A pointer to the EFI_CPU_IO_PROTOCOL instance.
|
||||
@param[in] Width Signifies the width of the I/O or Memory operation.
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
@param[in] Address The base address of the I/O operation.
|
||||
@param[in] Count The number of I/O operations to perform. The number of
|
||||
bytes moved is Width size * Count, starting at Address.
|
||||
@param[in] Buffer For read operations, the destination buffer to store the results.
|
||||
For write operations, the source buffer from which to write data.
|
||||
@@ -209,9 +209,9 @@ CpuIoServiceRead (
|
||||
@retval EFI_INVALID_PARAMETER Width is invalid for this PI system.
|
||||
@retval EFI_INVALID_PARAMETER Buffer is NULL.
|
||||
@retval EFI_UNSUPPORTED The Buffer is not aligned for the given Width.
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
@retval EFI_UNSUPPORTED The address range specified by Address, Width,
|
||||
and Count is not valid for this PI system.
|
||||
|
||||
|
||||
**/
|
||||
EFI_STATUS
|
||||
EFIAPI
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// CpuIoDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials
|
||||
// are licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -12,8 +12,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"Processor I/O DXE Driver"
|
||||
|
||||
|
||||
|
@@ -1,15 +1,15 @@
|
||||
/** @file
|
||||
This code produces the Data Hub protocol. It preloads the data hub
|
||||
with status information copied in from PEI HOBs.
|
||||
|
||||
Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
**/
|
||||
|
||||
@@ -32,7 +32,7 @@ DATA_HUB_INSTANCE mPrivateData;
|
||||
@param RawDataSize Size of Data Log data in bytes
|
||||
|
||||
@retval EFI_SUCCESS If data was logged
|
||||
@retval EFI_OUT_OF_RESOURCES If data was not logged due to lack of system
|
||||
@retval EFI_OUT_OF_RESOURCES If data was not logged due to lack of system
|
||||
resources.
|
||||
**/
|
||||
EFI_STATUS
|
||||
@@ -68,7 +68,7 @@ DataHubLogData (
|
||||
//
|
||||
RecordSize = sizeof (EFI_DATA_RECORD_HEADER) + RawDataSize;
|
||||
TotalSize = sizeof (EFI_DATA_ENTRY) + RecordSize;
|
||||
|
||||
|
||||
//
|
||||
// First try to get log time at TPL level <= TPL_CALLBACK.
|
||||
//
|
||||
@@ -149,7 +149,7 @@ DataHubLogData (
|
||||
}
|
||||
|
||||
/**
|
||||
Search the Head doubly linked list for the passed in MTC. Return the
|
||||
Search the Head doubly linked list for the passed in MTC. Return the
|
||||
matching element in Head and the MTC on the next entry.
|
||||
|
||||
@param Head Head of Data Log linked list.
|
||||
@@ -157,7 +157,7 @@ DataHubLogData (
|
||||
ClassFilter.
|
||||
@param PtrCurrentMTC On IN contians MTC to search for. On OUT contians next
|
||||
MTC in the data log list or zero if at end of the list.
|
||||
|
||||
|
||||
@retval EFI_DATA_LOG_ENTRY Return pointer to data log data from Head list.
|
||||
@retval NULL If no data record exists.
|
||||
|
||||
@@ -257,20 +257,20 @@ FindFilterDriverByEvent (
|
||||
Get a previously logged data record and the MonotonicCount for the next
|
||||
available Record. This allows all records or all records later
|
||||
than a give MonotonicCount to be returned. If an optional FilterDriverEvent
|
||||
is passed in with a MonotonicCout of zero return the first record
|
||||
not yet read by the filter driver. If FilterDriverEvent is NULL and
|
||||
is passed in with a MonotonicCout of zero return the first record
|
||||
not yet read by the filter driver. If FilterDriverEvent is NULL and
|
||||
MonotonicCount is zero return the first data record.
|
||||
|
||||
@param This Pointer to the EFI_DATA_HUB_PROTOCOL instance.
|
||||
@param MonotonicCount Specifies the Record to return. On input, zero means
|
||||
return the first record. On output, contains the next
|
||||
record to available. Zero indicates no more records.
|
||||
@param FilterDriverEvent If FilterDriverEvent is not passed in a MonotonicCount
|
||||
of zero, it means to return the first data record.
|
||||
If FilterDriverEvent is passed in, then a MonotonicCount
|
||||
of zero means to return the first data not yet read by
|
||||
@param FilterDriverEvent If FilterDriverEvent is not passed in a MonotonicCount
|
||||
of zero, it means to return the first data record.
|
||||
If FilterDriverEvent is passed in, then a MonotonicCount
|
||||
of zero means to return the first data not yet read by
|
||||
FilterDriverEvent.
|
||||
@param Record Returns a dynamically allocated memory buffer with a data
|
||||
@param Record Returns a dynamically allocated memory buffer with a data
|
||||
record that matches MonotonicCount.
|
||||
|
||||
@retval EFI_SUCCESS Data was returned in Record.
|
||||
@@ -312,7 +312,7 @@ DataHubGetNextRecord (
|
||||
}
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// For events the beginning is the last unread record. This info is
|
||||
// stored in the instance structure, so we must look up the event
|
||||
@@ -332,16 +332,16 @@ DataHubGetNextRecord (
|
||||
|
||||
//
|
||||
// Retrieve the next record or the first record.
|
||||
//
|
||||
if (*MonotonicCount != 0 || FilterDriver->GetNextMonotonicCount == 0) {
|
||||
//
|
||||
if (*MonotonicCount != 0 || FilterDriver->GetNextMonotonicCount == 0) {
|
||||
*Record = GetNextDataRecord (&Private->DataListHead, ClassFilter, MonotonicCount);
|
||||
if (*Record == NULL) {
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
|
||||
|
||||
if (*MonotonicCount != 0) {
|
||||
//
|
||||
// If this was not the last record then update the count associated with the filter
|
||||
// If this was not the last record then update the count associated with the filter
|
||||
//
|
||||
FilterDriver->GetNextMonotonicCount = *MonotonicCount;
|
||||
} else {
|
||||
@@ -352,13 +352,13 @@ DataHubGetNextRecord (
|
||||
}
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// This is a request to read the first record that has not been read yet.
|
||||
// This is a request to read the first record that has not been read yet.
|
||||
// Set MonotoicCount to the last record successfuly read
|
||||
//
|
||||
*MonotonicCount = FilterDriver->GetNextMonotonicCount;
|
||||
|
||||
|
||||
//
|
||||
// Retrieve the last record successfuly read again, but do not return it since
|
||||
// it has already been returned before.
|
||||
@@ -367,51 +367,51 @@ DataHubGetNextRecord (
|
||||
if (*Record == NULL) {
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
|
||||
|
||||
if (*MonotonicCount != 0) {
|
||||
//
|
||||
// Update the count associated with the filter
|
||||
// Update the count associated with the filter
|
||||
//
|
||||
FilterDriver->GetNextMonotonicCount = *MonotonicCount;
|
||||
|
||||
//
|
||||
// Retrieve the record after the last record successfuly read
|
||||
//
|
||||
// Retrieve the record after the last record successfuly read
|
||||
//
|
||||
*Record = GetNextDataRecord (&Private->DataListHead, ClassFilter, MonotonicCount);
|
||||
if (*Record == NULL) {
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
/**
|
||||
This function registers the data hub filter driver that is represented
|
||||
This function registers the data hub filter driver that is represented
|
||||
by FilterEvent. Only one instance of each FilterEvent can be registered.
|
||||
After the FilterEvent is registered, it will be signaled so it can sync
|
||||
with data records that have been recorded prior to the FilterEvent being
|
||||
After the FilterEvent is registered, it will be signaled so it can sync
|
||||
with data records that have been recorded prior to the FilterEvent being
|
||||
registered.
|
||||
|
||||
|
||||
@param This Pointer to The EFI_DATA_HUB_PROTOCOL instance.
|
||||
@param FilterEvent The EFI_EVENT to signal whenever data that matches
|
||||
@param FilterEvent The EFI_EVENT to signal whenever data that matches
|
||||
FilterClass is logged in the system.
|
||||
@param FilterTpl The maximum EFI_TPL at which FilterEvent can be
|
||||
signaled. It is strongly recommended that you use the
|
||||
@param FilterTpl The maximum EFI_TPL at which FilterEvent can be
|
||||
signaled. It is strongly recommended that you use the
|
||||
lowest EFI_TPL possible.
|
||||
@param FilterClass FilterEvent will be signaled whenever a bit in
|
||||
EFI_DATA_RECORD_HEADER.DataRecordClass is also set in
|
||||
FilterClass. If FilterClass is zero, no class-based
|
||||
@param FilterClass FilterEvent will be signaled whenever a bit in
|
||||
EFI_DATA_RECORD_HEADER.DataRecordClass is also set in
|
||||
FilterClass. If FilterClass is zero, no class-based
|
||||
filtering will be performed.
|
||||
@param FilterDataRecordGuid FilterEvent will be signaled whenever FilterDataRecordGuid
|
||||
matches EFI_DATA_RECORD_HEADER.DataRecordGuid. If
|
||||
FilterDataRecordGuid is NULL, then no GUID-based filtering
|
||||
will be performed.
|
||||
@param FilterDataRecordGuid FilterEvent will be signaled whenever FilterDataRecordGuid
|
||||
matches EFI_DATA_RECORD_HEADER.DataRecordGuid. If
|
||||
FilterDataRecordGuid is NULL, then no GUID-based filtering
|
||||
will be performed.
|
||||
|
||||
@retval EFI_SUCCESS The filter driver event was registered.
|
||||
@retval EFI_ALREADY_STARTED FilterEvent was previously registered and cannot be
|
||||
@retval EFI_ALREADY_STARTED FilterEvent was previously registered and cannot be
|
||||
registered again.
|
||||
@retval EFI_OUT_OF_RESOURCES The filter driver event was not registered due to lack of
|
||||
@retval EFI_OUT_OF_RESOURCES The filter driver event was not registered due to lack of
|
||||
system resources.
|
||||
|
||||
**/
|
||||
@@ -480,12 +480,12 @@ DataHubRegisterFilterDriver (
|
||||
}
|
||||
|
||||
/**
|
||||
Remove a Filter Driver, so it no longer gets called when data
|
||||
Remove a Filter Driver, so it no longer gets called when data
|
||||
information is logged.
|
||||
|
||||
@param This Protocol instance structure
|
||||
|
||||
@param FilterEvent Event that represents a filter driver that is to be
|
||||
@param FilterEvent Event that represents a filter driver that is to be
|
||||
Unregistered.
|
||||
|
||||
@retval EFI_SUCCESS If FilterEvent was unregistered
|
||||
@@ -526,7 +526,7 @@ DataHubUnregisterFilterDriver (
|
||||
|
||||
|
||||
/**
|
||||
Driver's Entry point routine that install Driver to produce Data Hub protocol.
|
||||
Driver's Entry point routine that install Driver to produce Data Hub protocol.
|
||||
|
||||
@param ImageHandle Module's image handle
|
||||
@param SystemTable Pointer of EFI_SYSTEM_TABLE
|
||||
|
@@ -1,15 +1,15 @@
|
||||
/** @file
|
||||
This code supports a the private implementation
|
||||
This code supports a the private implementation
|
||||
of the Data Hub protocol
|
||||
|
||||
Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
**/
|
||||
|
||||
|
@@ -20,8 +20,8 @@
|
||||
# Management Interface (IPMI).The alternative to a data-hub-like architecture is to require all
|
||||
# drivers to be aware of all reporting formats.
|
||||
# For more information, please ref http://www.intel.com/technology/framework/
|
||||
#
|
||||
# Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
|
||||
#
|
||||
# Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
#
|
||||
# This program and the accompanying materials
|
||||
# are licensed and made available under the terms and conditions of the BSD License
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// DataHubDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials
|
||||
// are licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -12,8 +12,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"Data Hub DXE Driver"
|
||||
|
||||
|
||||
|
@@ -2,7 +2,7 @@
|
||||
Data Hub filter driver that takes DEBUG () info from Data Hub and writes it
|
||||
to StdErr if it exists.
|
||||
|
||||
Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -65,7 +65,7 @@ DataHubStdErrEventHandler (
|
||||
if (gST->StdErr == NULL) {
|
||||
return ;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Mtc of zero means return the next record that has not been read by the
|
||||
// event handler.
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// DataHubStdErrDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials
|
||||
// are licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -12,8 +12,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"Data Hub stderr DXE Driver"
|
||||
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Implements functions to pad firmware file.
|
||||
|
||||
Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -219,7 +219,7 @@ FvCreatePadFileInFreeSpace (
|
||||
|
||||
/**
|
||||
Fill pad file header within firmware cache.
|
||||
|
||||
|
||||
@param PadFileHeader The start of the Pad File Buffer.
|
||||
@param PadFileLength The length of the pad file including the header.
|
||||
|
||||
@@ -264,7 +264,7 @@ FvFillPadFile (
|
||||
|
||||
/**
|
||||
Create entire FFS file.
|
||||
|
||||
|
||||
@param FileHeader Starting Address of a Buffer that hold the FFS File image.
|
||||
@param FfsFileBuffer The source buffer that contains the File Data.
|
||||
@param BufferSize The length of FfsFileBuffer.
|
||||
@@ -662,7 +662,7 @@ FreeFfsBuffer (
|
||||
@param ActualFileSize The array of actual file size.
|
||||
@param PadSize The array of leading pad file size for each FFS File
|
||||
@param FfsBuffer The array of Ffs Buffer pointer.
|
||||
@param FileData The array of EFI_FV_WRITE_FILE_DATA structure,
|
||||
@param FileData The array of EFI_FV_WRITE_FILE_DATA structure,
|
||||
used to get name, attributes, type, etc.
|
||||
|
||||
@retval EFI_SUCCESS Add the input multiple files into PAD file area.
|
||||
@@ -868,7 +868,7 @@ FvCreateMultipleFilesInsidePadFile (
|
||||
@param ActualFileSize The array of actual file size.
|
||||
@param PadSize The array of leading pad file size for each FFS File
|
||||
@param FfsBuffer The array of Ffs Buffer pointer.
|
||||
@param FileData The array of EFI_FV_WRITE_FILE_DATA structure,
|
||||
@param FileData The array of EFI_FV_WRITE_FILE_DATA structure,
|
||||
used to get name, attributes, type, etc.
|
||||
|
||||
@retval EFI_SUCCESS Add the input multiple files into PAD file area.
|
||||
@@ -993,7 +993,7 @@ FvCreateMultipleFilesInsideFreeSpace (
|
||||
|
||||
@param FvDevice Firmware Volume Device.
|
||||
@param NumOfFiles Total File number to be written.
|
||||
@param FileData The array of EFI_FV_WRITE_FILE_DATA structure,
|
||||
@param FileData The array of EFI_FV_WRITE_FILE_DATA structure,
|
||||
used to get name, attributes, type, etc
|
||||
@param FileOperation The array of operation for each file.
|
||||
|
||||
|
@@ -4,7 +4,7 @@
|
||||
Layers on top of Firmware Block protocol to produce a file abstraction
|
||||
of FV based files.
|
||||
|
||||
Copyright (c) 2006 - 2017, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -789,7 +789,7 @@ FwVolDriverInit (
|
||||
} else {
|
||||
FreePool (FvDevice);
|
||||
}
|
||||
|
||||
|
||||
DEBUG ((EFI_D_INFO, "Reinstall FV protocol as writable - %r\n", Status));
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
} else {
|
||||
@@ -807,7 +807,7 @@ FwVolDriverInit (
|
||||
} else {
|
||||
FreePool (FvDevice);
|
||||
}
|
||||
|
||||
|
||||
DEBUG ((EFI_D_INFO, "Install FV protocol as writable - %r\n", Status));
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
}
|
||||
@@ -822,7 +822,7 @@ Done:
|
||||
if (InstallFlag) {
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// No FV protocol install/reinstall successfully.
|
||||
// EFI_NOT_FOUND should return to ensure this image will be unloaded.
|
||||
|
@@ -2,7 +2,7 @@
|
||||
|
||||
Implements get/set firmware volume attributes.
|
||||
|
||||
Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -65,7 +65,7 @@ FvGetVolumeAttributes (
|
||||
unsuccessful return, FvAttributes is not
|
||||
modified and the firmware volume
|
||||
settings are not changed.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The requested firmware volume attributes
|
||||
were set and the resulting
|
||||
EFI_FV_ATTRIBUTES is returned in
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Common defines and definitions for a FwVolDxe driver.
|
||||
|
||||
Copyright (c) 2006 - 2017, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -129,7 +129,7 @@ FvGetVolumeAttributes (
|
||||
unsuccessful return, FvAttributes is not
|
||||
modified and the firmware volume
|
||||
settings are not changed.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The requested firmware volume attributes
|
||||
were set and the resulting
|
||||
EFI_FV_ATTRIBUTES is returned in
|
||||
@@ -598,7 +598,7 @@ FvCreateNewFileInsidePadFile (
|
||||
|
||||
@param FvDevice Firmware Volume Device.
|
||||
@param NumOfFiles Total File number to be written.
|
||||
@param FileData The array of EFI_FV_WRITE_FILE_DATA structure,
|
||||
@param FileData The array of EFI_FV_WRITE_FILE_DATA structure,
|
||||
used to get name, attributes, type, etc
|
||||
@param FileOperation The array of operation for each file.
|
||||
|
||||
|
@@ -4,13 +4,13 @@
|
||||
// This driver produces Firmware Volume2 protocol with full services
|
||||
// (read/write, get/set) based on Firmware Volume Block protocol.
|
||||
//
|
||||
// Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// FwVolDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials are
|
||||
// licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -13,8 +13,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"Flash Storage DXE Driver v2"
|
||||
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Implements write firmware file.
|
||||
|
||||
Copyright (c) 2006 - 2017, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -710,7 +710,7 @@ FvcWrite (
|
||||
UINTN RemainingLength;
|
||||
UINTN WriteLength;
|
||||
UINT8 *TmpBuffer;
|
||||
|
||||
|
||||
LOffset = 0;
|
||||
RemainingLength = CalculateRemainingLength (FvDevice, Offset, &Lba, &LOffset);
|
||||
if ((UINTN) (*NumBytes) > RemainingLength) {
|
||||
@@ -1463,8 +1463,8 @@ FvWriteFile (
|
||||
|
||||
if (FileData[Index1].Type == EFI_FV_FILETYPE_FFS_PAD) {
|
||||
//
|
||||
// According to PI spec, on EFI_FV_FILETYPE_FFS_PAD:
|
||||
// "Standard firmware file system services will not return the handle of any pad files,
|
||||
// According to PI spec, on EFI_FV_FILETYPE_FFS_PAD:
|
||||
// "Standard firmware file system services will not return the handle of any pad files,
|
||||
// nor will they permit explicit creation of such files."
|
||||
//
|
||||
return EFI_INVALID_PARAMETER;
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Functions in this file will program the image into flash area.
|
||||
|
||||
Copyright (c) 2002 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2002 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -450,9 +450,9 @@ FaultTolerantUpdateOnWholeFv (
|
||||
Offset = 0;
|
||||
UpdateBuffer = ImageBuffer;
|
||||
CopyMem (
|
||||
(VOID *) &PrivateData.FileGuid,
|
||||
(VOID *) &ConfigData->FileGuid,
|
||||
sizeof (EFI_GUID)
|
||||
(VOID *) &PrivateData.FileGuid,
|
||||
(VOID *) &ConfigData->FileGuid,
|
||||
sizeof (EFI_GUID)
|
||||
);
|
||||
|
||||
while (TRUE) {
|
||||
@@ -1006,9 +1006,9 @@ FaultTolerantUpdateOnPartFv (
|
||||
PtrMap = BlockMap;
|
||||
Image = ImageBuffer;
|
||||
CopyMem (
|
||||
(VOID *) &PrivateData.FileGuid,
|
||||
(VOID *) &ConfigData->FileGuid,
|
||||
sizeof (EFI_GUID)
|
||||
(VOID *) &PrivateData.FileGuid,
|
||||
(VOID *) &ConfigData->FileGuid,
|
||||
sizeof (EFI_GUID)
|
||||
);
|
||||
|
||||
while (TotalSize > 0) {
|
||||
|
@@ -3,7 +3,7 @@
|
||||
configuration file and pass the information to the update driver
|
||||
so that the driver can perform updates accordingly.
|
||||
|
||||
Copyright (c) 2002 - 2015, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2002 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -622,7 +622,7 @@ UpdateValueToString (
|
||||
}
|
||||
|
||||
/**
|
||||
Convert the input value to a ascii string,
|
||||
Convert the input value to a ascii string,
|
||||
and concatenates this string to the input string.
|
||||
|
||||
@param Str Pointer to a Null-terminated ASCII string.
|
||||
@@ -786,7 +786,7 @@ UpdateStringToGuid (
|
||||
|
||||
/**
|
||||
Pre process config data buffer into Section entry list and Comment entry list.
|
||||
|
||||
|
||||
@param DataBuffer Config raw file buffer.
|
||||
@param BufferSize Size of raw buffer.
|
||||
@param SectionHead Pointer to the section entry list.
|
||||
|
@@ -3,7 +3,7 @@
|
||||
for the image to be programmed, and the flash area that is going to be
|
||||
programed.
|
||||
|
||||
Copyright (c) 2002 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2002 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
|
||||
This program and the accompanying materials
|
||||
are licensed and made available under the terms and conditions
|
||||
@@ -22,7 +22,7 @@ EFI_HII_HANDLE gHiiHandle;
|
||||
|
||||
/**
|
||||
Update the whole FV, or certain files in the FV.
|
||||
|
||||
|
||||
@param ConfigData Pointer to the config data on updating file.
|
||||
@param ImageBuffer Image buffer to be updated.
|
||||
@param ImageSize Image size.
|
||||
@@ -89,7 +89,7 @@ PerformUpdateOnFirmwareVolume (
|
||||
//
|
||||
Status = FvbProtocol->GetAttributes (FvbProtocol, &Attributes);
|
||||
if (EFI_ERROR (Status) || ((Attributes & EFI_FVB2_WRITE_STATUS) == 0)) {
|
||||
continue;
|
||||
continue;
|
||||
}
|
||||
|
||||
Status = FvbProtocol->GetPhysicalAddress (
|
||||
@@ -197,7 +197,7 @@ PerformUpdateOnFlashArea (
|
||||
Print (TmpStr, FlashAddress, ((UINT64)SizeLeft + FlashAddress));
|
||||
FreePool (TmpStr);
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Locate all Fvb protocol
|
||||
//
|
||||
@@ -242,7 +242,7 @@ PerformUpdateOnFlashArea (
|
||||
//
|
||||
Status = FvbProtocol->GetAttributes (FvbProtocol, &Attributes);
|
||||
if (EFI_ERROR (Status) || ((Attributes & EFI_FVB2_WRITE_STATUS) == 0)) {
|
||||
continue;
|
||||
continue;
|
||||
}
|
||||
|
||||
Status = FvbProtocol->GetPhysicalAddress (
|
||||
@@ -326,7 +326,7 @@ PerformUpdateOnFlashArea (
|
||||
if (EFI_ERROR (Status)) {
|
||||
return Status;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Check if we are done with the update
|
||||
//
|
||||
@@ -540,7 +540,7 @@ ProcessUpdateImage (
|
||||
FvAlignment = 1 << ((FwVolHeader->Attributes & EFI_FVB2_ALIGNMENT) >> 16);
|
||||
//
|
||||
// FvAlignment must be greater than or equal to 8 bytes of the minimum FFS alignment value.
|
||||
//
|
||||
//
|
||||
if (FvAlignment < 8) {
|
||||
FvAlignment = 8;
|
||||
}
|
||||
@@ -583,7 +583,7 @@ ProcessUpdateImage (
|
||||
/**
|
||||
Find the image in the same FV and program it in a target Firmware Volume device.
|
||||
After update image, it will reset system and no return.
|
||||
|
||||
|
||||
@param ImageHandle A handle for the image that is initializing this driver
|
||||
@param SystemTable A pointer to the EFI system table
|
||||
|
||||
@@ -602,7 +602,7 @@ InitializeUpdateDriver (
|
||||
EFI_LOADED_IMAGE_PROTOCOL *LoadedImageProtocol;
|
||||
EFI_FIRMWARE_VOLUME2_PROTOCOL *FwVolProtocol;
|
||||
EFI_FIRMWARE_VOLUME2_PROTOCOL *DataFwVolProtocol;
|
||||
MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *FwVolFilePathNode;
|
||||
MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *FwVolFilePathNode;
|
||||
MEDIA_FW_VOL_FILEPATH_DEVICE_PATH *AlignedDevPathNode;
|
||||
EFI_DEVICE_PATH_PROTOCOL *FilePathNode;
|
||||
EFI_SECTION_TYPE SectionType;
|
||||
@@ -815,7 +815,7 @@ InitializeUpdateDriver (
|
||||
UpdateConfigData
|
||||
);
|
||||
//
|
||||
// Shall updates be serialized so that if an update is not successfully completed,
|
||||
// Shall updates be serialized so that if an update is not successfully completed,
|
||||
// the remaining updates won't be performed.
|
||||
//
|
||||
if (EFI_ERROR (Status)) {
|
||||
|
@@ -1,11 +1,11 @@
|
||||
## @file
|
||||
# Update Driver for Capulse update.
|
||||
#
|
||||
# This driver is intended to be put in a capsule (FV). If all goes well,
|
||||
# then it should be dispatched from the capsule FV, then find the image
|
||||
# This driver is intended to be put in a capsule (FV). If all goes well,
|
||||
# then it should be dispatched from the capsule FV, then find the image
|
||||
# in the same FV and program it in a target Firmware Volume device.
|
||||
#
|
||||
# Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
#
|
||||
# This program and the accompanying materials are
|
||||
# licensed and made available under the terms and conditions of the BSD License
|
||||
|
@@ -5,13 +5,13 @@
|
||||
// then it should be dispatched from the capsule FV, then find the image
|
||||
// in the same FV and program it in a target Firmware Volume device.
|
||||
//
|
||||
// Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// UpdateDriverDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials are
|
||||
// licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -13,8 +13,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"Firmware Update DXE Driver"
|
||||
|
||||
|
||||
|
@@ -1,13 +1,13 @@
|
||||
/** @file
|
||||
Produces the Legacy Region Protocol.
|
||||
|
||||
This generic implementation of the Legacy Region Protocol does not actually
|
||||
perform any lock/unlock operations. This module may be used on platforms
|
||||
that do not provide HW locking of the legacy memory regions. It can also
|
||||
This generic implementation of the Legacy Region Protocol does not actually
|
||||
perform any lock/unlock operations. This module may be used on platforms
|
||||
that do not provide HW locking of the legacy memory regions. It can also
|
||||
be used as a template driver for implementing the Legacy Region Protocol on
|
||||
a platform that does support HW locking of the legacy memory regions.
|
||||
|
||||
Copyright (c) 2009, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -135,9 +135,9 @@ EFI_LEGACY_REGION_PROTOCOL mLegacyRegion = {
|
||||
/**
|
||||
The user Entry Point for module LegacyRegionDxe. The user code starts with this function.
|
||||
|
||||
@param[in] ImageHandle The firmware allocated handle for the EFI image.
|
||||
@param[in] ImageHandle The firmware allocated handle for the EFI image.
|
||||
@param[in] SystemTable A pointer to the EFI System Table.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The entry point is executed successfully.
|
||||
@retval other Some error occurs when executing this entry point.
|
||||
|
||||
@@ -150,12 +150,12 @@ LegacyRegionInstall (
|
||||
)
|
||||
{
|
||||
EFI_STATUS Status;
|
||||
|
||||
|
||||
//
|
||||
// Make sure the Legacy Region Protocol is not already installed in the system
|
||||
//
|
||||
ASSERT_PROTOCOL_ALREADY_INSTALLED (NULL, &gEfiLegacyRegionProtocolGuid);
|
||||
|
||||
|
||||
//
|
||||
// Install the protocol on a new handle.
|
||||
//
|
||||
|
@@ -1,18 +1,18 @@
|
||||
## @file
|
||||
# Produces Framework Legacy Region Protocol.
|
||||
#
|
||||
# This generic implementation of the Legacy Region Protocol does not actually
|
||||
# perform any lock/unlock operations. This module may be used on platforms
|
||||
# that do not provide HW locking of the legacy memory regions. It can also
|
||||
# This generic implementation of the Legacy Region Protocol does not actually
|
||||
# perform any lock/unlock operations. This module may be used on platforms
|
||||
# that do not provide HW locking of the legacy memory regions. It can also
|
||||
# be used as a template driver for implementing the Legacy Region Protocol on
|
||||
# a platform that does support HW locking of the legacy memory regions.
|
||||
#
|
||||
# Copyright (c) 2009 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
# 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
|
||||
# http://opensource.org/licenses/bsd-license.php
|
||||
#
|
||||
#
|
||||
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#
|
||||
|
@@ -7,13 +7,13 @@
|
||||
// be used as a template driver for implementing the Legacy Region Protocol on
|
||||
// a platform that does support HW locking of the legacy memory regions.
|
||||
//
|
||||
// Copyright (c) 2009 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// LegacyRegionDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials
|
||||
// are licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -13,8 +13,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"Legacy Region DXE Driver"
|
||||
|
||||
|
||||
|
@@ -1,33 +1,33 @@
|
||||
/** @file
|
||||
Section Extraction Protocol implementation.
|
||||
|
||||
|
||||
Stream database is implemented as a linked list of section streams,
|
||||
where each stream contains a linked list of children, which may be leaves or
|
||||
encapsulations.
|
||||
|
||||
encapsulations.
|
||||
|
||||
Children that are encapsulations generate new stream entries
|
||||
when they are created. Streams can also be created by calls to
|
||||
when they are created. Streams can also be created by calls to
|
||||
SEP->OpenSectionStream().
|
||||
|
||||
|
||||
The database is only created far enough to return the requested data from
|
||||
any given stream, or to determine that the requested data is not found.
|
||||
|
||||
|
||||
If a GUIDed encapsulation is encountered, there are three possiblilites.
|
||||
|
||||
|
||||
1) A support protocol is found, in which the stream is simply processed with
|
||||
the support protocol.
|
||||
|
||||
|
||||
2) A support protocol is not found, but the data is available to be read
|
||||
without processing. In this case, the database is built up through the
|
||||
recursions to return the data, and a RPN event is set that will enable
|
||||
the stream in question to be refreshed if and when the required section
|
||||
extraction protocol is published.This insures the AuthenticationStatus
|
||||
extraction protocol is published.This insures the AuthenticationStatus
|
||||
does not become stale in the cache.
|
||||
|
||||
|
||||
3) A support protocol is not found, and the data is not available to be read
|
||||
without it. This results in EFI_PROTOCOL_ERROR.
|
||||
|
||||
Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -77,7 +77,7 @@ typedef struct {
|
||||
UINTN EncapsulatedStreamHandle;
|
||||
EFI_GUID *EncapsulationGuid;
|
||||
//
|
||||
// If the section REQUIRES an extraction protocol, register for RPN
|
||||
// If the section REQUIRES an extraction protocol, register for RPN
|
||||
// when the required GUIDed extraction protocol becomes available.
|
||||
//
|
||||
EFI_EVENT Event;
|
||||
@@ -157,22 +157,22 @@ OpenSectionStream (
|
||||
@param AuthenticationStatus Indicates the authentication status of the retrieved
|
||||
section.
|
||||
|
||||
|
||||
|
||||
@retval EFI_SUCCESS Section was retrieved successfully
|
||||
@retval EFI_PROTOCOL_ERROR A GUID defined section was encountered in the section
|
||||
@retval EFI_PROTOCOL_ERROR A GUID defined section was encountered in the section
|
||||
stream with its EFI_GUIDED_SECTION_PROCESSING_REQUIRED
|
||||
bit set, but there was no corresponding GUIDed Section
|
||||
Extraction Protocol in the handle database. *Buffer is
|
||||
bit set, but there was no corresponding GUIDed Section
|
||||
Extraction Protocol in the handle database. *Buffer is
|
||||
unmodified.
|
||||
@retval EFI_NOT_FOUND An error was encountered when parsing the SectionStream.
|
||||
This indicates the SectionStream is not correctly
|
||||
This indicates the SectionStream is not correctly
|
||||
formatted.
|
||||
@retval EFI_NOT_FOUND The requested section does not exist.
|
||||
@retval EFI_OUT_OF_RESOURCES The system has insufficient resources to process the
|
||||
@retval EFI_OUT_OF_RESOURCES The system has insufficient resources to process the
|
||||
request.
|
||||
@retval EFI_INVALID_PARAMETER The SectionStreamHandle does not exist.
|
||||
@retval EFI_WARN_TOO_SMALL The size of the caller allocated input buffer is
|
||||
insufficient to contain the requested section. The
|
||||
@retval EFI_WARN_TOO_SMALL The size of the caller allocated input buffer is
|
||||
insufficient to contain the requested section. The
|
||||
input buffer is filled and contents are section contents
|
||||
are truncated.
|
||||
|
||||
@@ -218,18 +218,18 @@ LIST_ENTRY mStreamRoot = INITIALIZE_LIST_HEAD_VARIABLE (mStreamRoot);
|
||||
|
||||
EFI_HANDLE mSectionExtractionHandle = NULL;
|
||||
|
||||
EFI_SECTION_EXTRACTION_PROTOCOL mSectionExtraction = {
|
||||
OpenSectionStream,
|
||||
GetSection,
|
||||
EFI_SECTION_EXTRACTION_PROTOCOL mSectionExtraction = {
|
||||
OpenSectionStream,
|
||||
GetSection,
|
||||
CloseSectionStream
|
||||
};
|
||||
|
||||
/**
|
||||
Entry point of the section extraction code. Initializes an instance of the
|
||||
Entry point of the section extraction code. Initializes an instance of the
|
||||
section extraction interface and installs it on a new handle.
|
||||
|
||||
@param ImageHandle A handle for the image that is initializing this driver
|
||||
@param SystemTable A pointer to the EFI system table
|
||||
@param SystemTable A pointer to the EFI system table
|
||||
|
||||
@retval EFI_SUCCESS Driver initialized successfully
|
||||
@retval EFI_OUT_OF_RESOURCES Could not allocate needed resources
|
||||
@@ -281,7 +281,7 @@ IsValidSectionStream (
|
||||
|
||||
TotalLength = 0;
|
||||
SectionHeader = (EFI_COMMON_SECTION_HEADER *)SectionStream;
|
||||
|
||||
|
||||
while (TotalLength < SectionStreamLength) {
|
||||
if (IS_SECTION2 (SectionHeader)) {
|
||||
SectionLength = SECTION2_SIZE (SectionHeader);
|
||||
@@ -291,14 +291,14 @@ IsValidSectionStream (
|
||||
TotalLength += SectionLength;
|
||||
|
||||
if (TotalLength == SectionStreamLength) {
|
||||
return TRUE;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
//
|
||||
// Move to the next byte following the section...
|
||||
//
|
||||
SectionHeader = (EFI_COMMON_SECTION_HEADER *) ((UINT8 *) SectionHeader + SectionLength);
|
||||
|
||||
|
||||
//
|
||||
// Figure out where the next section begins
|
||||
//
|
||||
@@ -331,13 +331,13 @@ OpenSectionStreamEx (
|
||||
IN UINTN SectionStreamLength,
|
||||
IN VOID *SectionStream,
|
||||
IN BOOLEAN AllocateBuffer,
|
||||
IN UINT32 AuthenticationStatus,
|
||||
IN UINT32 AuthenticationStatus,
|
||||
OUT UINTN *SectionStreamHandle
|
||||
)
|
||||
{
|
||||
FRAMEWORK_SECTION_STREAM_NODE *NewStream;
|
||||
EFI_TPL OldTpl;
|
||||
|
||||
|
||||
//
|
||||
// Allocate a new stream
|
||||
//
|
||||
@@ -345,14 +345,14 @@ OpenSectionStreamEx (
|
||||
if (NewStream == NULL) {
|
||||
return EFI_OUT_OF_RESOURCES;
|
||||
}
|
||||
|
||||
if (AllocateBuffer) {
|
||||
|
||||
if (AllocateBuffer) {
|
||||
//
|
||||
// if we're here, we're double buffering, allocate the buffer and copy the
|
||||
// data in
|
||||
//
|
||||
if (SectionStreamLength > 0) {
|
||||
NewStream->StreamBuffer = AllocatePool (SectionStreamLength);
|
||||
NewStream->StreamBuffer = AllocatePool (SectionStreamLength);
|
||||
if (NewStream->StreamBuffer == NULL) {
|
||||
FreePool (NewStream);
|
||||
return EFI_OUT_OF_RESOURCES;
|
||||
@@ -375,7 +375,7 @@ OpenSectionStreamEx (
|
||||
//
|
||||
NewStream->StreamBuffer = SectionStream;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Initialize the rest of the section stream
|
||||
//
|
||||
@@ -384,7 +384,7 @@ OpenSectionStreamEx (
|
||||
NewStream->StreamLength = SectionStreamLength;
|
||||
InitializeListHead (&NewStream->Children);
|
||||
NewStream->AuthenticationStatus = AuthenticationStatus;
|
||||
|
||||
|
||||
//
|
||||
// Add new stream to stream list
|
||||
//
|
||||
@@ -393,7 +393,7 @@ OpenSectionStreamEx (
|
||||
gBS->RestoreTPL (OldTpl);
|
||||
|
||||
*SectionStreamHandle = NewStream->StreamHandle;
|
||||
|
||||
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
@@ -428,9 +428,9 @@ OpenSectionStream (
|
||||
if (!IsValidSectionStream (SectionStream, SectionStreamLength)) {
|
||||
return EFI_INVALID_PARAMETER;
|
||||
}
|
||||
|
||||
return OpenSectionStreamEx (
|
||||
SectionStreamLength,
|
||||
|
||||
return OpenSectionStreamEx (
|
||||
SectionStreamLength,
|
||||
SectionStream,
|
||||
TRUE,
|
||||
0,
|
||||
@@ -460,7 +460,7 @@ ChildIsType (
|
||||
)
|
||||
{
|
||||
EFI_GUID_DEFINED_SECTION *GuidedSection;
|
||||
|
||||
|
||||
if (SearchType == EFI_SECTION_ALL) {
|
||||
return TRUE;
|
||||
}
|
||||
@@ -549,7 +549,7 @@ CreateProtocolNotifyEvent (
|
||||
|
||||
@return TRUE The GuidedSectionGuid could be identified, and the pointer to
|
||||
the Guided Section Extraction Protocol will be returned to *GuidedSectionExtraction.
|
||||
@return FALSE The GuidedSectionGuid could not be identified, or
|
||||
@return FALSE The GuidedSectionGuid could not be identified, or
|
||||
the Guided Section Extraction Protocol has not been installed yet.
|
||||
|
||||
**/
|
||||
@@ -588,7 +588,7 @@ VerifyGuidedSectionGuid (
|
||||
}
|
||||
|
||||
/**
|
||||
RPN callback function.
|
||||
RPN callback function.
|
||||
1. Initialize the section stream when the GUIDED_SECTION_EXTRACTION_PROTOCOL is installed.
|
||||
2. Removes a stale section stream and re-initializes it with an updated AuthenticationStatus.
|
||||
|
||||
@@ -611,7 +611,7 @@ NotifyGuidedExtraction (
|
||||
UINTN NewStreamBufferSize;
|
||||
UINT32 AuthenticationStatus;
|
||||
RPN_EVENT_CONTEXT *Context;
|
||||
|
||||
|
||||
Context = RpnContext;
|
||||
Status = EFI_SUCCESS;
|
||||
if (Context->ChildNode->EncapsulatedStreamHandle != NULL_STREAM_HANDLE) {
|
||||
@@ -619,14 +619,14 @@ NotifyGuidedExtraction (
|
||||
}
|
||||
if (!EFI_ERROR (Status)) {
|
||||
//
|
||||
// The stream is not initialized, open it.
|
||||
// The stream is not initialized, open it.
|
||||
// Or the stream closed successfully, so re-open the stream with correct AuthenticationStatus.
|
||||
//
|
||||
|
||||
GuidedHeader = (EFI_GUID_DEFINED_SECTION *)
|
||||
|
||||
GuidedHeader = (EFI_GUID_DEFINED_SECTION *)
|
||||
(Context->ParentStream->StreamBuffer + Context->ChildNode->OffsetInStream);
|
||||
ASSERT (GuidedHeader->CommonHeader.Type == EFI_SECTION_GUID_DEFINED);
|
||||
|
||||
|
||||
if (!VerifyGuidedSectionGuid (Context->ChildNode->EncapsulationGuid, &GuidedExtraction)) {
|
||||
return;
|
||||
}
|
||||
@@ -658,11 +658,11 @@ NotifyGuidedExtraction (
|
||||
// already been closed by someone, so just destroy the event and be done with
|
||||
// it.
|
||||
//
|
||||
|
||||
|
||||
gBS->CloseEvent (Event);
|
||||
Context->ChildNode->Event = NULL;
|
||||
FreePool (Context);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
Worker function. Constructor for RPN event if needed to keep AuthenticationStatus
|
||||
@@ -679,16 +679,16 @@ CreateGuidedExtractionRpnEvent (
|
||||
)
|
||||
{
|
||||
RPN_EVENT_CONTEXT *Context;
|
||||
|
||||
|
||||
//
|
||||
// Allocate new event structure and context
|
||||
//
|
||||
Context = AllocatePool (sizeof (RPN_EVENT_CONTEXT));
|
||||
ASSERT (Context != NULL);
|
||||
|
||||
|
||||
Context->ChildNode = ChildNode;
|
||||
Context->ParentStream = ParentStream;
|
||||
|
||||
|
||||
Context->ChildNode->Event = CreateProtocolNotifyEvent (
|
||||
Context->ChildNode->EncapsulationGuid,
|
||||
TPL_NOTIFY,
|
||||
@@ -740,7 +740,7 @@ CreateChildNode (
|
||||
UINT32 UncompressedLength;
|
||||
UINT8 CompressionType;
|
||||
UINT16 GuidedSectionAttributes;
|
||||
|
||||
|
||||
FRAMEWORK_SECTION_CHILD_NODE *Node;
|
||||
|
||||
SectionHeader = (EFI_COMMON_SECTION_HEADER *) (Stream->StreamBuffer + ChildOffset);
|
||||
@@ -753,7 +753,7 @@ CreateChildNode (
|
||||
if (Node == NULL) {
|
||||
return EFI_OUT_OF_RESOURCES;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Now initialize it
|
||||
//
|
||||
@@ -767,7 +767,7 @@ CreateChildNode (
|
||||
Node->OffsetInStream = ChildOffset;
|
||||
Node->EncapsulatedStreamHandle = NULL_STREAM_HANDLE;
|
||||
Node->EncapsulationGuid = NULL;
|
||||
|
||||
|
||||
//
|
||||
// If it's an encapsulating section, then create the new section stream also
|
||||
//
|
||||
@@ -805,7 +805,7 @@ CreateChildNode (
|
||||
FreePool (Node);
|
||||
return EFI_OUT_OF_RESOURCES;
|
||||
}
|
||||
|
||||
|
||||
if (CompressionType == EFI_NOT_COMPRESSED) {
|
||||
//
|
||||
// stream is not actually compressed, just encapsulated. So just copy it.
|
||||
@@ -814,15 +814,15 @@ CreateChildNode (
|
||||
} else if (CompressionType == EFI_STANDARD_COMPRESSION) {
|
||||
//
|
||||
// Only support the EFI_SATNDARD_COMPRESSION algorithm.
|
||||
//
|
||||
//
|
||||
|
||||
//
|
||||
// Decompress the stream
|
||||
//
|
||||
Status = gBS->LocateProtocol (&gEfiDecompressProtocolGuid, NULL, (VOID **)&Decompress);
|
||||
|
||||
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
|
||||
|
||||
Status = Decompress->GetInfo (
|
||||
Decompress,
|
||||
CompressionSource,
|
||||
@@ -855,7 +855,7 @@ CreateChildNode (
|
||||
ScratchBuffer,
|
||||
ScratchSize
|
||||
);
|
||||
FreePool (ScratchBuffer);
|
||||
FreePool (ScratchBuffer);
|
||||
if (EFI_ERROR (Status)) {
|
||||
FreePool (Node);
|
||||
FreePool (NewStreamBuffer);
|
||||
@@ -866,7 +866,7 @@ CreateChildNode (
|
||||
NewStreamBuffer = NULL;
|
||||
NewStreamBufferSize = 0;
|
||||
}
|
||||
|
||||
|
||||
Status = OpenSectionStreamEx (
|
||||
NewStreamBufferSize,
|
||||
NewStreamBuffer,
|
||||
@@ -906,9 +906,9 @@ CreateChildNode (
|
||||
FreePool (*ChildNode);
|
||||
return EFI_PROTOCOL_ERROR;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Make sure we initialize the new stream with the correct
|
||||
// Make sure we initialize the new stream with the correct
|
||||
// authentication status for both aggregate and local status fields.
|
||||
//
|
||||
if ((GuidedSectionAttributes & EFI_GUIDED_SECTION_AUTH_STATUS_VALID) == EFI_GUIDED_SECTION_AUTH_STATUS_VALID) {
|
||||
@@ -923,7 +923,7 @@ CreateChildNode (
|
||||
//
|
||||
AuthenticationStatus = Stream->AuthenticationStatus;
|
||||
}
|
||||
|
||||
|
||||
Status = OpenSectionStreamEx (
|
||||
NewStreamBufferSize,
|
||||
NewStreamBuffer,
|
||||
@@ -942,8 +942,8 @@ CreateChildNode (
|
||||
//
|
||||
if ((GuidedSectionAttributes & EFI_GUIDED_SECTION_PROCESSING_REQUIRED) == EFI_GUIDED_SECTION_PROCESSING_REQUIRED) {
|
||||
//
|
||||
// If the section REQUIRES an extraction protocol, register for RPN
|
||||
// when the required GUIDed extraction protocol becomes available.
|
||||
// If the section REQUIRES an extraction protocol, register for RPN
|
||||
// when the required GUIDed extraction protocol becomes available.
|
||||
//
|
||||
AuthenticationStatus = 0;
|
||||
CreateGuidedExtractionRpnEvent (Stream, Node);
|
||||
@@ -954,11 +954,11 @@ CreateChildNode (
|
||||
AuthenticationStatus = Stream->AuthenticationStatus;
|
||||
if ((GuidedSectionAttributes & EFI_GUIDED_SECTION_AUTH_STATUS_VALID) == EFI_GUIDED_SECTION_AUTH_STATUS_VALID) {
|
||||
//
|
||||
// The local status of the new stream is contained in
|
||||
// The local status of the new stream is contained in
|
||||
// AuthenticaionStatus. This value needs to be ORed into the
|
||||
// Aggregate bits also...
|
||||
//
|
||||
|
||||
|
||||
//
|
||||
// Clear out and initialize the local status
|
||||
//
|
||||
@@ -969,7 +969,7 @@ CreateChildNode (
|
||||
//
|
||||
AuthenticationStatus |= AuthenticationStatus >> 16;
|
||||
}
|
||||
|
||||
|
||||
if (IS_SECTION2 (GuidedHeader)) {
|
||||
Status = OpenSectionStreamEx (
|
||||
SECTION2_SIZE (GuidedHeader) - ((EFI_GUID_DEFINED_SECTION2 *) GuidedHeader)->DataOffset,
|
||||
@@ -993,8 +993,8 @@ CreateChildNode (
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ((AuthenticationStatus & EFI_LOCAL_AUTH_STATUS_ALL) ==
|
||||
|
||||
if ((AuthenticationStatus & EFI_LOCAL_AUTH_STATUS_ALL) ==
|
||||
(EFI_LOCAL_AUTH_STATUS_IMAGE_SIGNED | EFI_LOCAL_AUTH_STATUS_NOT_TESTED)) {
|
||||
//
|
||||
// Need to register for RPN for when the required GUIDed extraction
|
||||
@@ -1004,17 +1004,17 @@ CreateChildNode (
|
||||
//
|
||||
CreateGuidedExtractionRpnEvent (Stream, Node);
|
||||
}
|
||||
|
||||
|
||||
break;
|
||||
|
||||
default:
|
||||
|
||||
|
||||
//
|
||||
// Nothing to do if it's a leaf
|
||||
//
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Last, add the new child node to the stream
|
||||
//
|
||||
@@ -1064,15 +1064,15 @@ FindChildNode (
|
||||
UINT32 NextChildOffset;
|
||||
EFI_STATUS ErrorStatus;
|
||||
EFI_STATUS Status;
|
||||
|
||||
|
||||
CurrentChildNode = NULL;
|
||||
ErrorStatus = EFI_NOT_FOUND;
|
||||
|
||||
|
||||
if (SourceStream->StreamLength == 0) {
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
|
||||
if (IsListEmpty (&SourceStream->Children) &&
|
||||
|
||||
if (IsListEmpty (&SourceStream->Children) &&
|
||||
SourceStream->StreamLength >= sizeof (EFI_COMMON_SECTION_HEADER)) {
|
||||
//
|
||||
// This occurs when a section stream exists, but no child sections
|
||||
@@ -1086,7 +1086,7 @@ FindChildNode (
|
||||
return Status;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// At least one child has been parsed out of the section stream. So, walk
|
||||
// through the sections that have already been parsed out looking for the
|
||||
@@ -1113,7 +1113,7 @@ FindChildNode (
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (CurrentChildNode->EncapsulatedStreamHandle != NULL_STREAM_HANDLE) {
|
||||
//
|
||||
// If the current node is an encapsulating node, recurse into it...
|
||||
@@ -1147,7 +1147,7 @@ FindChildNode (
|
||||
//
|
||||
ErrorStatus = EFI_PROTOCOL_ERROR;
|
||||
}
|
||||
|
||||
|
||||
if (!IsNodeAtEnd (&SourceStream->Children, &CurrentChildNode->Link)) {
|
||||
//
|
||||
// We haven't found the child node we're interested in yet, but there's
|
||||
@@ -1199,9 +1199,9 @@ FindStreamNode (
|
||||
IN UINTN SearchHandle,
|
||||
OUT FRAMEWORK_SECTION_STREAM_NODE **FoundStream
|
||||
)
|
||||
{
|
||||
{
|
||||
FRAMEWORK_SECTION_STREAM_NODE *StreamNode;
|
||||
|
||||
|
||||
if (!IsListEmpty (&mStreamRoot)) {
|
||||
StreamNode = STREAM_NODE_FROM_LINK (GetFirstNode (&mStreamRoot));
|
||||
for (;;) {
|
||||
@@ -1215,10 +1215,10 @@ FindStreamNode (
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return EFI_NOT_FOUND;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
SEP member function. Retrieves requested section from section stream.
|
||||
|
||||
@@ -1242,22 +1242,22 @@ FindStreamNode (
|
||||
@param AuthenticationStatus Indicates the authentication status of the retrieved
|
||||
section.
|
||||
|
||||
|
||||
|
||||
@retval EFI_SUCCESS Section was retrieved successfully
|
||||
@retval EFI_PROTOCOL_ERROR A GUID defined section was encountered in the section
|
||||
@retval EFI_PROTOCOL_ERROR A GUID defined section was encountered in the section
|
||||
stream with its EFI_GUIDED_SECTION_PROCESSING_REQUIRED
|
||||
bit set, but there was no corresponding GUIDed Section
|
||||
Extraction Protocol in the handle database. *Buffer is
|
||||
bit set, but there was no corresponding GUIDed Section
|
||||
Extraction Protocol in the handle database. *Buffer is
|
||||
unmodified.
|
||||
@retval EFI_NOT_FOUND An error was encountered when parsing the SectionStream.
|
||||
This indicates the SectionStream is not correctly
|
||||
This indicates the SectionStream is not correctly
|
||||
formatted.
|
||||
@retval EFI_NOT_FOUND The requested section does not exist.
|
||||
@retval EFI_OUT_OF_RESOURCES The system has insufficient resources to process the
|
||||
@retval EFI_OUT_OF_RESOURCES The system has insufficient resources to process the
|
||||
request.
|
||||
@retval EFI_INVALID_PARAMETER The SectionStreamHandle does not exist.
|
||||
@retval EFI_WARN_TOO_SMALL The size of the caller allocated input buffer is
|
||||
insufficient to contain the requested section. The
|
||||
@retval EFI_WARN_TOO_SMALL The size of the caller allocated input buffer is
|
||||
insufficient to contain the requested section. The
|
||||
input buffer is filled and contents are section contents
|
||||
are truncated.
|
||||
|
||||
@@ -1286,12 +1286,12 @@ GetSection (
|
||||
UINT8 *CopyBuffer;
|
||||
UINTN SectionSize;
|
||||
EFI_COMMON_SECTION_HEADER *Section;
|
||||
|
||||
|
||||
|
||||
OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
|
||||
Instance = SectionInstance + 1;
|
||||
ChildStreamNode = NULL;
|
||||
|
||||
|
||||
//
|
||||
// Locate target stream
|
||||
//
|
||||
@@ -1300,7 +1300,7 @@ GetSection (
|
||||
Status = EFI_INVALID_PARAMETER;
|
||||
goto GetSection_Done;
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Found the stream, now locate and return the appropriate section
|
||||
//
|
||||
@@ -1316,12 +1316,12 @@ GetSection (
|
||||
// There's a requested section type, so go find it and return it...
|
||||
//
|
||||
Status = FindChildNode (
|
||||
StreamNode,
|
||||
*SectionType,
|
||||
&Instance,
|
||||
StreamNode,
|
||||
*SectionType,
|
||||
&Instance,
|
||||
SectionDefinitionGuid,
|
||||
&ChildNode,
|
||||
&ChildStreamNode,
|
||||
&ChildStreamNode,
|
||||
&ExtractedAuthenticationStatus
|
||||
);
|
||||
if (EFI_ERROR (Status)) {
|
||||
@@ -1339,9 +1339,9 @@ GetSection (
|
||||
CopyBuffer = (UINT8 *) Section + sizeof (EFI_COMMON_SECTION_HEADER);
|
||||
}
|
||||
*AuthenticationStatus = ExtractedAuthenticationStatus;
|
||||
}
|
||||
|
||||
SectionSize = CopySize;
|
||||
}
|
||||
|
||||
SectionSize = CopySize;
|
||||
if (*Buffer != NULL) {
|
||||
//
|
||||
// Caller allocated buffer. Fill to size and return required size...
|
||||
@@ -1362,7 +1362,7 @@ GetSection (
|
||||
}
|
||||
CopyMem (*Buffer, CopyBuffer, CopySize);
|
||||
*BufferSize = SectionSize;
|
||||
|
||||
|
||||
GetSection_Done:
|
||||
gBS->RestoreTPL (OldTpl);
|
||||
return Status;
|
||||
@@ -1384,7 +1384,7 @@ FreeChildNode (
|
||||
// Remove the child from it's list
|
||||
//
|
||||
RemoveEntryList (&ChildNode->Link);
|
||||
|
||||
|
||||
if (ChildNode->EncapsulatedStreamHandle != NULL_STREAM_HANDLE) {
|
||||
//
|
||||
// If it's an encapsulating section, we close the resulting section stream.
|
||||
@@ -1401,7 +1401,7 @@ FreeChildNode (
|
||||
// Last, free the child node itself
|
||||
//
|
||||
FreePool (ChildNode);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
SEP member function. Deletes an existing section stream
|
||||
@@ -1427,9 +1427,9 @@ CloseSectionStream (
|
||||
EFI_STATUS Status;
|
||||
LIST_ENTRY *Link;
|
||||
FRAMEWORK_SECTION_CHILD_NODE *ChildNode;
|
||||
|
||||
|
||||
OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
|
||||
|
||||
|
||||
//
|
||||
// Locate target stream
|
||||
//
|
||||
@@ -1450,7 +1450,7 @@ CloseSectionStream (
|
||||
} else {
|
||||
Status = EFI_INVALID_PARAMETER;
|
||||
}
|
||||
|
||||
|
||||
gBS->RestoreTPL (OldTpl);
|
||||
return Status;
|
||||
}
|
||||
|
@@ -4,16 +4,16 @@
|
||||
# The section is implemented as a linked list of section streams,
|
||||
# where each stream contains a linked list of children, which may be leaves or
|
||||
# encapsulations. Encapsulation section will further generate new section stream entries.
|
||||
#
|
||||
# Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
#
|
||||
# Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
# 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
|
||||
# http://opensource.org/licenses/bsd-license.php
|
||||
#
|
||||
#
|
||||
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
#
|
||||
#
|
||||
##
|
||||
|
||||
[Defines]
|
||||
@@ -23,7 +23,7 @@
|
||||
FILE_GUID = 801ADCA0-815E-46a4-84F7-657F53621A57
|
||||
MODULE_TYPE = DXE_DRIVER
|
||||
VERSION_STRING = 1.0
|
||||
ENTRY_POINT = SectionExtractionEntryPoint
|
||||
ENTRY_POINT = SectionExtractionEntryPoint
|
||||
|
||||
# The following information is for reference only and not required by the build tools.
|
||||
#
|
||||
|
@@ -5,13 +5,13 @@
|
||||
// where each stream contains a linked list of children, which may be leaves or
|
||||
// encapsulations. Encapsulation section will further generate new section stream entries.
|
||||
//
|
||||
// Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// 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
|
||||
// http://opensource.org/licenses/bsd-license.php
|
||||
//
|
||||
//
|
||||
// THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
//
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// SectionExtractionDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials
|
||||
// are licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -13,8 +13,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"Firmware Storage Extraction DXE Driver"
|
||||
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Data Hub status code worker.
|
||||
|
||||
Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2010 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -62,7 +62,7 @@ AcquireRecordBuffer (
|
||||
if (CurrentTpl > TPL_NOTIFY) {
|
||||
//
|
||||
// Memory management should work at <=TPL_NOTIFY
|
||||
//
|
||||
//
|
||||
gBS->RestoreTPL (CurrentTpl);
|
||||
return NULL;
|
||||
}
|
||||
@@ -132,7 +132,7 @@ RetrieveRecord (
|
||||
|
||||
/**
|
||||
Release given record and return it to free record buffer.
|
||||
|
||||
|
||||
@param RecordData Pointer to the record to release.
|
||||
|
||||
**/
|
||||
@@ -348,8 +348,8 @@ DataHubStatusCodeInitializeWorker (
|
||||
EFI_STATUS Status;
|
||||
|
||||
Status = gBS->LocateProtocol (
|
||||
&gEfiDataHubProtocolGuid,
|
||||
NULL,
|
||||
&gEfiDataHubProtocolGuid,
|
||||
NULL,
|
||||
(VOID **) &mDataHubProtocol
|
||||
);
|
||||
if (EFI_ERROR (Status)) {
|
||||
|
@@ -2,7 +2,7 @@
|
||||
Status Code Handler Driver which produces datahub handler and hook it
|
||||
onto the DXE status code router.
|
||||
|
||||
Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2010 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -45,7 +45,7 @@ UnregisterBootTimeHandlers (
|
||||
|
||||
@param ImageHandle The firmware allocated handle for the EFI image.
|
||||
@param SystemTable A pointer to the EFI System Table.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The entry point is executed successfully.
|
||||
|
||||
**/
|
||||
|
@@ -1,7 +1,7 @@
|
||||
## @file
|
||||
# Status Code Handler Driver which produces datahub handler.
|
||||
#
|
||||
# Copyright (c) 2011 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
# Copyright (c) 2011 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
#
|
||||
# This program and the accompanying materials
|
||||
# are licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -19,7 +19,7 @@
|
||||
MODULE_UNI_FILE = DatahubStatusCodeHandlerDxe.uni
|
||||
FILE_GUID = 863D214F-0920-437B-8CAD-88EA83A24E97
|
||||
MODULE_TYPE = DXE_DRIVER
|
||||
VERSION_STRING = 1.0
|
||||
VERSION_STRING = 1.0
|
||||
ENTRY_POINT = DatahubStatusCodeHandlerDxeEntry
|
||||
|
||||
#
|
||||
@@ -32,13 +32,13 @@
|
||||
DatahubStatusCodeHandlerDxe.h
|
||||
DatahubStatusCodeHandlerDxe.c
|
||||
DataHubStatusCodeWorker.c
|
||||
|
||||
|
||||
[Packages]
|
||||
MdePkg/MdePkg.dec
|
||||
MdeModulePkg/MdeModulePkg.dec
|
||||
IntelFrameworkPkg/IntelFrameworkPkg.dec
|
||||
IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec
|
||||
|
||||
|
||||
[LibraryClasses]
|
||||
BaseLib
|
||||
MemoryAllocationLib
|
||||
@@ -50,12 +50,12 @@
|
||||
DebugLib
|
||||
SynchronizationLib
|
||||
BaseMemoryLib
|
||||
|
||||
|
||||
[Guids]
|
||||
gEfiEventExitBootServicesGuid ## CONSUMES ## Event
|
||||
gEfiDataHubStatusCodeRecordGuid ## PRODUCES ## UNDEFINED # DataRecord Guid
|
||||
gEfiStatusCodeDataTypeDebugGuid ## SOMETIMES_PRODUCES ## UNDEFINED # Record data type
|
||||
|
||||
|
||||
[Protocols]
|
||||
gEfiRscHandlerProtocolGuid ## CONSUMES
|
||||
gEfiDataHubProtocolGuid ## CONSUMES
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// DatahubStatusCodeHandlerDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials
|
||||
// are licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -12,8 +12,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"Data Hub Status Code DXE Driver"
|
||||
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
PEI memory status code worker.
|
||||
|
||||
Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -81,7 +81,7 @@ MemoryStatusCodeReportWorker (
|
||||
MEMORY_STATUSCODE_RECORD *Record;
|
||||
|
||||
//
|
||||
// Find GUID'ed HOBs to locate current record buffer.
|
||||
// Find GUID'ed HOBs to locate current record buffer.
|
||||
//
|
||||
Hob.Raw = GetFirstGuidHob (&gMemoryStatusCodeRecordGuid);
|
||||
ASSERT (Hob.Raw != NULL);
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Status code PEIM which produces Status Code PPI.
|
||||
|
||||
Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -95,7 +95,7 @@ ReportDispatcher (
|
||||
|
||||
/**
|
||||
Entry point of Status Code PEIM.
|
||||
|
||||
|
||||
This function is the entry point of this Status Code PEIM.
|
||||
It initializes supported status code devices according to PCD settings,
|
||||
and installs Status Code PPI.
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// StatusCodePei Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials
|
||||
// are licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -12,8 +12,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"Status Code PEI Module"
|
||||
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Data Hub status code worker.
|
||||
|
||||
Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -62,7 +62,7 @@ AcquireRecordBuffer (
|
||||
if (CurrentTpl > TPL_NOTIFY) {
|
||||
//
|
||||
// Memory management should work at <=TPL_NOTIFY
|
||||
//
|
||||
//
|
||||
gBS->RestoreTPL (CurrentTpl);
|
||||
return NULL;
|
||||
}
|
||||
@@ -132,7 +132,7 @@ RetrieveRecord (
|
||||
|
||||
/**
|
||||
Release given record and return it to free record buffer.
|
||||
|
||||
|
||||
@param RecordData Pointer to the record to release.
|
||||
|
||||
**/
|
||||
@@ -212,7 +212,7 @@ DataHubStatusCodeReportWorker (
|
||||
return Status;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Record = AcquireRecordBuffer ();
|
||||
if (Record == NULL) {
|
||||
//
|
||||
@@ -362,8 +362,8 @@ DataHubStatusCodeInitializeWorker (
|
||||
EFI_STATUS Status;
|
||||
|
||||
Status = gBS->LocateProtocol (
|
||||
&gEfiDataHubProtocolGuid,
|
||||
NULL,
|
||||
&gEfiDataHubProtocolGuid,
|
||||
NULL,
|
||||
(VOID **) &mDataHubProtocol
|
||||
);
|
||||
if (EFI_ERROR (Status)) {
|
||||
|
@@ -1,14 +1,14 @@
|
||||
/** @file
|
||||
Runtime memory status code worker.
|
||||
|
||||
Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
**/
|
||||
|
||||
@@ -18,7 +18,7 @@ RUNTIME_MEMORY_STATUSCODE_HEADER *mRtMemoryStatusCodeTable;
|
||||
|
||||
/**
|
||||
Initialize runtime memory status code table as initialization for runtime memory status code worker
|
||||
|
||||
|
||||
@retval EFI_SUCCESS Runtime memory status code table successfully initialized.
|
||||
|
||||
**/
|
||||
@@ -38,7 +38,7 @@ RtMemoryStatusCodeInitializeWorker (
|
||||
|
||||
mRtMemoryStatusCodeTable->RecordIndex = 0;
|
||||
mRtMemoryStatusCodeTable->NumberOfRecords = 0;
|
||||
mRtMemoryStatusCodeTable->MaxRecordsNumber =
|
||||
mRtMemoryStatusCodeTable->MaxRecordsNumber =
|
||||
(PcdGet16 (PcdStatusCodeMemorySize) * 1024) / sizeof (MEMORY_STATUSCODE_RECORD);
|
||||
|
||||
return EFI_SUCCESS;
|
||||
@@ -46,16 +46,16 @@ RtMemoryStatusCodeInitializeWorker (
|
||||
|
||||
|
||||
/**
|
||||
Report status code into runtime memory. If the runtime pool is full, roll back to the
|
||||
Report status code into runtime memory. If the runtime pool is full, roll back to the
|
||||
first record and overwrite it.
|
||||
|
||||
|
||||
@param CodeType Indicates the type of status code being reported.
|
||||
@param Value Describes the current status of a hardware or software entity.
|
||||
This included information about the class and subclass that is used to
|
||||
classify the entity as well as an operation.
|
||||
@param Instance The enumeration of a hardware or software entity within
|
||||
the system. Valid instance numbers start with 1.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS Status code successfully recorded in runtime memory status code table.
|
||||
|
||||
**/
|
||||
|
@@ -1,14 +1,14 @@
|
||||
/** @file
|
||||
Serial I/O status code reporting worker.
|
||||
|
||||
Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
http://opensource.org/licenses/bsd-license.php
|
||||
|
||||
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
||||
|
||||
**/
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
/**
|
||||
Convert status code value and extended data to readable ASCII string, send string to serial I/O device.
|
||||
|
||||
|
||||
@param CodeType Indicates the type of status code being reported.
|
||||
@param Value Describes the current status of a hardware or software entity.
|
||||
This included information about the class and subclass that is used to
|
||||
@@ -72,9 +72,9 @@ SerialStatusCodeReportWorker (
|
||||
// Print DEBUG() information into output buffer.
|
||||
//
|
||||
CharCount = AsciiBSPrint (
|
||||
Buffer,
|
||||
sizeof (Buffer),
|
||||
Format,
|
||||
Buffer,
|
||||
sizeof (Buffer),
|
||||
Format,
|
||||
Marker
|
||||
);
|
||||
} else if ((CodeType & EFI_STATUS_CODE_TYPE_MASK) == EFI_ERROR_CODE) {
|
||||
@@ -82,14 +82,14 @@ SerialStatusCodeReportWorker (
|
||||
// Print ERROR information into output buffer.
|
||||
//
|
||||
CharCount = AsciiSPrint (
|
||||
Buffer,
|
||||
sizeof (Buffer),
|
||||
"ERROR: C%08x:V%08x I%x",
|
||||
CodeType,
|
||||
Value,
|
||||
Buffer,
|
||||
sizeof (Buffer),
|
||||
"ERROR: C%08x:V%08x I%x",
|
||||
CodeType,
|
||||
Value,
|
||||
Instance
|
||||
);
|
||||
|
||||
|
||||
if (CallerId != NULL) {
|
||||
CharCount += AsciiSPrint (
|
||||
&Buffer[CharCount],
|
||||
@@ -118,10 +118,10 @@ SerialStatusCodeReportWorker (
|
||||
// Print PROGRESS information into output buffer.
|
||||
//
|
||||
CharCount = AsciiSPrint (
|
||||
Buffer,
|
||||
sizeof (Buffer),
|
||||
"PROGRESS CODE: V%08x I%x\n\r",
|
||||
Value,
|
||||
Buffer,
|
||||
sizeof (Buffer),
|
||||
"PROGRESS CODE: V%08x I%x\n\r",
|
||||
Value,
|
||||
Instance
|
||||
);
|
||||
} else if (Data != NULL &&
|
||||
@@ -141,11 +141,11 @@ SerialStatusCodeReportWorker (
|
||||
// Code type is not defined.
|
||||
//
|
||||
CharCount = AsciiSPrint (
|
||||
Buffer,
|
||||
sizeof (Buffer),
|
||||
"Undefined: C%08x:V%08x I%x\n\r",
|
||||
CodeType,
|
||||
Value,
|
||||
Buffer,
|
||||
sizeof (Buffer),
|
||||
"Undefined: C%08x:V%08x I%x\n\r",
|
||||
CodeType,
|
||||
Value,
|
||||
Instance
|
||||
);
|
||||
}
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Status code driver for IA32/X64/EBC architecture.
|
||||
|
||||
Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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
|
||||
@@ -38,7 +38,7 @@ UINT32 mStatusCodeNestStatus = 0;
|
||||
|
||||
@param ImageHandle The firmware allocated handle for the EFI image.
|
||||
@param SystemTable A pointer to the EFI System Table.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS The entry point is executed successfully.
|
||||
|
||||
**/
|
||||
@@ -192,9 +192,9 @@ VirtualAddressChangeCallBack (
|
||||
}
|
||||
|
||||
/**
|
||||
Dispatch initialization request to sub status code devices based on
|
||||
Dispatch initialization request to sub status code devices based on
|
||||
customized feature flags.
|
||||
|
||||
|
||||
**/
|
||||
VOID
|
||||
InitializationDispatcherWorker (
|
||||
@@ -236,11 +236,11 @@ InitializationDispatcherWorker (
|
||||
}
|
||||
|
||||
//
|
||||
// Replay Status code which saved in GUID'ed HOB to all supported devices.
|
||||
// Replay Status code which saved in GUID'ed HOB to all supported devices.
|
||||
//
|
||||
if (FeaturePcdGet (PcdStatusCodeReplayIn)) {
|
||||
//
|
||||
// Journal GUID'ed HOBs to find all record entry, if found,
|
||||
//
|
||||
// Journal GUID'ed HOBs to find all record entry, if found,
|
||||
// then output record to support replay device.
|
||||
//
|
||||
Hob.Raw = GetFirstGuidHob (&gMemoryStatusCodeRecordGuid);
|
||||
|
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
Internal include file of Status Code Runtime DXE Driver.
|
||||
|
||||
Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
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,9 +87,9 @@ ReportDispatcher (
|
||||
);
|
||||
|
||||
/**
|
||||
Dispatch initialization request to sub status code devices based on
|
||||
Dispatch initialization request to sub status code devices based on
|
||||
customized feature flags.
|
||||
|
||||
|
||||
**/
|
||||
VOID
|
||||
InitializationDispatcherWorker (
|
||||
@@ -99,7 +99,7 @@ InitializationDispatcherWorker (
|
||||
|
||||
/**
|
||||
Locates Serial I/O Protocol as initialization for serial status code worker.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS Serial I/O Protocol is successfully located.
|
||||
|
||||
**/
|
||||
@@ -111,7 +111,7 @@ EfiSerialStatusCodeInitializeWorker (
|
||||
|
||||
/**
|
||||
Convert status code value and extended data to readable ASCII string, send string to serial I/O device.
|
||||
|
||||
|
||||
@param CodeType Indicates the type of status code being reported.
|
||||
@param Value Describes the current status of a hardware or software entity.
|
||||
This included information about the class and subclass that is used to
|
||||
@@ -139,7 +139,7 @@ SerialStatusCodeReportWorker (
|
||||
|
||||
/**
|
||||
Initialize runtime memory status code table as initialization for runtime memory status code worker
|
||||
|
||||
|
||||
@retval EFI_SUCCESS Runtime memory status code table successfully initialized.
|
||||
|
||||
**/
|
||||
@@ -149,16 +149,16 @@ RtMemoryStatusCodeInitializeWorker (
|
||||
);
|
||||
|
||||
/**
|
||||
Report status code into runtime memory. If the runtime pool is full, roll back to the
|
||||
Report status code into runtime memory. If the runtime pool is full, roll back to the
|
||||
first record and overwrite it.
|
||||
|
||||
|
||||
@param CodeType Indicates the type of status code being reported.
|
||||
@param Value Describes the current status of a hardware or software entity.
|
||||
This included information about the class and subclass that is used to
|
||||
classify the entity as well as an operation.
|
||||
@param Instance The enumeration of a hardware or software entity within
|
||||
the system. Valid instance numbers start with 1.
|
||||
|
||||
|
||||
@retval EFI_SUCCESS Status code successfully recorded in runtime memory status code table.
|
||||
|
||||
**/
|
||||
|
@@ -1,7 +1,7 @@
|
||||
// /** @file
|
||||
// StatusCodeRuntimeDxe Localized Strings and Content
|
||||
//
|
||||
// Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
|
||||
// Copyright (c) 2013 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
//
|
||||
// This program and the accompanying materials
|
||||
// are licensed and made available under the terms and conditions of the BSD License
|
||||
@@ -12,8 +12,8 @@
|
||||
//
|
||||
// **/
|
||||
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
#string STR_PROPERTIES_MODULE_NAME
|
||||
#language en-US
|
||||
"Status Code Runtime DXE Driver"
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user