Code scrub for PlatformBdsLibNull.inf library instance.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6801 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
klu2 2008-12-02 08:09:28 +00:00
parent 7e6a7a6378
commit e6b7d45e9d
5 changed files with 107 additions and 190 deletions

View File

@ -29,21 +29,21 @@ struct _EFI_BDS_ARCH_PROTOCOL_INSTANCE {
UINTN Signature;
EFI_HANDLE Handle;
EFI_BDS_ARCH_PROTOCOL Bds;
//
// Save the current boot mode
//
///
/// Save the current boot mode
///
EFI_BOOT_MODE BootMode;
//
// Set true if boot with default settings
//
///
/// Set true if boot with default settings
///
BOOLEAN DefaultBoot;
//
// The system default timeout for choose the boot option
//
///
/// The system default timeout for choose the boot option
///
UINT16 TimeoutDefault;
//
// Memory Test Level
//
///
/// Memory Test Level
///
EXTENDMEM_COVERAGE_LEVEL MemoryTestLevel;
};

View File

@ -1,6 +1,5 @@
/** @file
This file include all platform action which can be customized
by IBV/OEM.
This file include all platform action which can be customized by IBV/OEM.
Copyright (c) 2004 - 2008, Intel Corporation. <BR>
All rights reserved. This program and the accompanying materials
@ -18,191 +17,132 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
//
// BDS Platform Functions
//
/**
Platform Bds init. Include the platform firmware vendor, revision
and so crc check.
@param PrivateData The EFI_BDS_ARCH_PROTOCOL_INSTANCE instance
**/
VOID
PlatformBdsInit (
IN EFI_BDS_ARCH_PROTOCOL_INSTANCE *PrivateData
)
/*++
Routine Description:
Platform Bds init. Incude the platform firmware vendor, revision
and so crc check.
Arguments:
PrivateData - The EFI_BDS_ARCH_PROTOCOL_INSTANCE instance
Returns:
None.
--*/
{
return;
}
/**
Connect the predefined platform default console device. Always try to find
and enable the vga device if have.
@param PlatformConsole Predfined platform default console device array.
@retval EFI_SUCCESS Success connect at least one ConIn and ConOut
device, there must have one ConOut device is
active vga device.
@return Return the status of BdsLibConnectAllDefaultConsoles ()
**/
EFI_STATUS
PlatformBdsConnectConsole (
IN BDS_CONSOLE_CONNECT_ENTRY *PlatformConsole
)
/*++
Routine Description:
Connect the predefined platform default console device. Always try to find
and enable the vga device if have.
Arguments:
PlatformConsole - Predfined platform default console device array.
Returns:
EFI_SUCCESS - Success connect at least one ConIn and ConOut
device, there must have one ConOut device is
active vga device.
EFI_STATUS - Return the status of
BdsLibConnectAllDefaultConsoles ()
--*/
{
return EFI_SUCCESS;
}
/**
Connect with predeined platform connect sequence,
the OEM/IBV can customize with their own connect sequence.
**/
VOID
PlatformBdsConnectSequence (
VOID
)
/*++
Routine Description:
Connect with predeined platform connect sequence,
the OEM/IBV can customize with their own connect sequence.
Arguments:
None.
Returns:
None.
--*/
{
return;
}
/**
Load the predefined driver option, OEM/IBV can customize this
to load their own drivers
@param BdsDriverLists - The header of the driver option link list.
**/
VOID
PlatformBdsGetDriverOption (
IN OUT LIST_ENTRY *BdsDriverLists
)
/*++
Routine Description:
Load the predefined driver option, OEM/IBV can customize this
to load their own drivers
Arguments:
BdsDriverLists - The header of the driver option link list.
Returns:
None.
--*/
{
return;
}
/**
Perform the platform diagnostic, such like test memory. OEM/IBV also
can customize this fuction to support specific platform diagnostic.
@param MemoryTestLevel The memory test intensive level
@param QuietBoot Indicate if need to enable the quiet boot
**/
VOID
PlatformBdsDiagnostics (
IN EXTENDMEM_COVERAGE_LEVEL MemoryTestLevel,
IN BOOLEAN QuietBoot
)
/*++
Routine Description:
Perform the platform diagnostic, such like test memory. OEM/IBV also
can customize this fuction to support specific platform diagnostic.
Arguments:
MemoryTestLevel - The memory test intensive level
QuietBoot - Indicate if need to enable the quiet boot
Returns:
None.
--*/
{
return;
}
/**
The function will excute with as the platform policy, current policy
is driven by boot mode. IBV/OEM can customize this code for their specific
policy action.
@param PrivateData The EFI_BDS_ARCH_PROTOCOL_INSTANCE instance
@param DriverOptionList The header of the driver option link list
@param BootOptionList The header of the boot option link list
**/
VOID
PlatformBdsPolicyBehavior (
IN EFI_BDS_ARCH_PROTOCOL_INSTANCE *PrivateData,
IN OUT LIST_ENTRY *DriverOptionList,
IN OUT LIST_ENTRY *BootOptionList
)
/*++
Routine Description:
The function will excute with as the platform policy, current policy
is driven by boot mode. IBV/OEM can customize this code for their specific
policy action.
Arguments:
PrivateData - The EFI_BDS_ARCH_PROTOCOL_INSTANCE instance
DriverOptionList - The header of the driver option link list
BootOptionList - The header of the boot option link list
Returns:
None.
--*/
{
return ;
}
VOID
PlatformBdsBootSuccess (
IN BDS_COMMON_OPTION *Option
)
/*++
Routine Description:
/**
Hook point after a boot attempt succeeds. We don't expect a boot option to
return, so the EFI 1.0 specification defines that you will default to an
interactive mode and stop processing the BootOrder list in this case. This
is alos a platform implementation and can be customized by IBV/OEM.
Arguments:
@param Option Pointer to Boot Option that succeeded to boot.
Option - Pointer to Boot Option that succeeded to boot.
Returns:
None.
--*/
**/
VOID
PlatformBdsBootSuccess (
IN BDS_COMMON_OPTION *Option
)
{
return;
}
/**
Hook point after a boot attempt fails.
@param Option Pointer to Boot Option that failed to boot.
@param Status Status returned from failed boot.
@param ExitData Exit data returned from failed boot.
@param ExitDataSize Exit data size returned from failed boot.
**/
VOID
PlatformBdsBootFail (
IN BDS_COMMON_OPTION *Option,
@ -210,55 +150,31 @@ PlatformBdsBootFail (
IN CHAR16 *ExitData,
IN UINTN ExitDataSize
)
/*++
Routine Description:
Hook point after a boot attempt fails.
Arguments:
Option - Pointer to Boot Option that failed to boot.
Status - Status returned from failed boot.
ExitData - Exit data returned from failed boot.
ExitDataSize - Exit data size returned from failed boot.
Returns:
None.
--*/
{
return;
}
/**
This function is remained for IBV/OEM to do some platform action,
if there no console device can be connected.
@return EFI_SUCCESS Direct return success now.
**/
EFI_STATUS
PlatformBdsNoConsoleAction (
VOID
)
/*++
Routine Description:
This function is remained for IBV/OEM to do some platform action,
if there no console device can be connected.
Arguments:
None.
Returns:
EFI_SUCCESS - Direct return success now.
--*/
{
return EFI_SUCCESS;
}
/**
This function locks platform flash that is not allowed to be updated during normal boot path.
The flash layout is platform specific.
@retval EFI_SUCCESS The non-updatable flash areas.
**/
EFI_STATUS
EFIAPI
PlatformBdsLockNonUpdatableFlash (

View File

@ -12,8 +12,8 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
#ifndef _BDS_PLATFORM_H
#define _BDS_PLATFORM_H
#ifndef _BDS_PLATFORM_H_
#define _BDS_PLATFORM_H_
#include <PiDxe.h>

View File

@ -1,6 +1,7 @@
#/** @file
#
# Component name for module GenericBdsLib
# Provide NULL implementation for PlatformBdsLib library class interfaces which
# should be implemented by OEM.
#
# Copyright (c) 2007 - 2008, Intel Corporation. <BR>
# All rights reserved. This program and the accompanying materials

View File

@ -15,18 +15,18 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include "BdsPlatform.h"
//
// Predefined platform default time out value
//
///
/// Predefined platform default time out value
///
UINT16 gPlatformBootTimeOutDefault = 10;
//
// Platform specific keyboard device path
//
//
// Predefined platform default console device path
//
///
/// Predefined platform default console device path
///
BDS_CONSOLE_CONNECT_ENTRY gPlatformConsole[] = {
{
NULL,
@ -34,12 +34,12 @@ BDS_CONSOLE_CONNECT_ENTRY gPlatformConsole[] = {
}
};
//
// Predefined platform specific driver option
//
///
/// Predefined platform specific driver option
///
EFI_DEVICE_PATH_PROTOCOL *gPlatformDriverOption[] = { NULL };
//
// Predefined platform connect sequence
//
///
/// Predefined platform connect sequence
///
EFI_DEVICE_PATH_PROTOCOL *gPlatformConnectSequence[] = { NULL };