diff options
author | xli24 <xli24@6f19259b-4bc3-4df7-8a09-765794883524> | 2007-01-31 04:57:46 +0000 |
---|---|---|
committer | xli24 <xli24@6f19259b-4bc3-4df7-8a09-765794883524> | 2007-01-31 04:57:46 +0000 |
commit | 92dda53e9fe6568c9204ffd97f146710bdde3369 (patch) | |
tree | 6e555e93dae8c4ea49d503ecae1f56b3d4d2db3a | |
parent | 86e6bb786f6f23201a2041901362e08b80681930 (diff) | |
download | edk2-platforms-92dda53e9fe6568c9204ffd97f146710bdde3369.tar.xz |
Make EdkModulePkg pass Intel IPF compiler with /W4 /WX switches, solving warning #1419.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2338 6f19259b-4bc3-4df7-8a09-765794883524
100 files changed, 2096 insertions, 2043 deletions
diff --git a/EdkModulePkg/Application/HelloWorld/HelloWorld.c b/EdkModulePkg/Application/HelloWorld/HelloWorld.c index 18705100be..cd6113fb77 100644 --- a/EdkModulePkg/Application/HelloWorld/HelloWorld.c +++ b/EdkModulePkg/Application/HelloWorld/HelloWorld.c @@ -33,13 +33,6 @@ EFIAPI UefiMain (
IN EFI_HANDLE ImageHandle,
IN EFI_SYSTEM_TABLE *SystemTable
- );
-
-EFI_STATUS
-EFIAPI
-UefiMain (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
)
{
diff --git a/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/AtapiPassThru.c b/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/AtapiPassThru.c index 28be3f7026..96ed4d5c6b 100644 --- a/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/AtapiPassThru.c +++ b/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/AtapiPassThru.c @@ -12,31 +12,6 @@ #include "AtapiPassThru.h"
-EFI_STATUS
-EFIAPI
-AtapiScsiPassThruDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-AtapiScsiPassThruDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-AtapiScsiPassThruDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
///
/// IDE registers' fixed address
///
diff --git a/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/AtapiPassThru.h b/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/AtapiPassThru.h index fda5736878..f14388be95 100644 --- a/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/AtapiPassThru.h +++ b/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/AtapiPassThru.h @@ -236,6 +236,53 @@ typedef struct { //
// function prototype
//
+
+EFI_STATUS
+EFIAPI
+AtapiScsiPassThruDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+AtapiScsiPassThruDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+AtapiScsiPassThruDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+AtapiScsiPassThruComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+AtapiScsiPassThruComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
/**
AtapiScsiPassThruDriverEntryPoint
diff --git a/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/ComponentName.c b/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/ComponentName.c index b0b2231705..1731571069 100644 --- a/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/ComponentName.c +++ b/EdkModulePkg/Bus/Pci/AtapiPassThru/Dxe/ComponentName.c @@ -13,27 +13,6 @@ **/
#include "AtapiPassThru.h"
-//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-AtapiScsiPassThruComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-AtapiScsiPassThruComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
///
/// EFI Component Name Protocol
///
diff --git a/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/CirrusLogic5430.h b/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/CirrusLogic5430.h index b1984c8865..af841b704f 100644 --- a/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/CirrusLogic5430.h +++ b/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/CirrusLogic5430.h @@ -62,6 +62,19 @@ typedef struct { UINT8 *LineBuffer;
} CIRRUS_LOGIC_5430_PRIVATE_DATA;
+///
+/// Video Mode structure
+///
+typedef struct {
+ UINT32 Width;
+ UINT32 Height;
+ UINT32 ColorDepth;
+ UINT32 RefreshRate;
+ UINT8 *CrtcSettings;
+ UINT16 *SeqSettings;
+ UINT8 MiscSetting;
+} CIRRUS_LOGIC_5430_VIDEO_MODES;
+
#define CIRRUS_LOGIC_5430_PRIVATE_DATA_FROM_UGA_DRAW_THIS(a) \
CR(a, CIRRUS_LOGIC_5430_PRIVATE_DATA, UgaDraw, CIRRUS_LOGIC_5430_PRIVATE_DATA_SIGNATURE)
@@ -200,4 +213,79 @@ CirrusLogic5430ControllerDriverStop ( )
;
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+CirrusLogic5430ComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+CirrusLogic5430ComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
+//
+// Local Function Prototypes
+//
+VOID
+InitializeGraphicsMode (
+ CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
+ CIRRUS_LOGIC_5430_VIDEO_MODES *ModeData
+ );
+
+VOID
+SetPaletteColor (
+ CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
+ UINTN Index,
+ UINT8 Red,
+ UINT8 Green,
+ UINT8 Blue
+ );
+
+VOID
+SetDefaultPalette (
+ CIRRUS_LOGIC_5430_PRIVATE_DATA *Private
+ );
+
+VOID
+DrawLogo (
+ CIRRUS_LOGIC_5430_PRIVATE_DATA *Private
+ );
+
+VOID
+outb (
+ CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
+ UINTN Address,
+ UINT8 Data
+ );
+
+VOID
+outw (
+ CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
+ UINTN Address,
+ UINT16 Data
+ );
+
+UINT8
+inb (
+ CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
+ UINTN Address
+ );
+
+UINT16
+inw (
+ CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
+ UINTN Address
+ );
+
#endif
diff --git a/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/CirrusLogic5430UgaDraw.c b/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/CirrusLogic5430UgaDraw.c index be05f8766f..e71ec8e405 100644 --- a/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/CirrusLogic5430UgaDraw.c +++ b/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/CirrusLogic5430UgaDraw.c @@ -16,18 +16,11 @@ #include "CirrusLogic5430.h"
-///
-/// Video Mode structure
-///
-typedef struct {
- UINT32 Width;
- UINT32 Height;
- UINT32 ColorDepth;
- UINT32 RefreshRate;
- UINT8 *CrtcSettings;
- UINT16 *SeqSettings;
- UINT8 MiscSetting;
-} CIRRUS_LOGIC_5430_VIDEO_MODES;
+STATIC
+VOID
+ClearScreen (
+ CIRRUS_LOGIC_5430_PRIVATE_DATA *Private
+ );
///
/// Generic Attribute Controller Register Settings
@@ -100,66 +93,6 @@ static CIRRUS_LOGIC_5430_VIDEO_MODES CirrusLogic5430VideoModes[] = { };
//
-// Local Function Prototypes
-//
-VOID
-InitializeGraphicsMode (
- CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
- CIRRUS_LOGIC_5430_VIDEO_MODES *ModeData
- );
-
-VOID
-SetPaletteColor (
- CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
- UINTN Index,
- UINT8 Red,
- UINT8 Green,
- UINT8 Blue
- );
-
-VOID
-SetDefaultPalette (
- CIRRUS_LOGIC_5430_PRIVATE_DATA *Private
- );
-
-STATIC
-VOID
-ClearScreen (
- CIRRUS_LOGIC_5430_PRIVATE_DATA *Private
- );
-
-VOID
-DrawLogo (
- CIRRUS_LOGIC_5430_PRIVATE_DATA *Private
- );
-
-VOID
-outb (
- CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
- UINTN Address,
- UINT8 Data
- );
-
-VOID
-outw (
- CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
- UINTN Address,
- UINT16 Data
- );
-
-UINT8
-inb (
- CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
- UINTN Address
- );
-
-UINT16
-inw (
- CIRRUS_LOGIC_5430_PRIVATE_DATA *Private,
- UINTN Address
- );
-
-//
// UGA Draw Protocol Member Functions
//
/**
diff --git a/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/ComponentName.c b/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/ComponentName.c index 38d86a556c..361bf83ff1 100644 --- a/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/ComponentName.c +++ b/EdkModulePkg/Bus/Pci/CirrusLogic/Dxe/ComponentName.c @@ -13,27 +13,6 @@ #include "CirrusLogic5430.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-CirrusLogic5430ComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-CirrusLogic5430ComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gCirrusLogic5430ComponentName = {
diff --git a/EdkModulePkg/Bus/Pci/Ehci/Dxe/ComponentName.c b/EdkModulePkg/Bus/Pci/Ehci/Dxe/ComponentName.c index 12cb7665d1..5d332e018d 100644 --- a/EdkModulePkg/Bus/Pci/Ehci/Dxe/ComponentName.c +++ b/EdkModulePkg/Bus/Pci/Ehci/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "Ehci.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-EhciComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-EhciComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle, OPTIONAL
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gEhciComponentName = {
diff --git a/EdkModulePkg/Bus/Pci/Ehci/Dxe/Ehci.c b/EdkModulePkg/Bus/Pci/Ehci/Dxe/Ehci.c index e6a4f6130b..cb89e178f7 100644 --- a/EdkModulePkg/Bus/Pci/Ehci/Dxe/Ehci.c +++ b/EdkModulePkg/Bus/Pci/Ehci/Dxe/Ehci.c @@ -28,190 +28,6 @@ GLOBAL_REMOVE_IF_UNREFERENCED UINTN gEHCErrorLevel = EFI_D_ERROR; //
-// Prototypes
-// Driver model protocol interface
-//
-
-EFI_STATUS
-EFIAPI
-EhciDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-EhciDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-EhciDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
-//
-// Ehci protocol interface
-//
-EFI_STATUS
-EFIAPI
-EhciGetCapability (
- IN EFI_USB2_HC_PROTOCOL *This,
- OUT UINT8 *MaxSpeed,
- OUT UINT8 *PortNumber,
- OUT UINT8 *Is64BitCapable
- );
-
-EFI_STATUS
-EFIAPI
-EhciReset (
- IN EFI_USB2_HC_PROTOCOL *This,
- IN UINT16 Attributes
- );
-
-EFI_STATUS
-EFIAPI
-EhciGetState (
- IN EFI_USB2_HC_PROTOCOL *This,
- OUT EFI_USB_HC_STATE *State
- );
-
-EFI_STATUS
-EFIAPI
-EhciSetState (
- IN EFI_USB2_HC_PROTOCOL *This,
- IN EFI_USB_HC_STATE State
- );
-
-EFI_STATUS
-EFIAPI
-EhciControlTransfer (
- IN EFI_USB2_HC_PROTOCOL *This,
- IN UINT8 DeviceAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaximumPacketLength,
- IN EFI_USB_DEVICE_REQUEST *Request,
- IN EFI_USB_DATA_DIRECTION TransferDirection,
- IN OUT VOID *Data,
- IN OUT UINTN *DataLength,
- IN UINTN TimeOut,
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-EhciBulkTransfer (
- IN EFI_USB2_HC_PROTOCOL *This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaximumPacketLength,
- IN UINT8 DataBuffersNumber,
- IN OUT VOID *Data[EFI_USB_MAX_BULK_BUFFER_NUM],
- IN OUT UINTN *DataLength,
- IN OUT UINT8 *DataToggle,
- IN UINTN TimeOut,
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-EhciAsyncInterruptTransfer (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaxiumPacketLength,
- IN BOOLEAN IsNewTransfer,
- IN OUT UINT8 *DataToggle,
- IN UINTN PollingInterval,
- IN UINTN DataLength,
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- IN EFI_ASYNC_USB_TRANSFER_CALLBACK CallBackFunction,
- IN VOID *Context OPTIONAL
- );
-
-EFI_STATUS
-EFIAPI
-EhciSyncInterruptTransfer (
- IN EFI_USB2_HC_PROTOCOL *This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaximumPacketLength,
- IN OUT VOID *Data,
- IN OUT UINTN *DataLength,
- IN OUT UINT8 *DataToggle,
- IN UINTN TimeOut,
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-EhciIsochronousTransfer (
- IN EFI_USB2_HC_PROTOCOL *This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaximumPacketLength,
- IN UINT8 DataBuffersNumber,
- IN OUT VOID *Data[EFI_USB_MAX_ISO_BUFFER_NUM],
- IN UINTN DataLength,
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-EhciAsyncIsochronousTransfer (
- IN EFI_USB2_HC_PROTOCOL *This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaximumPacketLength,
- IN UINT8 DataBuffersNumber,
- IN OUT VOID *Data[EFI_USB_MAX_ISO_BUFFER_NUM],
- IN UINTN DataLength,
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- IN EFI_ASYNC_USB_TRANSFER_CALLBACK IsochronousCallBack,
- IN VOID *Context
- );
-
-EFI_STATUS
-EFIAPI
-EhciGetRootHubPortStatus (
- IN EFI_USB2_HC_PROTOCOL *This,
- IN UINT8 PortNumber,
- OUT EFI_USB_PORT_STATUS *PortStatus
- );
-
-EFI_STATUS
-EFIAPI
-EhciSetRootHubPortFeature (
- IN EFI_USB2_HC_PROTOCOL *This,
- IN UINT8 PortNumber,
- IN EFI_USB_PORT_FEATURE PortFeature
- );
-
-EFI_STATUS
-EFIAPI
-EhciClearRootHubPortFeature (
- IN EFI_USB2_HC_PROTOCOL *This,
- IN UINT8 PortNumber,
- IN EFI_USB_PORT_FEATURE PortFeature
- );
-
-//
// Ehci Driver Global Variables
//
EFI_DRIVER_BINDING_PROTOCOL gEhciDriverBinding = {
diff --git a/EdkModulePkg/Bus/Pci/Ehci/Dxe/Ehci.h b/EdkModulePkg/Bus/Pci/Ehci/Dxe/Ehci.h index 603bb2665a..dcf3e56107 100644 --- a/EdkModulePkg/Bus/Pci/Ehci/Dxe/Ehci.h +++ b/EdkModulePkg/Bus/Pci/Ehci/Dxe/Ehci.h @@ -404,6 +404,211 @@ typedef struct _USB2_HC_DEV { //
+// Prototypes
+// Driver model protocol interface
+//
+
+EFI_STATUS
+EFIAPI
+EhciDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+EhciDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+EhciDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// Ehci protocol interface
+//
+EFI_STATUS
+EFIAPI
+EhciGetCapability (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ OUT UINT8 *MaxSpeed,
+ OUT UINT8 *PortNumber,
+ OUT UINT8 *Is64BitCapable
+ );
+
+EFI_STATUS
+EFIAPI
+EhciReset (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ IN UINT16 Attributes
+ );
+
+EFI_STATUS
+EFIAPI
+EhciGetState (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ OUT EFI_USB_HC_STATE *State
+ );
+
+EFI_STATUS
+EFIAPI
+EhciSetState (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ IN EFI_USB_HC_STATE State
+ );
+
+EFI_STATUS
+EFIAPI
+EhciControlTransfer (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaximumPacketLength,
+ IN EFI_USB_DEVICE_REQUEST *Request,
+ IN EFI_USB_DATA_DIRECTION TransferDirection,
+ IN OUT VOID *Data,
+ IN OUT UINTN *DataLength,
+ IN UINTN TimeOut,
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+EhciBulkTransfer (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaximumPacketLength,
+ IN UINT8 DataBuffersNumber,
+ IN OUT VOID *Data[EFI_USB_MAX_BULK_BUFFER_NUM],
+ IN OUT UINTN *DataLength,
+ IN OUT UINT8 *DataToggle,
+ IN UINTN TimeOut,
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+EhciAsyncInterruptTransfer (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaxiumPacketLength,
+ IN BOOLEAN IsNewTransfer,
+ IN OUT UINT8 *DataToggle,
+ IN UINTN PollingInterval,
+ IN UINTN DataLength,
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ IN EFI_ASYNC_USB_TRANSFER_CALLBACK CallBackFunction,
+ IN VOID *Context OPTIONAL
+ );
+
+EFI_STATUS
+EFIAPI
+EhciSyncInterruptTransfer (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaximumPacketLength,
+ IN OUT VOID *Data,
+ IN OUT UINTN *DataLength,
+ IN OUT UINT8 *DataToggle,
+ IN UINTN TimeOut,
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+EhciIsochronousTransfer (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaximumPacketLength,
+ IN UINT8 DataBuffersNumber,
+ IN OUT VOID *Data[EFI_USB_MAX_ISO_BUFFER_NUM],
+ IN UINTN DataLength,
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+EhciAsyncIsochronousTransfer (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaximumPacketLength,
+ IN UINT8 DataBuffersNumber,
+ IN OUT VOID *Data[EFI_USB_MAX_ISO_BUFFER_NUM],
+ IN UINTN DataLength,
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ IN EFI_ASYNC_USB_TRANSFER_CALLBACK IsochronousCallBack,
+ IN VOID *Context
+ );
+
+EFI_STATUS
+EFIAPI
+EhciGetRootHubPortStatus (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ IN UINT8 PortNumber,
+ OUT EFI_USB_PORT_STATUS *PortStatus
+ );
+
+EFI_STATUS
+EFIAPI
+EhciSetRootHubPortFeature (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ IN UINT8 PortNumber,
+ IN EFI_USB_PORT_FEATURE PortFeature
+ );
+
+EFI_STATUS
+EFIAPI
+EhciClearRootHubPortFeature (
+ IN EFI_USB2_HC_PROTOCOL *This,
+ IN UINT8 PortNumber,
+ IN EFI_USB_PORT_FEATURE PortFeature
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+EhciComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+EhciComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle, OPTIONAL
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
+//
// Internal Functions Declaration
//
diff --git a/EdkModulePkg/Bus/Pci/IdeBus/Dxe/DriverConfiguration.c b/EdkModulePkg/Bus/Pci/IdeBus/Dxe/DriverConfiguration.c index 6a05562a17..7ee2ab3c39 100644 --- a/EdkModulePkg/Bus/Pci/IdeBus/Dxe/DriverConfiguration.c +++ b/EdkModulePkg/Bus/Pci/IdeBus/Dxe/DriverConfiguration.c @@ -18,33 +18,6 @@ CHAR16 *OptionString[4] = { L"Enable Secondary Master (Y/N)? -->",
L"Enable Secondary Slave (Y/N)? -->"
};
-//
-// EFI Driver Configuration Functions
-//
-EFI_STATUS
-IDEBusDriverConfigurationSetOptions (
- IN EFI_DRIVER_CONFIGURATION_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED *ActionRequired
- );
-
-EFI_STATUS
-IDEBusDriverConfigurationOptionsValid (
- IN EFI_DRIVER_CONFIGURATION_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL
- );
-
-EFI_STATUS
-IDEBusDriverConfigurationForceDefaults (
- IN EFI_DRIVER_CONFIGURATION_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN UINT32 DefaultType,
- OUT EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED *ActionRequired
- );
//
// EFI Driver Configuration Protocol
diff --git a/EdkModulePkg/Bus/Pci/IdeBus/Dxe/DriverDiagnostics.c b/EdkModulePkg/Bus/Pci/IdeBus/Dxe/DriverDiagnostics.c index 83a273aed4..44d767ceb1 100644 --- a/EdkModulePkg/Bus/Pci/IdeBus/Dxe/DriverDiagnostics.c +++ b/EdkModulePkg/Bus/Pci/IdeBus/Dxe/DriverDiagnostics.c @@ -15,21 +15,6 @@ #define IDE_BUS_DIAGNOSTIC_ERROR L"PCI IDE/ATAPI Driver Diagnostics Failed"
//
-// EFI Driver Diagnostics Functions
-//
-EFI_STATUS
-IDEBusDriverDiagnosticsRunDiagnostics (
- IN EFI_DRIVER_DIAGNOSTICS_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN EFI_DRIVER_DIAGNOSTIC_TYPE DiagnosticType,
- IN CHAR8 *Language,
- OUT EFI_GUID **ErrorType,
- OUT UINTN *BufferSize,
- OUT CHAR16 **Buffer
- );
-
-//
// EFI Driver Diagnostics Protocol
//
EFI_DRIVER_DIAGNOSTICS_PROTOCOL gIDEBusDriverDiagnostics = {
diff --git a/EdkModulePkg/Bus/Pci/IdeBus/Dxe/ata.c b/EdkModulePkg/Bus/Pci/IdeBus/Dxe/ata.c index 7ea54b9a4f..aea126b3e6 100644 --- a/EdkModulePkg/Bus/Pci/IdeBus/Dxe/ata.c +++ b/EdkModulePkg/Bus/Pci/IdeBus/Dxe/ata.c @@ -23,43 +23,6 @@ #include "idebus.h"
-
-EFI_STATUS
-AtaReadSectorsExt (
- IN IDE_BLK_IO_DEV *IdeDev,
- IN OUT VOID *DataBuffer,
- IN EFI_LBA StartLba,
- IN UINTN NumberOfBlocks
- );
-
-EFI_STATUS
-AtaWriteSectorsExt (
- IN IDE_BLK_IO_DEV *IdeDev,
- IN VOID *DataBuffer,
- IN EFI_LBA StartLba,
- IN UINTN NumberOfBlocks
- );
-
-EFI_STATUS
-AtaPioDataInExt (
- IN IDE_BLK_IO_DEV *IdeDev,
- IN OUT VOID *Buffer,
- IN UINT32 ByteCount,
- IN UINT8 AtaCommand,
- IN EFI_LBA StartLba,
- IN UINT16 SectorCount
- );
-
-EFI_STATUS
-AtaPioDataOutExt (
- IN IDE_BLK_IO_DEV *IdeDev,
- IN VOID *Buffer,
- IN UINT32 ByteCount,
- IN UINT8 AtaCommand,
- IN EFI_LBA StartLba,
- IN UINT16 SectorCount
- );
-
/**
Sends out an ATA Identify Command to the specified device.
diff --git a/EdkModulePkg/Bus/Pci/IdeBus/Dxe/idebus.h b/EdkModulePkg/Bus/Pci/IdeBus/Dxe/idebus.h index e49e7623e5..52c1f266b1 100644 --- a/EdkModulePkg/Bus/Pci/IdeBus/Dxe/idebus.h +++ b/EdkModulePkg/Bus/Pci/IdeBus/Dxe/idebus.h @@ -172,6 +172,49 @@ IDEBusDriverBindingStop ( ;
//
+// EFI Driver Configuration Functions
+//
+EFI_STATUS
+IDEBusDriverConfigurationSetOptions (
+ IN EFI_DRIVER_CONFIGURATION_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED *ActionRequired
+ );
+
+EFI_STATUS
+IDEBusDriverConfigurationOptionsValid (
+ IN EFI_DRIVER_CONFIGURATION_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL
+ );
+
+EFI_STATUS
+IDEBusDriverConfigurationForceDefaults (
+ IN EFI_DRIVER_CONFIGURATION_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN UINT32 DefaultType,
+ OUT EFI_DRIVER_CONFIGURATION_ACTION_REQUIRED *ActionRequired
+ );
+
+//
+// EFI Driver Diagnostics Functions
+//
+EFI_STATUS
+IDEBusDriverDiagnosticsRunDiagnostics (
+ IN EFI_DRIVER_DIAGNOSTICS_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN EFI_DRIVER_DIAGNOSTIC_TYPE DiagnosticType,
+ IN CHAR8 *Language,
+ OUT EFI_GUID **ErrorType,
+ OUT UINTN *BufferSize,
+ OUT CHAR16 **Buffer
+ );
+
+//
// Block I/O Protocol Interface
//
/**
diff --git a/EdkModulePkg/Bus/Pci/PciBus/Dxe/pcibus.c b/EdkModulePkg/Bus/Pci/PciBus/Dxe/pcibus.c index 43d3e38dd1..eb6713f4dd 100644 --- a/EdkModulePkg/Bus/Pci/PciBus/Dxe/pcibus.c +++ b/EdkModulePkg/Bus/Pci/PciBus/Dxe/pcibus.c @@ -24,42 +24,6 @@ Revision History #include "pcibus.h"
//
-// PCI Bus Support Function Prototypes
-//
-
-EFI_STATUS
-EFIAPI
-PciBusEntryPoint (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- );
-
-EFI_STATUS
-EFIAPI
-PciBusDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-PciBusDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-PciBusDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
-//
// PCI Bus Driver Global Variables
//
diff --git a/EdkModulePkg/Bus/Pci/PciBus/Dxe/pcibus.h b/EdkModulePkg/Bus/Pci/PciBus/Dxe/pcibus.h index a18d12f3d4..cd34d8742e 100644 --- a/EdkModulePkg/Bus/Pci/PciBus/Dxe/pcibus.h +++ b/EdkModulePkg/Bus/Pci/PciBus/Dxe/pcibus.h @@ -240,4 +240,32 @@ extern EFI_PCI_PLATFORM_PROTOCOL *gPciPlatformProtocol; #include "PciHotPlugSupport.h"
#include "PciLib.h"
+//
+// PCI Bus Support Function Prototypes
+//
+EFI_STATUS
+EFIAPI
+PciBusDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+PciBusDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+PciBusDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
#endif
diff --git a/EdkModulePkg/Bus/Pci/Uhci/Dxe/ComponentName.c b/EdkModulePkg/Bus/Pci/Uhci/Dxe/ComponentName.c index 909912f329..b6209e4295 100644 --- a/EdkModulePkg/Bus/Pci/Uhci/Dxe/ComponentName.c +++ b/EdkModulePkg/Bus/Pci/Uhci/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "uhci.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-UhciComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-UhciComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle, OPTIONAL
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gUhciComponentName = {
diff --git a/EdkModulePkg/Bus/Pci/Uhci/Dxe/uhci.c b/EdkModulePkg/Bus/Pci/Uhci/Dxe/uhci.c index 7e033df2df..b3cb1f543d 100644 --- a/EdkModulePkg/Bus/Pci/Uhci/Dxe/uhci.c +++ b/EdkModulePkg/Bus/Pci/Uhci/Dxe/uhci.c @@ -22,342 +22,6 @@ Revision History #include "uhci.h"
//
-// Prototypes
-// Driver model protocol interface
-//
-
-EFI_STATUS
-EFIAPI
-UHCIDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-UHCIDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-UHCIDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
-//
-// UHCI interface functions
-//
-
-EFI_STATUS
-EFIAPI
-UHCIReset (
- IN EFI_USB_HC_PROTOCOL *This,
- IN UINT16 Attributes
- );
-
-EFI_STATUS
-EFIAPI
-UHCIGetState (
- IN EFI_USB_HC_PROTOCOL *This,
- OUT EFI_USB_HC_STATE *State
- );
-
-EFI_STATUS
-EFIAPI
-UHCISetState (
- IN EFI_USB_HC_PROTOCOL *This,
- IN EFI_USB_HC_STATE State
- );
-
-EFI_STATUS
-EFIAPI
-UHCIControlTransfer (
- IN EFI_USB_HC_PROTOCOL *This,
- IN UINT8 DeviceAddress,
- IN BOOLEAN IsSlowDevice,
- IN UINT8 MaximumPacketLength,
- IN EFI_USB_DEVICE_REQUEST *Request,
- IN EFI_USB_DATA_DIRECTION TransferDirection,
- IN OUT VOID *Data, OPTIONAL
- IN OUT UINTN *DataLength, OPTIONAL
- IN UINTN TimeOut,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-UHCIBulkTransfer (
- IN EFI_USB_HC_PROTOCOL *This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 MaximumPacketLength,
- IN OUT VOID *Data,
- IN OUT UINTN *DataLength,
- IN OUT UINT8 *DataToggle,
- IN UINTN TimeOut,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-UHCIAsyncInterruptTransfer (
- IN EFI_USB_HC_PROTOCOL * This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN BOOLEAN IsSlowDevice,
- IN UINT8 MaximumPacketLength,
- IN BOOLEAN IsNewTransfer,
- IN OUT UINT8 *DataToggle,
- IN UINTN PollingInterval, OPTIONAL
- IN UINTN DataLength, OPTIONAL
- IN EFI_ASYNC_USB_TRANSFER_CALLBACK CallBackFunction, OPTIONAL
- IN VOID *Context OPTIONAL
- );
-
-EFI_STATUS
-EFIAPI
-UHCISyncInterruptTransfer (
- IN EFI_USB_HC_PROTOCOL *This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN BOOLEAN IsSlowDevice,
- IN UINT8 MaximumPacketLength,
- IN OUT VOID *Data,
- IN OUT UINTN *DataLength,
- IN OUT UINT8 *DataToggle,
- IN UINTN TimeOut,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-UHCIIsochronousTransfer (
- IN EFI_USB_HC_PROTOCOL *This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 MaximumPacketLength,
- IN OUT VOID *Data,
- IN UINTN DataLength,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-UHCIAsyncIsochronousTransfer (
- IN EFI_USB_HC_PROTOCOL * This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 MaximumPacketLength,
- IN OUT VOID *Data,
- IN UINTN DataLength,
- IN EFI_ASYNC_USB_TRANSFER_CALLBACK IsochronousCallBack,
- IN VOID *Context OPTIONAL
- );
-
-EFI_STATUS
-EFIAPI
-UHCIGetRootHubPortNumber (
- IN EFI_USB_HC_PROTOCOL *This,
- OUT UINT8 *PortNumber
- );
-
-EFI_STATUS
-EFIAPI
-UHCIGetRootHubPortStatus (
- IN EFI_USB_HC_PROTOCOL *This,
- IN UINT8 PortNumber,
- OUT EFI_USB_PORT_STATUS *PortStatus
- );
-
-EFI_STATUS
-EFIAPI
-UHCISetRootHubPortFeature (
- IN EFI_USB_HC_PROTOCOL *This,
- IN UINT8 PortNumber,
- IN EFI_USB_PORT_FEATURE PortFeature
- );
-
-EFI_STATUS
-EFIAPI
-UHCIClearRootHubPortFeature (
- IN EFI_USB_HC_PROTOCOL *This,
- IN UINT8 PortNumber,
- IN EFI_USB_PORT_FEATURE PortFeature
- );
-
-//
-// UEFI 2.0 Protocol
-//
-
-EFI_STATUS
-EFIAPI
-UHCI2GetCapability(
- IN EFI_USB2_HC_PROTOCOL * This,
- OUT UINT8 *MaxSpeed,
- OUT UINT8 *PortNumber,
- OUT UINT8 *Is64BitCapable
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2Reset (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN UINT16 Attributes
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2GetState (
- IN EFI_USB2_HC_PROTOCOL * This,
- OUT EFI_USB_HC_STATE * State
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2SetState (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN EFI_USB_HC_STATE State
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2ControlTransfer (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN UINT8 DeviceAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaximumPacketLength,
- IN EFI_USB_DEVICE_REQUEST * Request,
- IN EFI_USB_DATA_DIRECTION TransferDirection,
- IN OUT VOID *Data, OPTIONAL
- IN OUT UINTN *DataLength, OPTIONAL
- IN UINTN TimeOut,
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2BulkTransfer (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaximumPacketLength,
- IN UINT8 DataBuffersNumber,
- IN OUT VOID *Data[EFI_USB_MAX_BULK_BUFFER_NUM],
- IN OUT UINTN *DataLength,
- IN OUT UINT8 *DataToggle,
- IN UINTN TimeOut,
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2AsyncInterruptTransfer (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaximumPacketLength,
- IN BOOLEAN IsNewTransfer,
- IN OUT UINT8 *DataToggle,
- IN UINTN PollingInterval, OPTIONAL
- IN UINTN DataLength, OPTIONAL
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- IN EFI_ASYNC_USB_TRANSFER_CALLBACK CallBackFunction, OPTIONAL
- IN VOID *Context OPTIONAL
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2SyncInterruptTransfer (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaximumPacketLength,
- IN OUT VOID *Data,
- IN OUT UINTN *DataLength,
- IN OUT UINT8 *DataToggle,
- IN UINTN TimeOut,
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2IsochronousTransfer (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaximumPacketLength,
- IN UINT8 DataBuffersNumber,
- IN OUT VOID *Data[EFI_USB_MAX_ISO_BUFFER_NUM],
- IN UINTN DataLength,
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- OUT UINT32 *TransferResult
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2AsyncIsochronousTransfer (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN UINT8 DeviceAddress,
- IN UINT8 EndPointAddress,
- IN UINT8 DeviceSpeed,
- IN UINTN MaximumPacketLength,
- IN UINT8 DataBuffersNumber,
- IN OUT VOID *Data[EFI_USB_MAX_ISO_BUFFER_NUM],
- IN UINTN DataLength,
- IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
- IN EFI_ASYNC_USB_TRANSFER_CALLBACK IsochronousCallBack,
- IN VOID *Context OPTIONAL
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2GetRootHubPortStatus (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN UINT8 PortNumber,
- OUT EFI_USB_PORT_STATUS * PortStatus
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2SetRootHubPortFeature (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN UINT8 PortNumber,
- IN EFI_USB_PORT_FEATURE PortFeature
- );
-
-EFI_STATUS
-EFIAPI
-UHCI2ClearRootHubPortFeature (
- IN EFI_USB2_HC_PROTOCOL * This,
- IN UINT8 PortNumber,
- IN EFI_USB_PORT_FEATURE PortFeature
- );
-
-//
-// Asynchronous interrupt transfer monitor function
-//
-VOID
-EFIAPI
-MonitorInterruptTrans (
- IN EFI_EVENT Event,
- IN VOID *Context
- );
-
-//
// UHCI Driver Global Variables
//
EFI_DRIVER_BINDING_PROTOCOL gUhciDriverBinding = {
diff --git a/EdkModulePkg/Bus/Pci/Uhci/Dxe/uhci.h b/EdkModulePkg/Bus/Pci/Uhci/Dxe/uhci.h index c224a16ac6..68571c5d89 100644 --- a/EdkModulePkg/Bus/Pci/Uhci/Dxe/uhci.h +++ b/EdkModulePkg/Bus/Pci/Uhci/Dxe/uhci.h @@ -285,6 +285,27 @@ typedef struct { extern EFI_DRIVER_BINDING_PROTOCOL gUhciDriverBinding;
extern EFI_COMPONENT_NAME_PROTOCOL gUhciComponentName;
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+UhciComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+UhciComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle, OPTIONAL
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
EFI_STATUS
WriteUHCCommandReg (
IN EFI_PCI_IO_PROTOCOL *PciIo,
@@ -2635,4 +2656,340 @@ Returns: --*/
;
+//
+// Prototypes
+// Driver model protocol interface
+//
+
+EFI_STATUS
+EFIAPI
+UHCIDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+UHCIDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+UHCIDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// UHCI interface functions
+//
+
+EFI_STATUS
+EFIAPI
+UHCIReset (
+ IN EFI_USB_HC_PROTOCOL *This,
+ IN UINT16 Attributes
+ );
+
+EFI_STATUS
+EFIAPI
+UHCIGetState (
+ IN EFI_USB_HC_PROTOCOL *This,
+ OUT EFI_USB_HC_STATE *State
+ );
+
+EFI_STATUS
+EFIAPI
+UHCISetState (
+ IN EFI_USB_HC_PROTOCOL *This,
+ IN EFI_USB_HC_STATE State
+ );
+
+EFI_STATUS
+EFIAPI
+UHCIControlTransfer (
+ IN EFI_USB_HC_PROTOCOL *This,
+ IN UINT8 DeviceAddress,
+ IN BOOLEAN IsSlowDevice,
+ IN UINT8 MaximumPacketLength,
+ IN EFI_USB_DEVICE_REQUEST *Request,
+ IN EFI_USB_DATA_DIRECTION TransferDirection,
+ IN OUT VOID *Data, OPTIONAL
+ IN OUT UINTN *DataLength, OPTIONAL
+ IN UINTN TimeOut,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+UHCIBulkTransfer (
+ IN EFI_USB_HC_PROTOCOL *This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 MaximumPacketLength,
+ IN OUT VOID *Data,
+ IN OUT UINTN *DataLength,
+ IN OUT UINT8 *DataToggle,
+ IN UINTN TimeOut,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+UHCIAsyncInterruptTransfer (
+ IN EFI_USB_HC_PROTOCOL * This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN BOOLEAN IsSlowDevice,
+ IN UINT8 MaximumPacketLength,
+ IN BOOLEAN IsNewTransfer,
+ IN OUT UINT8 *DataToggle,
+ IN UINTN PollingInterval, OPTIONAL
+ IN UINTN DataLength, OPTIONAL
+ IN EFI_ASYNC_USB_TRANSFER_CALLBACK CallBackFunction, OPTIONAL
+ IN VOID *Context OPTIONAL
+ );
+
+EFI_STATUS
+EFIAPI
+UHCISyncInterruptTransfer (
+ IN EFI_USB_HC_PROTOCOL *This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN BOOLEAN IsSlowDevice,
+ IN UINT8 MaximumPacketLength,
+ IN OUT VOID *Data,
+ IN OUT UINTN *DataLength,
+ IN OUT UINT8 *DataToggle,
+ IN UINTN TimeOut,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+UHCIIsochronousTransfer (
+ IN EFI_USB_HC_PROTOCOL *This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 MaximumPacketLength,
+ IN OUT VOID *Data,
+ IN UINTN DataLength,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+UHCIAsyncIsochronousTransfer (
+ IN EFI_USB_HC_PROTOCOL * This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 MaximumPacketLength,
+ IN OUT VOID *Data,
+ IN UINTN DataLength,
+ IN EFI_ASYNC_USB_TRANSFER_CALLBACK IsochronousCallBack,
+ IN VOID *Context OPTIONAL
+ );
+
+EFI_STATUS
+EFIAPI
+UHCIGetRootHubPortNumber (
+ IN EFI_USB_HC_PROTOCOL *This,
+ OUT UINT8 *PortNumber
+ );
+
+EFI_STATUS
+EFIAPI
+UHCIGetRootHubPortStatus (
+ IN EFI_USB_HC_PROTOCOL *This,
+ IN UINT8 PortNumber,
+ OUT EFI_USB_PORT_STATUS *PortStatus
+ );
+
+EFI_STATUS
+EFIAPI
+UHCISetRootHubPortFeature (
+ IN EFI_USB_HC_PROTOCOL *This,
+ IN UINT8 PortNumber,
+ IN EFI_USB_PORT_FEATURE PortFeature
+ );
+
+EFI_STATUS
+EFIAPI
+UHCIClearRootHubPortFeature (
+ IN EFI_USB_HC_PROTOCOL *This,
+ IN UINT8 PortNumber,
+ IN EFI_USB_PORT_FEATURE PortFeature
+ );
+
+//
+// UEFI 2.0 Protocol
+//
+
+EFI_STATUS
+EFIAPI
+UHCI2GetCapability(
+ IN EFI_USB2_HC_PROTOCOL * This,
+ OUT UINT8 *MaxSpeed,
+ OUT UINT8 *PortNumber,
+ OUT UINT8 *Is64BitCapable
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2Reset (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN UINT16 Attributes
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2GetState (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ OUT EFI_USB_HC_STATE * State
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2SetState (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN EFI_USB_HC_STATE State
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2ControlTransfer (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaximumPacketLength,
+ IN EFI_USB_DEVICE_REQUEST * Request,
+ IN EFI_USB_DATA_DIRECTION TransferDirection,
+ IN OUT VOID *Data, OPTIONAL
+ IN OUT UINTN *DataLength, OPTIONAL
+ IN UINTN TimeOut,
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2BulkTransfer (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaximumPacketLength,
+ IN UINT8 DataBuffersNumber,
+ IN OUT VOID *Data[EFI_USB_MAX_BULK_BUFFER_NUM],
+ IN OUT UINTN *DataLength,
+ IN OUT UINT8 *DataToggle,
+ IN UINTN TimeOut,
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2AsyncInterruptTransfer (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaximumPacketLength,
+ IN BOOLEAN IsNewTransfer,
+ IN OUT UINT8 *DataToggle,
+ IN UINTN PollingInterval, OPTIONAL
+ IN UINTN DataLength, OPTIONAL
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ IN EFI_ASYNC_USB_TRANSFER_CALLBACK CallBackFunction, OPTIONAL
+ IN VOID *Context OPTIONAL
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2SyncInterruptTransfer (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaximumPacketLength,
+ IN OUT VOID *Data,
+ IN OUT UINTN *DataLength,
+ IN OUT UINT8 *DataToggle,
+ IN UINTN TimeOut,
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2IsochronousTransfer (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaximumPacketLength,
+ IN UINT8 DataBuffersNumber,
+ IN OUT VOID *Data[EFI_USB_MAX_ISO_BUFFER_NUM],
+ IN UINTN DataLength,
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ OUT UINT32 *TransferResult
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2AsyncIsochronousTransfer (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN UINT8 DeviceAddress,
+ IN UINT8 EndPointAddress,
+ IN UINT8 DeviceSpeed,
+ IN UINTN MaximumPacketLength,
+ IN UINT8 DataBuffersNumber,
+ IN OUT VOID *Data[EFI_USB_MAX_ISO_BUFFER_NUM],
+ IN UINTN DataLength,
+ IN EFI_USB2_HC_TRANSACTION_TRANSLATOR *Translator,
+ IN EFI_ASYNC_USB_TRANSFER_CALLBACK IsochronousCallBack,
+ IN VOID *Context OPTIONAL
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2GetRootHubPortStatus (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN UINT8 PortNumber,
+ OUT EFI_USB_PORT_STATUS * PortStatus
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2SetRootHubPortFeature (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN UINT8 PortNumber,
+ IN EFI_USB_PORT_FEATURE PortFeature
+ );
+
+EFI_STATUS
+EFIAPI
+UHCI2ClearRootHubPortFeature (
+ IN EFI_USB2_HC_PROTOCOL * This,
+ IN UINT8 PortNumber,
+ IN EFI_USB_PORT_FEATURE PortFeature
+ );
+
+//
+// Asynchronous interrupt transfer monitor function
+//
+VOID
+EFIAPI
+MonitorInterruptTrans (
+ IN EFI_EVENT Event,
+ IN VOID *Context
+ );
+
#endif
diff --git a/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Decode.c b/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Decode.c index 90c6713666..c3288438b7 100644 --- a/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Decode.c +++ b/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Decode.c @@ -25,13 +25,6 @@ Revision history: #pragma data_seg("rtdata")
//
-// Global variables defined outside this file
-//
-extern PXE_SW_UNDI *pxe; // !pxe structure
-extern PXE_SW_UNDI *pxe_31; // !pxe structure for 3.1 drivers
-extern UNDI32_DEV *UNDI32DeviceList[MAX_NIC_INTERFACES];
-
-//
// Global variables defined in this file
//
UNDI_CALL_TABLE api_table[PXE_OPCODE_LAST_VALID+1] = { \
diff --git a/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Init.c b/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Init.c index ad91d75726..c9a217fe72 100644 --- a/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Init.c +++ b/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Init.c @@ -31,75 +31,9 @@ PXE_SW_UNDI *pxe_31 = 0; // 3.1 entry UNDI32_DEV *UNDI32DeviceList[MAX_NIC_INTERFACES];
NII_TABLE *UnidiDataPointer=NULL;
-//
-// external Global Variables
-//
-extern UNDI_CALL_TABLE api_table[];
-
-//
-// function prototypes
-//
-EFI_STATUS
-InstallConfigTable (
- IN VOID
- );
-
-EFI_STATUS
-EFIAPI
-InitializeUNDIDriver (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- );
-
-VOID
-UNDI_notify_virtual (
- EFI_EVENT event,
- VOID *context
- );
VOID
EFIAPI
-UndiNotifyExitBs (
- EFI_EVENT Event,
- VOID *Context
- );
-
-EFI_STATUS
-EFIAPI
-UndiDriverSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-UndiDriverStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-UndiDriverStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
-EFI_STATUS
-AppendMac2DevPath (
- IN OUT EFI_DEVICE_PATH_PROTOCOL **DevPtr,
- IN EFI_DEVICE_PATH_PROTOCOL *BaseDevPtr,
- IN NIC_DATA_INSTANCE *AdapterInfo
- );
-//
-// end function prototypes
-//
-VOID
-EFIAPI
UndiNotifyVirtual (
EFI_EVENT Event,
VOID *Context
diff --git a/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Undi32.h b/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Undi32.h index d4ad6b65c1..b7c721262a 100644 --- a/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Undi32.h +++ b/EdkModulePkg/Bus/Pci/Undi/RuntimeDxe/Undi32.h @@ -94,6 +94,11 @@ typedef VOID (*map_mem)(UINT64, UINT64, UINT32, UINT32, UINT64); typedef VOID (*unmap_mem)(UINT64, UINT64, UINT32, UINT32, UINT64);
typedef VOID (*sync_mem)(UINT64, UINT64, UINT32, UINT32, UINT64);
+extern UNDI_CALL_TABLE api_table[];
+extern PXE_SW_UNDI *pxe; // !pxe structure
+extern PXE_SW_UNDI *pxe_31; // !pxe structure for 3.1 drivers
+extern UNDI32_DEV *UNDI32DeviceList[MAX_NIC_INTERFACES];
+
//
// functions defined in e100b.c
//
@@ -158,6 +163,63 @@ VOID FindPhySpeedAndDpx (NIC_DATA_INSTANCE *AdapterInfo, UINT32 PhyId); //
// functions defined in init.c
//
+EFI_STATUS
+InstallConfigTable (
+ IN VOID
+ );
+
+EFI_STATUS
+EFIAPI
+InitializeUNDIDriver (
+ IN EFI_HANDLE ImageHandle,
+ IN EFI_SYSTEM_TABLE *SystemTable
+ );
+
+VOID
+UNDI_notify_virtual (
+ EFI_EVENT event,
+ VOID *context
+ );
+
+VOID
+EFIAPI
+UndiNotifyExitBs (
+ EFI_EVENT Event,
+ VOID *Context
+ );
+
+EFI_STATUS
+EFIAPI
+UndiDriverSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+UndiDriverStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+UndiDriverStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+EFI_STATUS
+AppendMac2DevPath (
+ IN OUT EFI_DEVICE_PATH_PROTOCOL **DevPtr,
+ IN EFI_DEVICE_PATH_PROTOCOL *BaseDevPtr,
+ IN NIC_DATA_INSTANCE *AdapterInfo
+ );
+
VOID
TmpDelay (
IN UINT64 UnqId,
diff --git a/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ComponentName.c b/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ComponentName.c index 3f61c46d54..2468108d52 100644 --- a/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ComponentName.c +++ b/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "ScsiBus.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-ScsiBusComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-ScsiBusComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gScsiBusComponentName = {
diff --git a/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ScsiBus.c b/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ScsiBus.c index b7b59615fd..3c79e473a3 100644 --- a/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ScsiBus.c +++ b/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ScsiBus.c @@ -21,31 +21,6 @@ Revision History #include "ScsiBus.h"
-EFI_STATUS
-EFIAPI
-SCSIBusDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-SCSIBusDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-SCSIBusDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
EFI_DRIVER_BINDING_PROTOCOL gSCSIBusDriverBinding = {
SCSIBusDriverBindingSupported,
SCSIBusDriverBindingStart,
diff --git a/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ScsiBus.h b/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ScsiBus.h index f98187126b..594953e4d6 100644 --- a/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ScsiBus.h +++ b/EdkModulePkg/Bus/Scsi/ScsiBus/Dxe/ScsiBus.h @@ -58,6 +58,52 @@ extern EFI_COMPONENT_NAME_PROTOCOL gScsiBusComponentName; EFI_STATUS
EFIAPI
+SCSIBusDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+SCSIBusDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+SCSIBusDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+ScsiBusComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+ScsiBusComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
+EFI_STATUS
+EFIAPI
ScsiGetDeviceType (
IN EFI_SCSI_IO_PROTOCOL *This,
OUT UINT8 *DeviceType
diff --git a/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ComponentName.c b/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ComponentName.c index e1d0f8d470..74a41e869e 100644 --- a/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ComponentName.c +++ b/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "ScsiDisk.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-ScsiDiskComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-ScsiDiskComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gScsiDiskComponentName = {
diff --git a/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ScsiDisk.c b/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ScsiDisk.c index 10134e864e..a3f4d6a3b6 100644 --- a/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ScsiDisk.c +++ b/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ScsiDisk.c @@ -19,31 +19,6 @@ Abstract: #include "ScsiDisk.h"
-EFI_STATUS
-EFIAPI
-ScsiDiskDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-ScsiDiskDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-ScsiDiskDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
EFI_DRIVER_BINDING_PROTOCOL gScsiDiskDriverBinding = {
ScsiDiskDriverBindingSupported,
ScsiDiskDriverBindingStart,
diff --git a/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ScsiDisk.h b/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ScsiDisk.h index 96d1da4f90..675c643eff 100644 --- a/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ScsiDisk.h +++ b/EdkModulePkg/Bus/Scsi/ScsiDisk/Dxe/ScsiDisk.h @@ -65,6 +65,52 @@ extern EFI_COMPONENT_NAME_PROTOCOL gScsiDiskComponentName; EFI_STATUS
EFIAPI
+ScsiDiskDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+ScsiDiskDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+ScsiDiskDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+ScsiDiskComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+ScsiDiskComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
+EFI_STATUS
+EFIAPI
ScsiDiskReset (
IN EFI_BLOCK_IO_PROTOCOL *This,
IN BOOLEAN ExtendedVerification
diff --git a/EdkModulePkg/Bus/Usb/UsbBot/Dxe/ComponentName.c b/EdkModulePkg/Bus/Usb/UsbBot/Dxe/ComponentName.c index ca4228583a..1b3d5abfa1 100644 --- a/EdkModulePkg/Bus/Usb/UsbBot/Dxe/ComponentName.c +++ b/EdkModulePkg/Bus/Usb/UsbBot/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "bot.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-UsbBotComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-UsbBotComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gUsbBotComponentName = {
diff --git a/EdkModulePkg/Bus/Usb/UsbBot/Dxe/bot.c b/EdkModulePkg/Bus/Usb/UsbBot/Dxe/bot.c index fd830ec56e..e6a5be480b 100644 --- a/EdkModulePkg/Bus/Usb/UsbBot/Dxe/bot.c +++ b/EdkModulePkg/Bus/Usb/UsbBot/Dxe/bot.c @@ -21,44 +21,6 @@ Abstract: GLOBAL_REMOVE_IF_UNREFERENCED UINT32 gBOTDebugLevel = EFI_D_INFO;
GLOBAL_REMOVE_IF_UNREFERENCED UINT32 gBOTErrorLevel = EFI_D_INFO;
-//
-// Function prototypes
-//
-EFI_STATUS
-EFIAPI
-UsbBotDriverEntryPoint (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- );
-
-//
-// Bot Driver Binding Protocol
-//
-EFI_STATUS
-EFIAPI
-BotDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-BotDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-BotDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
EFI_DRIVER_BINDING_PROTOCOL gUsbBotDriverBinding = {
BotDriverBindingSupported,
@@ -124,6 +86,7 @@ BotMassStorageReset ( IN BOOLEAN ExtendedVerification
);
+STATIC
VOID
BotReportStatusCode (
IN EFI_DEVICE_PATH_PROTOCOL *DevicePath,
@@ -979,6 +942,7 @@ BotMassStorageReset ( return Status;
}
+STATIC
VOID
BotReportStatusCode (
IN EFI_DEVICE_PATH_PROTOCOL *DevicePath,
diff --git a/EdkModulePkg/Bus/Usb/UsbBot/Dxe/bot.h b/EdkModulePkg/Bus/Usb/UsbBot/Dxe/bot.h index 383cfde48e..6e43a1b940 100644 --- a/EdkModulePkg/Bus/Usb/UsbBot/Dxe/bot.h +++ b/EdkModulePkg/Bus/Usb/UsbBot/Dxe/bot.h @@ -78,4 +78,53 @@ extern EFI_DRIVER_BINDING_PROTOCOL gUsbBotDriverBinding; extern EFI_COMPONENT_NAME_PROTOCOL gUsbBotComponentName;
extern EFI_GUID gUsbBotDriverGuid;
+//
+// Bot Driver Binding Protocol
+//
+EFI_STATUS
+EFIAPI
+BotDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+BotDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+BotDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+UsbBotComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+UsbBotComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
#endif
diff --git a/EdkModulePkg/Bus/Usb/UsbBus/Dxe/ComponentName.c b/EdkModulePkg/Bus/Usb/UsbBus/Dxe/ComponentName.c index 8ecbbb0995..1233eaccec 100644 --- a/EdkModulePkg/Bus/Usb/UsbBus/Dxe/ComponentName.c +++ b/EdkModulePkg/Bus/Usb/UsbBus/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "usbbus.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-UsbBusComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-UsbBusComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle, OPTIONAL
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gUsbBusComponentName = {
diff --git a/EdkModulePkg/Bus/Usb/UsbBus/Dxe/usbbus.c b/EdkModulePkg/Bus/Usb/UsbBus/Dxe/usbbus.c index ffca53595e..e1fdce7997 100644 --- a/EdkModulePkg/Bus/Usb/UsbBus/Dxe/usbbus.c +++ b/EdkModulePkg/Bus/Usb/UsbBus/Dxe/usbbus.c @@ -34,36 +34,6 @@ GLOBAL_REMOVE_IF_UNREFERENCED UINTN gUSBErrorLevel = EFI_D_ERROR; //
STATIC EFI_GUID mUsbBusProtocolGuid = EFI_USB_BUS_PROTOCOL_GUID;
-
-
-//
-// EFI_DRIVER_BINDING_PROTOCOL Protocol Interface
-//
-EFI_STATUS
-EFIAPI
-UsbBusControllerDriverSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-UsbBusControllerDriverStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-UsbBusControllerDriverStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
EFI_DRIVER_BINDING_PROTOCOL gUsbBusDriverBinding = {
UsbBusControllerDriverSupported,
UsbBusControllerDriverStart,
@@ -154,6 +124,7 @@ ReleasePortToCHC ( UINT8 PortNum
);
+STATIC
EFI_STATUS
ResetRootPort (
IN USB_BUS_CONTROLLER_DEVICE *UsbBusDev,
@@ -161,6 +132,7 @@ ResetRootPort ( IN UINT8 RetryTimes
);
+STATIC
EFI_STATUS
ResetHubPort (
IN USB_IO_CONTROLLER_DEVICE *UsbIoController,
@@ -2341,6 +2313,7 @@ UsbPortReset ( return ParentPortReset (UsbIoController, TRUE, 0);
}
+STATIC
EFI_STATUS
ResetRootPort (
IN USB_BUS_CONTROLLER_DEVICE *UsbBusDev,
@@ -2433,6 +2406,7 @@ ResetRootPort ( return EFI_SUCCESS;
}
+STATIC
EFI_STATUS
ResetHubPort (
IN USB_IO_CONTROLLER_DEVICE *UsbIoController,
diff --git a/EdkModulePkg/Bus/Usb/UsbBus/Dxe/usbbus.h b/EdkModulePkg/Bus/Usb/UsbBus/Dxe/usbbus.h index 4977d71695..ce0e698013 100644 --- a/EdkModulePkg/Bus/Usb/UsbBus/Dxe/usbbus.h +++ b/EdkModulePkg/Bus/Usb/UsbBus/Dxe/usbbus.h @@ -176,6 +176,55 @@ extern EFI_COMPONENT_NAME_PROTOCOL gUsbBusComponentName; extern EFI_GUID gUSBBusDriverGuid;
//
+// EFI_DRIVER_BINDING_PROTOCOL Protocol Interface
+//
+EFI_STATUS
+EFIAPI
+UsbBusControllerDriverSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+UsbBusControllerDriverStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+UsbBusControllerDriverStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+UsbBusComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+UsbBusComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle, OPTIONAL
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
+//
// Usb Device Configuration functions
//
BOOLEAN
diff --git a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/Cbi0.c b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/Cbi0.c index 91a447de66..73b89406bd 100644 --- a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/Cbi0.c +++ b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/Cbi0.c @@ -19,17 +19,6 @@ Abstract: #include "cbi.h"
-extern EFI_COMPONENT_NAME_PROTOCOL gUsbCbi0ComponentName;
-//
-// Function prototypes
-//
-EFI_STATUS
-EFIAPI
-UsbCbi0DriverEntryPoint (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- );
-
//
// Bot Driver Binding Protocol
//
@@ -61,6 +50,7 @@ Cbi0DriverBindingStop ( IN EFI_HANDLE *ChildHandleBuffer
);
+STATIC
VOID
Cbi0ReportStatusCode (
IN EFI_DEVICE_PATH_PROTOCOL *DevicePath,
@@ -1004,6 +994,7 @@ Cbi0AtapiCommand ( return Status;
}
+STATIC
VOID
Cbi0ReportStatusCode (
IN EFI_DEVICE_PATH_PROTOCOL *DevicePath,
diff --git a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/ComponentName.c b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/ComponentName.c index 7d16b5a1e3..87ff7d257b 100644 --- a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/ComponentName.c +++ b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/ComponentName.c @@ -19,29 +19,6 @@ Abstract: #include "cbi.h"
-extern EFI_DRIVER_BINDING_PROTOCOL gUsbCbi0DriverBinding;
-
-//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-UsbCbi0ComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-UsbCbi0ComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
//
// EFI Component Name Protocol
//
diff --git a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/cbi.h b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/cbi.h index e2a7c9d5af..d312176cac 100644 --- a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/cbi.h +++ b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi0/cbi.h @@ -67,4 +67,28 @@ typedef struct { #define USB_CBI_DEVICE_FROM_THIS(a) \
CR(a, USB_CBI_DEVICE, UsbAtapiProtocol, USB_CBI_DEVICE_SIGNATURE)
+extern EFI_COMPONENT_NAME_PROTOCOL gUsbCbi0ComponentName;
+extern EFI_DRIVER_BINDING_PROTOCOL gUsbCbi0DriverBinding;
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+UsbCbi0ComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+UsbCbi0ComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
#endif
diff --git a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/ComponentName.c b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/ComponentName.c index f8485dd734..316c7f4c55 100644 --- a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/ComponentName.c +++ b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/ComponentName.c @@ -19,29 +19,6 @@ Abstract: #include "cbi.h"
-extern EFI_DRIVER_BINDING_PROTOCOL gUsbCbi1DriverBinding;
-
-//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-UsbCbi1ComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-UsbCbi1ComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
//
// EFI Component Name Protocol
//
diff --git a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/cbi.h b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/cbi.h index e2a7c9d5af..77daa1a29b 100644 --- a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/cbi.h +++ b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/cbi.h @@ -67,4 +67,28 @@ typedef struct { #define USB_CBI_DEVICE_FROM_THIS(a) \
CR(a, USB_CBI_DEVICE, UsbAtapiProtocol, USB_CBI_DEVICE_SIGNATURE)
+extern EFI_DRIVER_BINDING_PROTOCOL gUsbCbi1DriverBinding;
+extern EFI_COMPONENT_NAME_PROTOCOL gUsbCbi1ComponentName;
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+UsbCbi1ComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+UsbCbi1ComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
#endif
diff --git a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/cbi1.c b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/cbi1.c index d8ef374c9f..d98d022a54 100644 --- a/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/cbi1.c +++ b/EdkModulePkg/Bus/Usb/UsbCbi/Dxe/Cbi1/cbi1.c @@ -20,15 +20,6 @@ Abstract: #include "cbi.h"
-extern EFI_COMPONENT_NAME_PROTOCOL gUsbCbi1ComponentName;
-
-EFI_STATUS
-EFIAPI
-UsbCBI1DriverEntryPoint (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- );
-
//
// CBI Function prototypes
//
@@ -107,6 +98,7 @@ CBI1DriverBindingStop ( IN EFI_HANDLE *ChildHandleBuffer
);
+STATIC
VOID
Cbi1ReportStatusCode (
IN EFI_DEVICE_PATH_PROTOCOL *DevicePath,
@@ -827,6 +819,7 @@ CBI1AtapiCommand ( return EFI_DEVICE_ERROR;
}
+STATIC
VOID
Cbi1ReportStatusCode (
IN EFI_DEVICE_PATH_PROTOCOL *DevicePath,
diff --git a/EdkModulePkg/Bus/Usb/UsbKb/Dxe/ComponentName.c b/EdkModulePkg/Bus/Usb/UsbKb/Dxe/ComponentName.c index 3e139f9d9a..71a715f06e 100644 --- a/EdkModulePkg/Bus/Usb/UsbKb/Dxe/ComponentName.c +++ b/EdkModulePkg/Bus/Usb/UsbKb/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "keyboard.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-UsbKeyboardComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-UsbKeyboardComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gUsbKeyboardComponentName = {
diff --git a/EdkModulePkg/Bus/Usb/UsbKb/Dxe/efikey.c b/EdkModulePkg/Bus/Usb/UsbKb/Dxe/efikey.c index 1b8c96166c..a1fd418bde 100644 --- a/EdkModulePkg/Bus/Usb/UsbKb/Dxe/efikey.c +++ b/EdkModulePkg/Bus/Usb/UsbKb/Dxe/efikey.c @@ -25,42 +25,6 @@ Revision History #include "keyboard.h"
//
-// Prototypes
-// Driver model protocol interface
-//
-EFI_STATUS
-EFIAPI
-USBKeyboardDriverBindingEntryPoint (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- );
-
-EFI_STATUS
-EFIAPI
-USBKeyboardDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-USBKeyboardDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-USBKeyboardDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
-//
// Simple Text In Protocol Interface
//
STATIC
diff --git a/EdkModulePkg/Bus/Usb/UsbKb/Dxe/efikey.h b/EdkModulePkg/Bus/Usb/UsbKb/Dxe/efikey.h index 31307ebe57..4bdbfc9f9a 100644 --- a/EdkModulePkg/Bus/Usb/UsbKb/Dxe/efikey.h +++ b/EdkModulePkg/Bus/Usb/UsbKb/Dxe/efikey.h @@ -117,4 +117,34 @@ typedef struct { UINT8 ScrollLock : 1;
UINT8 Resrvd : 5;
} LED_MAP;
+
+//
+// Prototypes
+// Driver model protocol interface
+//
+EFI_STATUS
+EFIAPI
+USBKeyboardDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+USBKeyboardDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+USBKeyboardDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
#endif
diff --git a/EdkModulePkg/Bus/Usb/UsbKb/Dxe/keyboard.h b/EdkModulePkg/Bus/Usb/UsbKb/Dxe/keyboard.h index a01fda3ca4..ef4c1c3443 100644 --- a/EdkModulePkg/Bus/Usb/UsbKb/Dxe/keyboard.h +++ b/EdkModulePkg/Bus/Usb/UsbKb/Dxe/keyboard.h @@ -24,6 +24,27 @@ Revision History #include "efikey.h"
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+UsbKeyboardComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+UsbKeyboardComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
BOOLEAN
IsUSBKeyboard (
IN EFI_USB_IO_PROTOCOL *UsbIo
diff --git a/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/ComponentName.c b/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/ComponentName.c index f033361fff..3e34361cef 100644 --- a/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/ComponentName.c +++ b/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "UsbMassStorage.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-UsbMassStorageComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-UsbMassStorageComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gUsbMassStorageComponentName = {
diff --git a/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/UsbMassStorage.c b/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/UsbMassStorage.c index 7f6cd4daf2..951ab0a186 100644 --- a/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/UsbMassStorage.c +++ b/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/UsbMassStorage.c @@ -24,44 +24,6 @@ Revision History #include "UsbMassStorage.h"
#include "UsbMassStorageHelper.h"
-extern EFI_COMPONENT_NAME_PROTOCOL gUsbMassStorageComponentName;
-
-//
-// Prototypes
-// Driver model protocol interface
-//
-EFI_STATUS
-EFIAPI
-USBMassStorageDriverBindingEntryPoint (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- );
-
-EFI_STATUS
-EFIAPI
-USBFloppyDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-USBFloppyDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-USBFloppyDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
//
// Block I/O Protocol Interface
//
diff --git a/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/UsbMassStorage.h b/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/UsbMassStorage.h index 832befcccc..27912b0d13 100644 --- a/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/UsbMassStorage.h +++ b/EdkModulePkg/Bus/Usb/UsbMassStorage/Dxe/UsbMassStorage.h @@ -57,4 +57,56 @@ typedef struct { #define USB_FLOPPY_DEV_FROM_THIS(a) \
CR(a, USB_FLOPPY_DEV, BlkIo, USB_FLOPPY_DEV_SIGNATURE)
+extern EFI_COMPONENT_NAME_PROTOCOL gUsbMassStorageComponentName;
+
+//
+// Prototypes
+// Driver model protocol interface
+//
+EFI_STATUS
+EFIAPI
+USBFloppyDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+USBFloppyDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+USBFloppyDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+UsbMassStorageComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+UsbMassStorageComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
#endif
diff --git a/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/ComponentName.c b/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/ComponentName.c index 5b01cea9d4..695961f17c 100644 --- a/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/ComponentName.c +++ b/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "usbmouse.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-UsbMouseComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-UsbMouseComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gUsbMouseComponentName = {
diff --git a/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/usbmouse.c b/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/usbmouse.c index 442b5a2139..f7449ebfc3 100644 --- a/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/usbmouse.c +++ b/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/usbmouse.c @@ -20,43 +20,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #include "usbmouse.h"
#include "mousehid.h"
-//
-// Prototypes
-// Driver model protocol interface
-//
-EFI_STATUS
-EFIAPI
-USBMouseDriverBindingEntryPoint (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- );
-
-EFI_STATUS
-EFIAPI
-USBMouseDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-USBMouseDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-USBMouseDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
-
EFI_DRIVER_BINDING_PROTOCOL gUsbMouseDriverBinding = {
USBMouseDriverBindingSupported,
USBMouseDriverBindingStart,
diff --git a/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/usbmouse.h b/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/usbmouse.h index 47485bfc08..ac071db311 100644 --- a/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/usbmouse.h +++ b/EdkModulePkg/Bus/Usb/UsbMouse/Dxe/usbmouse.h @@ -82,4 +82,54 @@ MouseReportStatusCode ( IN EFI_STATUS_CODE_VALUE Value
);
+//
+// Prototypes
+// Driver model protocol interface
+//
+EFI_STATUS
+EFIAPI
+USBMouseDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+USBMouseDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+USBMouseDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+UsbMouseComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+UsbMouseComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
#endif
diff --git a/EdkModulePkg/Core/Dxe/Dispatcher/Dispatcher.c b/EdkModulePkg/Core/Dxe/Dispatcher/Dispatcher.c index e7c23b57b3..08d5dc34e5 100644 --- a/EdkModulePkg/Core/Dxe/Dispatcher/Dispatcher.c +++ b/EdkModulePkg/Core/Dxe/Dispatcher/Dispatcher.c @@ -101,11 +101,13 @@ FV_FILEPATH_DEVICE_PATH mFvDevicePath; //
// Function Prototypes
//
+STATIC
VOID
CoreInsertOnScheduledQueueWhileProcessingBeforeAndAfter (
IN EFI_CORE_DRIVER_ENTRY *InsertedDriverEntry
);
+STATIC
VOID
EFIAPI
CoreFwVolEventProtocolNotify (
@@ -113,6 +115,7 @@ CoreFwVolEventProtocolNotify ( IN VOID *Context
);
+STATIC
EFI_DEVICE_PATH_PROTOCOL *
CoreFvToDevicePath (
IN EFI_FIRMWARE_VOLUME_PROTOCOL *Fv,
@@ -523,7 +526,7 @@ Returns: return ReturnStatus;
}
-
+STATIC
VOID
CoreInsertOnScheduledQueueWhileProcessingBeforeAndAfter (
IN EFI_CORE_DRIVER_ENTRY *InsertedDriverEntry
@@ -664,7 +667,7 @@ Returns: -
+STATIC
EFI_DEVICE_PATH_PROTOCOL *
CoreFvToDevicePath (
IN EFI_FIRMWARE_VOLUME_PROTOCOL *Fv,
@@ -858,7 +861,7 @@ Returns: return Status;
}
-
+STATIC
VOID
EFIAPI
CoreFwVolEventProtocolNotify (
diff --git a/EdkModulePkg/Core/Dxe/DxeMain.h b/EdkModulePkg/Core/Dxe/DxeMain.h index b38ba8e7f9..d655cd3381 100644 --- a/EdkModulePkg/Core/Dxe/DxeMain.h +++ b/EdkModulePkg/Core/Dxe/DxeMain.h @@ -2507,4 +2507,256 @@ CoreDisplayDiscoveredNotDispatched ( NONE
--*/;
+
+EFI_STATUS
+EFIAPI
+CoreEfiNotAvailableYetArg0 (
+ VOID
+ )
+/*++
+
+Routine Description:
+
+ Place holder function until all the Boot Services and Runtime Services are available
+
+Arguments:
+
+ None
+
+Returns:
+
+ EFI_NOT_AVAILABLE_YET
+
+--*/
+;
+
+EFI_STATUS
+EFIAPI
+CoreEfiNotAvailableYetArg1 (
+ UINTN Arg1
+ )
+/*++
+
+Routine Description:
+
+ Place holder function until all the Boot Services and Runtime Services are available
+
+Arguments:
+
+ Arg1 - Undefined
+
+Returns:
+
+ EFI_NOT_AVAILABLE_YET
+
+--*/
+;
+
+EFI_STATUS
+EFIAPI
+CoreEfiNotAvailableYetArg2 (
+ UINTN Arg1,
+ UINTN Arg2
+ )
+/*++
+
+Routine Description:
+
+ Place holder function until all the Boot Services and Runtime Services are available
+
+Arguments:
+
+ Arg1 - Undefined
+
+ Arg2 - Undefined
+
+Returns:
+
+ EFI_NOT_AVAILABLE_YET
+
+--*/
+;
+
+EFI_STATUS
+EFIAPI
+CoreEfiNotAvailableYetArg3 (
+ UINTN Arg1,
+ UINTN Arg2,
+ UINTN Arg3
+ )
+/*++
+
+Routine Description:
+
+ Place holder function until all the Boot Services and Runtime Services are available
+
+Arguments:
+
+ Arg1 - Undefined
+
+ Arg2 - Undefined
+
+ Arg3 - Undefined
+
+Returns:
+
+ EFI_NOT_AVAILABLE_YET
+
+--*/
+;
+
+EFI_STATUS
+EFIAPI
+CoreEfiNotAvailableYetArg4 (
+ UINTN Arg1,
+ UINTN Arg2,
+ UINTN Arg3,
+ UINTN Arg4
+ )
+/*++
+
+Routine Description:
+
+ Place holder function until all the Boot Services and Runtime Services are available
+
+Arguments:
+
+ Arg1 - Undefined
+
+ Arg2 - Undefined
+
+ Arg3 - Undefined
+
+ Arg4 - Undefined
+
+Returns:
+
+ EFI_NOT_AVAILABLE_YET
+
+--*/
+;
+
+EFI_STATUS
+EFIAPI
+CoreEfiNotAvailableYetArg5 (
+ UINTN Arg1,
+ UINTN Arg2,
+ UINTN Arg3,
+ UINTN Arg4,
+ UINTN Arg5
+ )
+/*++
+
+Routine Description:
+
+ Place holder function until all the Boot Services and Runtime Services are available
+
+Arguments:
+
+ Arg1 - Undefined
+
+ Arg2 - Undefined
+
+ Arg3 - Undefined
+
+ Arg4 - Undefined
+
+ Arg5 - Undefined
+
+Returns:
+
+ EFI_NOT_AVAILABLE_YET
+
+--*/
+;
+
+EFI_STATUS
+CoreGetPeiProtocol (
+ IN EFI_GUID *ProtocolGuid,
+ IN VOID **Interface
+ )
+/*++
+
+Routine Description:
+
+ Searches for a Protocol Interface passed from PEI through a HOB
+
+Arguments:
+
+ ProtocolGuid - The Protocol GUID to search for in the HOB List
+
+ Interface - A pointer to the interface for the Protocol GUID
+
+Returns:
+
+ EFI_SUCCESS - The Protocol GUID was found and its interface is returned in Interface
+
+ EFI_NOT_FOUND - The Protocol GUID was not found in the HOB List
+
+--*/
+;
+
+EFI_STATUS
+DxeMainUefiDecompressGetInfo (
+ IN EFI_DECOMPRESS_PROTOCOL *This,
+ IN VOID *Source,
+ IN UINT32 SourceSize,
+ OUT UINT32 *DestinationSize,
+ OUT UINT32 *ScratchSize
+ );
+
+EFI_STATUS
+EFIAPI
+DxeMainUefiDecompress (
+ IN EFI_DECOMPRESS_PROTOCOL *This,
+ IN VOID *Source,
+ IN UINT32 SourceSize,
+ IN OUT VOID *Destination,
+ IN UINT32 DestinationSize,
+ IN OUT VOID *Scratch,
+ IN UINT32 ScratchSize
+ );
+
+EFI_STATUS
+DxeMainTianoDecompressGetInfo (
+ IN EFI_TIANO_DECOMPRESS_PROTOCOL *This,
+ IN VOID *Source,
+ IN UINT32 SourceSize,
+ OUT UINT32 *DestinationSize,
+ OUT UINT32 *ScratchSize
+ );
+
+EFI_STATUS
+EFIAPI
+DxeMainTianoDecompress (
+ IN EFI_TIANO_DECOMPRESS_PROTOCOL *This,
+ IN VOID *Source,
+ IN UINT32 SourceSize,
+ IN OUT VOID *Destination,
+ IN UINT32 DestinationSize,
+ IN OUT VOID *Scratch,
+ IN UINT32 ScratchSize
+ );
+
+EFI_STATUS
+DxeMainCustomDecompressGetInfo (
+ IN EFI_CUSTOMIZED_DECOMPRESS_PROTOCOL *This,
+ IN VOID *Source,
+ IN UINT32 SourceSize,
+ OUT UINT32 *DestinationSize,
+ OUT UINT32 *ScratchSize
+ );
+
+EFI_STATUS
+EFIAPI
+DxeMainCustomDecompress (
+ IN EFI_CUSTOMIZED_DECOMPRESS_PROTOCOL *This,
+ IN VOID *Source,
+ IN UINT32 SourceSize,
+ IN OUT VOID *Destination,
+ IN UINT32 DestinationSize,
+ IN OUT VOID *Scratch,
+ IN UINT32 ScratchSize
+ );
+
#endif
diff --git a/EdkModulePkg/Core/Dxe/DxeMain/DxeMain.c b/EdkModulePkg/Core/Dxe/DxeMain/DxeMain.c index 6b1f084e77..b590538fea 100644 --- a/EdkModulePkg/Core/Dxe/DxeMain/DxeMain.c +++ b/EdkModulePkg/Core/Dxe/DxeMain/DxeMain.c @@ -21,127 +21,6 @@ Abstract: #include <DxeMain.h>
-VOID
-EFIAPI
-DxeMain (
- IN VOID *HobStart
- );
-
-EFI_STATUS
-EFIAPI
-CoreEfiNotAvailableYetArg0 (
- VOID
- );
-
-EFI_STATUS
-EFIAPI
-CoreEfiNotAvailableYetArg1 (
- UINTN Arg1
- );
-
-EFI_STATUS
-EFIAPI
-CoreEfiNotAvailableYetArg2 (
- UINTN Arg1,
- UINTN Arg2
- );
-
-EFI_STATUS
-EFIAPI
-CoreEfiNotAvailableYetArg3 (
- UINTN Arg1,
- UINTN Arg2,
- UINTN Arg3
- );
-
-EFI_STATUS
-EFIAPI
-CoreEfiNotAvailableYetArg4 (
- UINTN Arg1,
- UINTN Arg2,
- UINTN Arg3,
- UINTN Arg4
- );
-
-EFI_STATUS
-EFIAPI
-CoreEfiNotAvailableYetArg5 (
- UINTN Arg1,
- UINTN Arg2,
- UINTN Arg3,
- UINTN Arg4,
- UINTN Arg5
- );
-
-EFI_STATUS
-CoreGetPeiProtocol (
- IN EFI_GUID *ProtocolGuid,
- IN VOID **Interface
- );
-
-EFI_STATUS
-DxeMainUefiDecompressGetInfo (
- IN EFI_DECOMPRESS_PROTOCOL *This,
- IN VOID *Source,
- IN UINT32 SourceSize,
- OUT UINT32 *DestinationSize,
- OUT UINT32 *ScratchSize
- );
-
-EFI_STATUS
-EFIAPI
-DxeMainUefiDecompress (
- IN EFI_DECOMPRESS_PROTOCOL *This,
- IN VOID *Source,
- IN UINT32 SourceSize,
- IN OUT VOID *Destination,
- IN UINT32 DestinationSize,
- IN OUT VOID *Scratch,
- IN UINT32 ScratchSize
- );
-
-EFI_STATUS
-DxeMainTianoDecompressGetInfo (
- IN EFI_TIANO_DECOMPRESS_PROTOCOL *This,
- IN VOID *Source,
- IN UINT32 SourceSize,
- OUT UINT32 *DestinationSize,
- OUT UINT32 *ScratchSize
- );
-
-EFI_STATUS
-EFIAPI
-DxeMainTianoDecompress (
- IN EFI_TIANO_DECOMPRESS_PROTOCOL *This,
- IN VOID *Source,
- IN UINT32 SourceSize,
- IN OUT VOID *Destination,
- IN UINT32 DestinationSize,
- IN OUT VOID *Scratch,
- IN UINT32 ScratchSize
- );
-
-EFI_STATUS
-DxeMainCustomDecompressGetInfo (
- IN EFI_CUSTOMIZED_DECOMPRESS_PROTOCOL *This,
- IN VOID *Source,
- IN UINT32 SourceSize,
- OUT UINT32 *DestinationSize,
- OUT UINT32 *ScratchSize
- );
-
-EFI_STATUS
-EFIAPI
-DxeMainCustomDecompress (
- IN EFI_CUSTOMIZED_DECOMPRESS_PROTOCOL *This,
- IN VOID *Source,
- IN UINT32 SourceSize,
- IN OUT VOID *Destination,
- IN UINT32 DestinationSize,
- IN OUT VOID *Scratch,
- IN UINT32 ScratchSize
- );
-
//
// DXE Core Global Variables for Protocols from PEI
//
diff --git a/EdkModulePkg/Core/Dxe/Event/timer.c b/EdkModulePkg/Core/Dxe/Event/timer.c index 8d7932f837..a49701519e 100644 --- a/EdkModulePkg/Core/Dxe/Event/timer.c +++ b/EdkModulePkg/Core/Dxe/Event/timer.c @@ -33,6 +33,7 @@ CoreCurrentSystemTime ( VOID
);
+STATIC
VOID
EFIAPI
CoreCheckTimers (
@@ -173,6 +174,7 @@ Returns: CoreReleaseLock (&mEfiSystemTimeLock);
}
+STATIC
VOID
EFIAPI
CoreCheckTimers (
diff --git a/EdkModulePkg/Core/Dxe/Image/ImageFile.c b/EdkModulePkg/Core/Dxe/Image/ImageFile.c index 999cd694ad..408688c69f 100644 --- a/EdkModulePkg/Core/Dxe/Image/ImageFile.c +++ b/EdkModulePkg/Core/Dxe/Image/ImageFile.c @@ -25,15 +25,6 @@ Revision History #include <DxeMain.h>
-
-VOID
-CoreDevicePathToFileName (
- IN FILEPATH_DEVICE_PATH *FilePath,
- OUT CHAR16 **String
- );
-
-
-
EFI_STATUS
CoreOpenImageFile (
IN BOOLEAN BootPolicy,
@@ -432,67 +423,6 @@ Returns: return Status;
}
-
-VOID
-CoreDevicePathToFileName (
- IN FILEPATH_DEVICE_PATH *FilePath,
- OUT CHAR16 **String
- )
-/*++
-
-Routine Description:
-
- Transfer a device's full path a string.
-
-Arguments:
-
- FilePath - Device path
-
- String - The string represent the device's full path
-
-Returns:
-
- None
-
---*/
-{
- UINTN StringSize;
- FILEPATH_DEVICE_PATH *FilePathNode;
- CHAR16 *Str;
-
- *String = NULL;
- StringSize = 0;
- FilePathNode = FilePath;
- while (!IsDevicePathEnd (&FilePathNode->Header)) {
-
- //
- // For filesystem access each node should be a filepath component
- //
- if (DevicePathType (&FilePathNode->Header) != MEDIA_DEVICE_PATH ||
- DevicePathSubType (&FilePathNode->Header) != MEDIA_FILEPATH_DP) {
-
- return;
- }
-
- StringSize += StrLen (FilePathNode->PathName);
-
- FilePathNode = (FILEPATH_DEVICE_PATH *) NextDevicePathNode (&FilePathNode->Header);
- }
-
- *String = CoreAllocateBootServicesPool (StringSize);
- if (*String == NULL) {
- return;
- }
-
- FilePathNode = FilePath;
- Str = *String;
- while (!IsDevicePathEnd (&FilePathNode->Header)) {
- StrCat (Str, FilePathNode->PathName);
- FilePathNode = (FILEPATH_DEVICE_PATH *) NextDevicePathNode (&FilePathNode->Header);
- }
-}
-
-
BOOLEAN
CoreGrowBuffer (
IN OUT EFI_STATUS *Status,
diff --git a/EdkModulePkg/Core/Dxe/Mem/Page.c b/EdkModulePkg/Core/Dxe/Mem/Page.c index 44116abcb6..4f66e0a3d2 100644 --- a/EdkModulePkg/Core/Dxe/Mem/Page.c +++ b/EdkModulePkg/Core/Dxe/Mem/Page.c @@ -94,6 +94,7 @@ EFI_MEMORY_TYPE_INFORMATION gMemoryTypeInformation[EfiMaxMemoryType + 1] = { //
// Internal prototypes
//
+STATIC
VOID
PromoteMemoryResource (
VOID
@@ -175,6 +176,7 @@ Returns: CoreReleaseLock (&gMemoryLock);
}
+STATIC
VOID
PromoteMemoryResource (
VOID
diff --git a/EdkModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c b/EdkModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c index 89dd9afcc1..a3e20e69e8 100644 --- a/EdkModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c +++ b/EdkModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c @@ -131,6 +131,7 @@ CreateGuidedExtractionRpnEvent ( IN CORE_SECTION_CHILD_NODE *ChildNode
);
+STATIC
EFI_STATUS
EFIAPI
OpenSectionStream (
@@ -140,6 +141,7 @@ OpenSectionStream ( OUT UINTN *SectionStreamHandle
);
+STATIC
EFI_STATUS
EFIAPI
GetSection (
@@ -153,6 +155,7 @@ GetSection ( OUT UINT32 *AuthenticationStatus
);
+STATIC
EFI_STATUS
EFIAPI
CloseSectionStream (
@@ -262,7 +265,7 @@ Returns: return Status;
}
-
+STATIC
EFI_STATUS
EFIAPI
OpenSectionStream (
@@ -308,7 +311,7 @@ Returns: );
}
-
+STATIC
EFI_STATUS
EFIAPI
GetSection (
@@ -451,7 +454,7 @@ GetSection_Done: }
-
+STATIC
EFI_STATUS
EFIAPI
CloseSectionStream (
diff --git a/EdkModulePkg/Core/Pei/Dispatcher/Dispatcher.c b/EdkModulePkg/Core/Pei/Dispatcher/Dispatcher.c index ccd840d376..c764b3907e 100644 --- a/EdkModulePkg/Core/Pei/Dispatcher/Dispatcher.c +++ b/EdkModulePkg/Core/Pei/Dispatcher/Dispatcher.c @@ -23,6 +23,7 @@ Revision History #include <PeiMain.h>
+STATIC
VOID *
TransferOldDataToNewDataRange (
IN PEI_CORE_INSTANCE *PrivateData
@@ -506,7 +507,7 @@ Returns: return Runnable;
}
-
+STATIC
VOID *
TransferOldDataToNewDataRange (
IN PEI_CORE_INSTANCE *PrivateData
diff --git a/EdkModulePkg/Core/Pei/Ipf/IpfPeiMain.h b/EdkModulePkg/Core/Pei/Ipf/IpfPeiMain.h new file mode 100644 index 0000000000..e2df07378e --- /dev/null +++ b/EdkModulePkg/Core/Pei/Ipf/IpfPeiMain.h @@ -0,0 +1,52 @@ +/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+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.
+
+Module Name:
+
+ IpfPeiMain.h
+
+Abstract:
+
+ Definition of IPF specific function
+
+Revision History
+
+--*/
+
+#ifndef _IPF_PEI_MAIN_H_
+#define _IPF_PEI_MAIN_H_
+
+#include <PeiMain.h>
+
+SAL_RETURN_REGS
+GetHandOffStatus (
+ VOID
+ )
+/*++
+
+Routine Description:
+
+ This routine is called by all processors simultaneously, to get some hand-off
+ status that has been captured by IPF dispatcher and recorded in kernel registers.
+
+Arguments :
+
+ On Entry : None.
+
+Returns:
+
+ Lid, R20Status.
+
+--*/
+
+;
+
+#endif
diff --git a/EdkModulePkg/Core/Pei/Ipf/SwitchToCacheMode.c b/EdkModulePkg/Core/Pei/Ipf/SwitchToCacheMode.c index 36b66f93d9..db9cb52adf 100644 --- a/EdkModulePkg/Core/Pei/Ipf/SwitchToCacheMode.c +++ b/EdkModulePkg/Core/Pei/Ipf/SwitchToCacheMode.c @@ -20,14 +20,9 @@ Abstract: Revision History
--*/
-#include <PeiMain.h>
-#include "IpfCpuCore.i"
-extern
-SAL_RETURN_REGS
-GetHandOffStatus (
- VOID
- );
+#include "IpfPeiMain.h"
+#include "IpfCpuCore.i"
VOID
SwitchToCacheMode (
diff --git a/EdkModulePkg/Core/Pei/PeiMain.msa b/EdkModulePkg/Core/Pei/PeiMain.msa index 250d5390ed..5daf40f64d 100644 --- a/EdkModulePkg/Core/Pei/PeiMain.msa +++ b/EdkModulePkg/Core/Pei/PeiMain.msa @@ -74,6 +74,7 @@ <Filename SupArchList="IPF">Ipf/SwitchToCacheMode.c</Filename>
<Filename SupArchList="IPF">Ipf/IpfCpuCore.i</Filename>
<Filename SupArchList="IPF">Ipf/IpfCpuCore.s</Filename>
+ <Filename SupArchList="IPF">Ipf/IpfPeiMain.h</Filename>
<Filename SupArchList="IPF">Ipf/Stack.c</Filename>
<Filename SupArchList="IA32 X64 EBC">Dispatcher/Stack.c</Filename>
</SourceFiles>
diff --git a/EdkModulePkg/Core/Pei/Security/Security.c b/EdkModulePkg/Core/Pei/Security/Security.c index 0bc175a856..089995e529 100644 --- a/EdkModulePkg/Core/Pei/Security/Security.c +++ b/EdkModulePkg/Core/Pei/Security/Security.c @@ -21,6 +21,7 @@ Abstract: #include <PeiMain.h>
+STATIC
EFI_STATUS
EFIAPI
SecurityPpiNotifyCallback (
@@ -63,6 +64,7 @@ Returns: return;
}
+STATIC
EFI_STATUS
EFIAPI
SecurityPpiNotifyCallback (
diff --git a/EdkModulePkg/Library/DxeCorePerformanceLib/DxeCorePerformanceLib.c b/EdkModulePkg/Library/DxeCorePerformanceLib/DxeCorePerformanceLib.c index bd4b5adcec..727133226c 100644 --- a/EdkModulePkg/Library/DxeCorePerformanceLib/DxeCorePerformanceLib.c +++ b/EdkModulePkg/Library/DxeCorePerformanceLib/DxeCorePerformanceLib.c @@ -45,6 +45,7 @@ Abstract: @retval EFI_OUT_OF_RESOURCES There are not enough resources to record the measurement.
**/
+STATIC
EFI_STATUS
EFIAPI
StartGauge (
@@ -78,6 +79,7 @@ StartGauge ( @retval EFI_NOT_FOUND The specified measurement record could not be found.
**/
+STATIC
EFI_STATUS
EFIAPI
EndGauge (
@@ -105,6 +107,7 @@ EndGauge ( @retval EFI_INVALIDE_PARAMETER GaugeDataEntry is NULL.
**/
+STATIC
EFI_STATUS
EFIAPI
GetGauge (
@@ -202,6 +205,7 @@ InternalSearchForGaugeEntry ( @retval EFI_OUT_OF_RESOURCES There are not enough resources to record the measurement.
**/
+STATIC
EFI_STATUS
EFIAPI
StartGauge (
@@ -284,6 +288,7 @@ StartGauge ( @retval EFI_NOT_FOUND The specified measurement record could not be found.
**/
+STATIC
EFI_STATUS
EFIAPI
EndGauge (
@@ -328,6 +333,7 @@ EndGauge ( @retval EFI_INVALIDE_PARAMETER GaugeDataEntry is NULL.
**/
+STATIC
EFI_STATUS
EFIAPI
GetGauge (
diff --git a/EdkModulePkg/Universal/Console/ConSplitter/Dxe/ComponentName.c b/EdkModulePkg/Universal/Console/ConSplitter/Dxe/ComponentName.c index dc2a22f447..f82ae55c4e 100644 --- a/EdkModulePkg/Universal/Console/ConSplitter/Dxe/ComponentName.c +++ b/EdkModulePkg/Universal/Console/ConSplitter/Dxe/ComponentName.c @@ -20,57 +20,6 @@ Abstract: #include "ConSplitter.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-ConSplitterComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-ConSplitterConInComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-EFI_STATUS
-EFIAPI
-ConSplitterSimplePointerComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-EFI_STATUS
-EFIAPI
-ConSplitterConOutComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-EFI_STATUS
-EFIAPI
-ConSplitterStdErrComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gConSplitterConInComponentName = {
diff --git a/EdkModulePkg/Universal/Console/ConSplitter/Dxe/ConSplitter.h b/EdkModulePkg/Universal/Console/ConSplitter/Dxe/ConSplitter.h index 4509390e83..13c4e743db 100644 --- a/EdkModulePkg/Universal/Console/ConSplitter/Dxe/ConSplitter.h +++ b/EdkModulePkg/Universal/Console/ConSplitter/Dxe/ConSplitter.h @@ -293,6 +293,54 @@ ConSplitterStdErrDriverBindingStop ( )
;
+EFI_STATUS
+EFIAPI
+ConSplitterComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+ConSplitterConInComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
+EFI_STATUS
+EFIAPI
+ConSplitterSimplePointerComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
+EFI_STATUS
+EFIAPI
+ConSplitterConOutComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
+EFI_STATUS
+EFIAPI
+ConSplitterStdErrComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
//
// TextIn Constructor/Destructor functions
//
diff --git a/EdkModulePkg/Universal/Console/GraphicsConsole/Dxe/GraphicsConsole.c b/EdkModulePkg/Universal/Console/GraphicsConsole/Dxe/GraphicsConsole.c index 866aaad444..4a2dd5928c 100644 --- a/EdkModulePkg/Universal/Console/GraphicsConsole/Dxe/GraphicsConsole.c +++ b/EdkModulePkg/Universal/Console/GraphicsConsole/Dxe/GraphicsConsole.c @@ -19,34 +19,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #include "GraphicsConsole.h"
-//
-// Function Prototypes
-//
-EFI_STATUS
-EFIAPI
-GraphicsConsoleControllerDriverSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-GraphicsConsoleControllerDriverStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-GraphicsConsoleControllerDriverStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
+STATIC
EFI_STATUS
GetTextColors (
IN EFI_SIMPLE_TEXT_OUT_PROTOCOL *This,
@@ -54,12 +27,7 @@ GetTextColors ( OUT EFI_GRAPHICS_OUTPUT_BLT_PIXEL *Background
);
-EFI_STATUS
-DrawUnicodeWeightAtCursor (
- IN EFI_SIMPLE_TEXT_OUT_PROTOCOL *This,
- IN CHAR16 UnicodeWeight
- );
-
+STATIC
EFI_STATUS
DrawUnicodeWeightAtCursorN (
IN EFI_SIMPLE_TEXT_OUT_PROTOCOL *This,
@@ -67,6 +35,7 @@ DrawUnicodeWeightAtCursorN ( IN UINTN Count
);
+STATIC
EFI_STATUS
EraseCursor (
IN EFI_SIMPLE_TEXT_OUT_PROTOCOL *This
@@ -1532,6 +1501,7 @@ GraphicsConsoleConOutEnableCursor ( return EFI_SUCCESS;
}
+STATIC
EFI_STATUS
GetTextColors (
IN EFI_SIMPLE_TEXT_OUT_PROTOCOL *This,
@@ -1549,6 +1519,7 @@ GetTextColors ( return EFI_SUCCESS;
}
+STATIC
EFI_STATUS
DrawUnicodeWeightAtCursorN (
IN EFI_SIMPLE_TEXT_OUT_PROTOCOL *This,
@@ -1689,6 +1660,7 @@ DrawUnicodeWeightAtCursorN ( return ReturnStatus;
}
+STATIC
EFI_STATUS
EraseCursor (
IN EFI_SIMPLE_TEXT_OUT_PROTOCOL *This
diff --git a/EdkModulePkg/Universal/Console/GraphicsConsole/Dxe/GraphicsConsole.h b/EdkModulePkg/Universal/Console/GraphicsConsole/Dxe/GraphicsConsole.h index 45a2ec4764..bcc1d56746 100644 --- a/EdkModulePkg/Universal/Console/GraphicsConsole/Dxe/GraphicsConsole.h +++ b/EdkModulePkg/Universal/Console/GraphicsConsole/Dxe/GraphicsConsole.h @@ -159,4 +159,29 @@ EfiLocateHiiProtocol ( VOID
);
+EFI_STATUS
+EFIAPI
+GraphicsConsoleControllerDriverSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+GraphicsConsoleControllerDriverStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+GraphicsConsoleControllerDriverStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
#endif
diff --git a/EdkModulePkg/Universal/Console/Terminal/Dxe/ComponentName.c b/EdkModulePkg/Universal/Console/Terminal/Dxe/ComponentName.c index 7a1c23d17c..bdc6df471d 100644 --- a/EdkModulePkg/Universal/Console/Terminal/Dxe/ComponentName.c +++ b/EdkModulePkg/Universal/Console/Terminal/Dxe/ComponentName.c @@ -21,27 +21,6 @@ Abstract: #include "Terminal.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-TerminalComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-TerminalComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gTerminalComponentName = {
diff --git a/EdkModulePkg/Universal/Console/Terminal/Dxe/Terminal.c b/EdkModulePkg/Universal/Console/Terminal/Dxe/Terminal.c index 45eb632e26..6aa70e4c95 100644 --- a/EdkModulePkg/Universal/Console/Terminal/Dxe/Terminal.c +++ b/EdkModulePkg/Universal/Console/Terminal/Dxe/Terminal.c @@ -23,34 +23,6 @@ Revision History: #include "Terminal.h"
//
-// Function Prototypes
-//
-EFI_STATUS
-EFIAPI
-TerminalDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-TerminalDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-TerminalDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
-//
// Globals
//
EFI_DRIVER_BINDING_PROTOCOL gTerminalDriverBinding = {
diff --git a/EdkModulePkg/Universal/Console/Terminal/Dxe/Terminal.h b/EdkModulePkg/Universal/Console/Terminal/Dxe/Terminal.h index 2382d86f7e..e7ce1dc324 100644 --- a/EdkModulePkg/Universal/Console/Terminal/Dxe/Terminal.h +++ b/EdkModulePkg/Universal/Console/Terminal/Dxe/Terminal.h @@ -244,6 +244,49 @@ TerminalConOutEnableCursor ( )
;
+EFI_STATUS
+EFIAPI
+TerminalDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+TerminalDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+TerminalDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+EFI_STATUS
+EFIAPI
+TerminalComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+TerminalComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
//
// internal functions
//
diff --git a/EdkModulePkg/Universal/Disk/DiskIo/Dxe/ComponentName.c b/EdkModulePkg/Universal/Disk/DiskIo/Dxe/ComponentName.c index 35ca70d8f8..86ed5f29f0 100644 --- a/EdkModulePkg/Universal/Disk/DiskIo/Dxe/ComponentName.c +++ b/EdkModulePkg/Universal/Disk/DiskIo/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "DiskIo.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-DiskIoComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-DiskIoComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gDiskIoComponentName = {
diff --git a/EdkModulePkg/Universal/Disk/DiskIo/Dxe/DiskIo.h b/EdkModulePkg/Universal/Disk/DiskIo/Dxe/DiskIo.h index 39d87661c6..cdb67390ba 100644 --- a/EdkModulePkg/Universal/Disk/DiskIo/Dxe/DiskIo.h +++ b/EdkModulePkg/Universal/Disk/DiskIo/Dxe/DiskIo.h @@ -41,4 +41,77 @@ typedef struct { extern EFI_DRIVER_BINDING_PROTOCOL gDiskIoDriverBinding;
extern EFI_COMPONENT_NAME_PROTOCOL gDiskIoComponentName;
+//
+// Prototypes
+// Driver model protocol interface
+//
+EFI_STATUS
+EFIAPI
+DiskIoDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+DiskIoDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+DiskIoDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// Disk I/O Protocol Interface
+//
+EFI_STATUS
+EFIAPI
+DiskIoReadDisk (
+ IN EFI_DISK_IO_PROTOCOL *This,
+ IN UINT32 MediaId,
+ IN UINT64 Offset,
+ IN UINTN BufferSize,
+ OUT VOID *Buffer
+ );
+
+EFI_STATUS
+EFIAPI
+DiskIoWriteDisk (
+ IN EFI_DISK_IO_PROTOCOL *This,
+ IN UINT32 MediaId,
+ IN UINT64 Offset,
+ IN UINTN BufferSize,
+ IN VOID *Buffer
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+DiskIoComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+DiskIoComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
#endif
diff --git a/EdkModulePkg/Universal/Disk/DiskIo/Dxe/diskio.c b/EdkModulePkg/Universal/Disk/DiskIo/Dxe/diskio.c index d378ae3e33..62ae6d2b8a 100644 --- a/EdkModulePkg/Universal/Disk/DiskIo/Dxe/diskio.c +++ b/EdkModulePkg/Universal/Disk/DiskIo/Dxe/diskio.c @@ -32,58 +32,6 @@ Abstract: #include "DiskIo.h"
-//
-// Prototypes
-// Driver model protocol interface
-//
-EFI_STATUS
-EFIAPI
-DiskIoDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-DiskIoDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-DiskIoDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
-//
-// Disk I/O Protocol Interface
-//
-EFI_STATUS
-EFIAPI
-DiskIoReadDisk (
- IN EFI_DISK_IO_PROTOCOL *This,
- IN UINT32 MediaId,
- IN UINT64 Offset,
- IN UINTN BufferSize,
- OUT VOID *Buffer
- );
-
-EFI_STATUS
-EFIAPI
-DiskIoWriteDisk (
- IN EFI_DISK_IO_PROTOCOL *This,
- IN UINT32 MediaId,
- IN UINT64 Offset,
- IN UINTN BufferSize,
- IN VOID *Buffer
- );
-
EFI_DRIVER_BINDING_PROTOCOL gDiskIoDriverBinding = {
DiskIoDriverBindingSupported,
DiskIoDriverBindingStart,
diff --git a/EdkModulePkg/Universal/Disk/Partition/Dxe/ComponentName.c b/EdkModulePkg/Universal/Disk/Partition/Dxe/ComponentName.c index 3821690f0c..96ff648332 100644 --- a/EdkModulePkg/Universal/Disk/Partition/Dxe/ComponentName.c +++ b/EdkModulePkg/Universal/Disk/Partition/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "Partition.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-PartitionComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-PartitionComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gPartitionComponentName = {
diff --git a/EdkModulePkg/Universal/Disk/Partition/Dxe/Gpt.c b/EdkModulePkg/Universal/Disk/Partition/Dxe/Gpt.c index 42411806f6..4b4910a813 100644 --- a/EdkModulePkg/Universal/Disk/Partition/Dxe/Gpt.c +++ b/EdkModulePkg/Universal/Disk/Partition/Dxe/Gpt.c @@ -22,6 +22,7 @@ Abstract: #include "Partition.h"
+STATIC
BOOLEAN
PartitionValidGptTable (
IN EFI_BLOCK_IO_PROTOCOL *BlockIo,
@@ -30,6 +31,7 @@ PartitionValidGptTable ( OUT EFI_PARTITION_TABLE_HEADER *PartHeader
);
+STATIC
BOOLEAN
PartitionCheckGptEntryArrayCRC (
IN EFI_BLOCK_IO_PROTOCOL *BlockIo,
@@ -37,6 +39,7 @@ PartitionCheckGptEntryArrayCRC ( IN EFI_PARTITION_TABLE_HEADER *PartHeader
);
+STATIC
BOOLEAN
PartitionRestoreGptTable (
IN EFI_BLOCK_IO_PROTOCOL *BlockIo,
@@ -44,6 +47,7 @@ PartitionRestoreGptTable ( IN EFI_PARTITION_TABLE_HEADER *PartHeader
);
+STATIC
VOID
PartitionCheckGptEntry (
IN EFI_PARTITION_TABLE_HEADER *PartHeader,
@@ -51,6 +55,7 @@ PartitionCheckGptEntry ( OUT EFI_PARTITION_ENTRY_STATUS *PEntryStatus
);
+STATIC
BOOLEAN
PartitionCheckCrcAltSize (
IN UINTN MaxSize,
@@ -58,18 +63,21 @@ PartitionCheckCrcAltSize ( IN OUT EFI_TABLE_HEADER *Hdr
);
+STATIC
BOOLEAN
PartitionCheckCrc (
IN UINTN MaxSize,
IN OUT EFI_TABLE_HEADER *Hdr
);
+STATIC
VOID
PartitionSetCrcAltSize (
IN UINTN Size,
IN OUT EFI_TABLE_HEADER *Hdr
);
+STATIC
VOID
PartitionSetCrc (
IN OUT EFI_TABLE_HEADER *Hdr
@@ -320,6 +328,7 @@ Done: return GptValid;
}
+STATIC
BOOLEAN
PartitionValidGptTable (
IN EFI_BLOCK_IO_PROTOCOL *BlockIo,
@@ -391,6 +400,7 @@ Returns: return TRUE;
}
+STATIC
BOOLEAN
PartitionCheckGptEntryArrayCRC (
IN EFI_BLOCK_IO_PROTOCOL *BlockIo,
@@ -457,6 +467,7 @@ Returns: return (BOOLEAN) (PartHeader->PartitionEntryArrayCRC32 == Crc);
}
+STATIC
BOOLEAN
PartitionRestoreGptTable (
IN EFI_BLOCK_IO_PROTOCOL *BlockIo,
@@ -554,6 +565,7 @@ Done: return TRUE;
}
+STATIC
VOID
PartitionCheckGptEntry (
IN EFI_PARTITION_TABLE_HEADER *PartHeader,
@@ -622,6 +634,7 @@ Returns: DEBUG ((EFI_D_INFO, " End check partition entries\n"));
}
+STATIC
VOID
PartitionSetCrc (
IN OUT EFI_TABLE_HEADER *Hdr
@@ -645,6 +658,7 @@ Returns: PartitionSetCrcAltSize (Hdr->HeaderSize, Hdr);
}
+STATIC
VOID
PartitionSetCrcAltSize (
IN UINTN Size,
@@ -674,6 +688,7 @@ Returns: Hdr->CRC32 = Crc;
}
+STATIC
BOOLEAN
PartitionCheckCrc (
IN UINTN MaxSize,
@@ -699,6 +714,7 @@ Returns: return PartitionCheckCrcAltSize (MaxSize, Hdr->HeaderSize, Hdr);
}
+STATIC
BOOLEAN
PartitionCheckCrcAltSize (
IN UINTN MaxSize,
diff --git a/EdkModulePkg/Universal/Disk/Partition/Dxe/Partition.c b/EdkModulePkg/Universal/Disk/Partition/Dxe/Partition.c index 6a896e4e72..b4207d42b8 100644 --- a/EdkModulePkg/Universal/Disk/Partition/Dxe/Partition.c +++ b/EdkModulePkg/Universal/Disk/Partition/Dxe/Partition.c @@ -25,41 +25,6 @@ Abstract: #include "Partition.h"
//
-// Function Prototypes
-//
-EFI_STATUS
-EFIAPI
-PartitionEntryPoint (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- );
-
-EFI_STATUS
-EFIAPI
-PartitionDriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-PartitionDriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-PartitionDriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
-//
// Partition Driver Global Variables
//
EFI_DRIVER_BINDING_PROTOCOL gPartitionDriverBinding = {
diff --git a/EdkModulePkg/Universal/Disk/Partition/Dxe/Partition.h b/EdkModulePkg/Universal/Disk/Partition/Dxe/Partition.h index ba105554e9..a52b8f5103 100644 --- a/EdkModulePkg/Universal/Disk/Partition/Dxe/Partition.h +++ b/EdkModulePkg/Universal/Disk/Partition/Dxe/Partition.h @@ -77,6 +77,55 @@ extern EFI_COMPONENT_NAME_PROTOCOL gPartitionComponentName; (((UINT8 *) a)[2] << 16) | \
(((UINT8 *) a)[3] << 24) )
+//
+// Function Prototypes
+//
+EFI_STATUS
+EFIAPI
+PartitionDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+PartitionDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+PartitionDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+PartitionComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+PartitionComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
EFI_STATUS
PartitionInstallChildHandle (
IN EFI_DRIVER_BINDING_PROTOCOL *This,
diff --git a/EdkModulePkg/Universal/Ebc/Dxe/EbcExecute.c b/EdkModulePkg/Universal/Ebc/Dxe/EbcExecute.c index ce9b3aa547..5e6b3e3a8f 100644 --- a/EdkModulePkg/Universal/Ebc/Dxe/EbcExecute.c +++ b/EdkModulePkg/Universal/Ebc/Dxe/EbcExecute.c @@ -134,20 +134,6 @@ VmWriteMem32 ( IN UINT32 Data
);
-EFI_STATUS
-VmWriteMemN (
- IN VM_CONTEXT *VmPtr,
- UINTN Addr,
- IN UINTN Data
- );
-
-EFI_STATUS
-VmWriteMem64 (
- IN VM_CONTEXT *VmPtr,
- UINTN Addr,
- IN UINT64 Data
- );
-
STATIC
UINT16
VmReadCode16 (
diff --git a/EdkModulePkg/Universal/Ebc/Dxe/EbcInt.c b/EdkModulePkg/Universal/Ebc/Dxe/EbcInt.c index e38f5be730..cf683295ea 100644 --- a/EdkModulePkg/Universal/Ebc/Dxe/EbcInt.c +++ b/EdkModulePkg/Universal/Ebc/Dxe/EbcInt.c @@ -41,16 +41,6 @@ typedef struct _EBC_IMAGE_LIST { EBC_THUNK_LIST *ThunkList;
} EBC_IMAGE_LIST;
-//
-// Function prototypes
-//
-EFI_STATUS
-EFIAPI
-InitializeEbcDriver (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- );
-
STATIC
EFI_STATUS
EFIAPI
@@ -77,12 +67,14 @@ EbcGetVersion ( IN OUT UINT64 *Version
);
+STATIC
EFI_STATUS
EFIAPI
InitializeEbcCallback (
IN EFI_DEBUG_SUPPORT_PROTOCOL *This
);
+STATIC
VOID
EFIAPI
CommonEbcExceptionHandler (
@@ -90,6 +82,7 @@ CommonEbcExceptionHandler ( IN EFI_SYSTEM_CONTEXT SystemContext
);
+STATIC
VOID
EFIAPI
EbcPeriodicNotifyFunction (
@@ -97,6 +90,7 @@ EbcPeriodicNotifyFunction ( IN VOID *Context
);
+STATIC
EFI_STATUS
EFIAPI
EbcDebugPeriodic (
@@ -646,6 +640,7 @@ Returns: return EFI_SUCCESS;
}
+STATIC
EFI_STATUS
InitializeEbcCallback (
IN EFI_DEBUG_SUPPORT_PROTOCOL *This
@@ -707,6 +702,7 @@ Returns: return EFI_SUCCESS;
}
+STATIC
VOID
CommonEbcExceptionHandler (
IN EFI_EXCEPTION_TYPE InterruptType,
@@ -739,6 +735,7 @@ Returns: return ;
}
+STATIC
VOID
EFIAPI
EbcPeriodicNotifyFunction (
@@ -774,7 +771,7 @@ Returns: return ;
}
-
+STATIC
EFI_STATUS
EbcDebugPeriodic (
IN VM_CONTEXT *VmPtr
diff --git a/EdkModulePkg/Universal/Ebc/Dxe/Ipf/EbcSupport.c b/EdkModulePkg/Universal/Ebc/Dxe/Ipf/EbcSupport.c index 279f4202b6..29ee55b864 100644 --- a/EdkModulePkg/Universal/Ebc/Dxe/Ipf/EbcSupport.c +++ b/EdkModulePkg/Universal/Ebc/Dxe/Ipf/EbcSupport.c @@ -22,34 +22,7 @@ Abstract: #include "EbcInt.h"
#include "EbcExecute.h"
-
-#define VM_STACK_SIZE (1024 * 32)
-
-#define EBC_THUNK_SIZE 128
-
-//
-// For code execution, thunks must be aligned on 16-byte boundary
-//
-#define EBC_THUNK_ALIGNMENT 16
-
-//
-// Opcodes for IPF instructions. We'll need to hand-create thunk code (stuffing
-// bits) to insert a jump to the interpreter.
-//
-#define OPCODE_NOP (UINT64) 0x00008000000
-#define OPCODE_BR_COND_SPTK_FEW (UINT64) 0x00100000000
-#define OPCODE_MOV_BX_RX (UINT64) 0x00E00100000
-
-//
-// Opcode for MOVL instruction
-//
-#define MOVL_OPCODE 0x06
-
-VOID
-EbcAsmLLCALLEX (
- IN UINTN CallAddr,
- IN UINTN EbcSp
- );
+#include "EbcSupport.h"
STATIC
EFI_STATUS
diff --git a/EdkModulePkg/Universal/Ebc/Dxe/Ipf/EbcSupport.h b/EdkModulePkg/Universal/Ebc/Dxe/Ipf/EbcSupport.h new file mode 100644 index 0000000000..93c568edc1 --- /dev/null +++ b/EdkModulePkg/Universal/Ebc/Dxe/Ipf/EbcSupport.h @@ -0,0 +1,55 @@ +/*++
+
+Copyright (c) 2006, Intel Corporation
+All rights reserved. This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+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.
+
+Module Name:
+
+ EbcSupport.h
+
+Abstract:
+
+ Definition of EBC Support function
+
+Revision History
+
+--*/
+
+#ifndef _IPF_EBC_SUPPORT_H_
+#define _IPF_EBC_SUPPORT_H_
+
+#define VM_STACK_SIZE (1024 * 32)
+
+#define EBC_THUNK_SIZE 128
+
+//
+// For code execution, thunks must be aligned on 16-byte boundary
+//
+#define EBC_THUNK_ALIGNMENT 16
+
+//
+// Opcodes for IPF instructions. We'll need to hand-create thunk code (stuffing
+// bits) to insert a jump to the interpreter.
+//
+#define OPCODE_NOP (UINT64) 0x00008000000
+#define OPCODE_BR_COND_SPTK_FEW (UINT64) 0x00100000000
+#define OPCODE_MOV_BX_RX (UINT64) 0x00E00100000
+
+//
+// Opcode for MOVL instruction
+//
+#define MOVL_OPCODE 0x06
+
+VOID
+EbcAsmLLCALLEX (
+ IN UINTN CallAddr,
+ IN UINTN EbcSp
+ );
+
+#endif
diff --git a/EdkModulePkg/Universal/EmuVariable/RuntimeDxe/Ipf/InitVariable.c b/EdkModulePkg/Universal/EmuVariable/RuntimeDxe/Ipf/InitVariable.c index da71705dae..b4b29cf7c6 100644 --- a/EdkModulePkg/Universal/EmuVariable/RuntimeDxe/Ipf/InitVariable.c +++ b/EdkModulePkg/Universal/EmuVariable/RuntimeDxe/Ipf/InitVariable.c @@ -24,7 +24,6 @@ Revision History //
// Don't use module globals after the SetVirtualAddress map is signaled
//
-extern ESAL_VARIABLE_GLOBAL *mVariableModuleGlobal;
STATIC
SAL_RETURN_REGS
diff --git a/EdkModulePkg/Universal/EmuVariable/RuntimeDxe/Variable.h b/EdkModulePkg/Universal/EmuVariable/RuntimeDxe/Variable.h index 55423a25b9..bf21a3e86d 100644 --- a/EdkModulePkg/Universal/EmuVariable/RuntimeDxe/Variable.h +++ b/EdkModulePkg/Universal/EmuVariable/RuntimeDxe/Variable.h @@ -74,6 +74,8 @@ typedef struct { UINT32 FvbInstance;
} ESAL_VARIABLE_GLOBAL;
+extern ESAL_VARIABLE_GLOBAL *mVariableModuleGlobal;
+
//
// Functions
//
diff --git a/EdkModulePkg/Universal/FirmwareVolume/GuidedSectionExtraction/Crc32SectionExtract/Dxe/Crc32SectionExtract.c b/EdkModulePkg/Universal/FirmwareVolume/GuidedSectionExtraction/Crc32SectionExtract/Dxe/Crc32SectionExtract.c index 143836be82..7e196d6453 100644 --- a/EdkModulePkg/Universal/FirmwareVolume/GuidedSectionExtraction/Crc32SectionExtract/Dxe/Crc32SectionExtract.c +++ b/EdkModulePkg/Universal/FirmwareVolume/GuidedSectionExtraction/Crc32SectionExtract/Dxe/Crc32SectionExtract.c @@ -32,13 +32,6 @@ EFIAPI InitializeCrc32GuidedSectionExtractionProtocol (
IN EFI_HANDLE ImageHandle,
IN EFI_SYSTEM_TABLE *SystemTable
- );
-
-EFI_STATUS
-EFIAPI
-InitializeCrc32GuidedSectionExtractionProtocol (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
)
/*++
diff --git a/EdkModulePkg/Universal/FirmwareVolume/GuidedSectionExtraction/Crc32SectionExtract/Dxe/Crc32SectionExtract.h b/EdkModulePkg/Universal/FirmwareVolume/GuidedSectionExtraction/Crc32SectionExtract/Dxe/Crc32SectionExtract.h index de2bb3a80a..387e637cd0 100644 --- a/EdkModulePkg/Universal/FirmwareVolume/GuidedSectionExtraction/Crc32SectionExtract/Dxe/Crc32SectionExtract.h +++ b/EdkModulePkg/Universal/FirmwareVolume/GuidedSectionExtraction/Crc32SectionExtract/Dxe/Crc32SectionExtract.h @@ -63,4 +63,33 @@ Returns: --*/
;
+EFI_STATUS
+EFIAPI
+InitializeCrc32GuidedSectionExtractionProtocol (
+ IN EFI_HANDLE ImageHandle,
+ IN EFI_SYSTEM_TABLE *SystemTable
+ )
+/*++
+
+Routine Description:
+
+ Entry point of the CRC32 GUIDed section extraction protocol.
+ Creates and initializes an instance of the GUIDed section
+ extraction protocol with CRC32 GUID.
+
+Arguments:
+
+ ImageHandle EFI_HANDLE: A handle for the image that is initializing
+ this driver
+ SystemTable EFI_SYSTEM_TABLE: A pointer to the EFI system table
+
+Returns:
+
+ EFI_SUCCESS: Driver initialized successfully
+ EFI_LOAD_ERROR: Failed to Initialize or has been loaded
+ EFI_OUT_OF_RESOURCES: Could not allocate needed resources
+
+--*/
+;
+
#endif
diff --git a/EdkModulePkg/Universal/Network/PxeBc/Dxe/Bc.h b/EdkModulePkg/Universal/Network/PxeBc/Dxe/Bc.h index 6d5a616af4..26df291a29 100644 --- a/EdkModulePkg/Universal/Network/PxeBc/Dxe/Bc.h +++ b/EdkModulePkg/Universal/Network/PxeBc/Dxe/Bc.h @@ -163,6 +163,52 @@ typedef struct { #define EFI_LOAD_FILE_DEV_FROM_THIS(a) CR (a, LOADFILE_DEVICE, LoadFile, LOADFILE_DEVICE_SIGNATURE)
+EFI_STATUS
+EFIAPI
+PxeBcDriverSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+PxeBcDriverStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+PxeBcDriverStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Controller,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+PxeBcComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+PxeBcComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
EFI_BIS_PROTOCOL *
PxebcBisStart (
PXE_BASECODE_DEVICE *Private,
diff --git a/EdkModulePkg/Universal/Network/PxeBc/Dxe/ComponentName.c b/EdkModulePkg/Universal/Network/PxeBc/Dxe/ComponentName.c index 2c11dc4556..4c6ebef07b 100644 --- a/EdkModulePkg/Universal/Network/PxeBc/Dxe/ComponentName.c +++ b/EdkModulePkg/Universal/Network/PxeBc/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "Bc.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-PxeBcComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-PxeBcComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gPxeBcComponentName = {
diff --git a/EdkModulePkg/Universal/Network/PxeBc/Dxe/bc.c b/EdkModulePkg/Universal/Network/PxeBc/Dxe/bc.c index f3969b90e8..44f7cf22c6 100644 --- a/EdkModulePkg/Universal/Network/PxeBc/Dxe/bc.c +++ b/EdkModulePkg/Universal/Network/PxeBc/Dxe/bc.c @@ -18,34 +18,6 @@ Abstract: #include "Bc.h"
//
-//
-//
-EFI_STATUS
-EFIAPI
-PxeBcDriverSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-PxeBcDriverStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-PxeBcDriverStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE Controller,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
-//
// helper routines
//
VOID
diff --git a/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/ComponentName.c b/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/ComponentName.c index b48b5d0b85..12cc0b06af 100644 --- a/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/ComponentName.c +++ b/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/ComponentName.c @@ -20,31 +20,6 @@ Abstract: #include "PxeDhcp4.h"
-/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
-
-//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-PxeDhcp4ComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-PxeDhcp4ComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
-
//
// EFI Component Name Protocol
//
diff --git a/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/PxeDhcp4.c b/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/PxeDhcp4.c index 7bdc78fb51..f0e87dba35 100644 --- a/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/PxeDhcp4.c +++ b/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/PxeDhcp4.c @@ -19,46 +19,6 @@ Abstract: #include "PxeDhcp4.h"
-/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
-
-//
-// Prototypes
-// Driver model protocol interface
-//
-EFI_STATUS
-EFIAPI
-PxeDhcp4DriverEntryPoint (
- IN EFI_HANDLE ImageHandle,
- IN EFI_SYSTEM_TABLE *SystemTable
- );
-
-EFI_STATUS
-EFIAPI
-PxeDhcp4DriverBindingSupported (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-PxeDhcp4DriverBindingStart (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
- );
-
-EFI_STATUS
-EFIAPI
-PxeDhcp4DriverBindingStop (
- IN EFI_DRIVER_BINDING_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN UINTN NumberOfChildren,
- IN EFI_HANDLE *ChildHandleBuffer
- );
-
-/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
-
//
// PXE DHCP Protocol Interface
//
diff --git a/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/PxeDhcp4.h b/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/PxeDhcp4.h index 136d392504..a49f169d15 100644 --- a/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/PxeDhcp4.h +++ b/EdkModulePkg/Universal/Network/PxeDhcp4/Dxe/PxeDhcp4.h @@ -161,6 +161,56 @@ PxeDhcp4Release ( )
;
+//
+// Prototypes
+// Driver model protocol interface
+//
+EFI_STATUS
+EFIAPI
+PxeDhcp4DriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+PxeDhcp4DriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ );
+
+EFI_STATUS
+EFIAPI
+PxeDhcp4DriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+PxeDhcp4ComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+PxeDhcp4ComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
//
diff --git a/EdkModulePkg/Universal/Network/Snp32_64/Dxe/ComponentName.c b/EdkModulePkg/Universal/Network/Snp32_64/Dxe/ComponentName.c index 3cc2d98440..7ccfcc102f 100644 --- a/EdkModulePkg/Universal/Network/Snp32_64/Dxe/ComponentName.c +++ b/EdkModulePkg/Universal/Network/Snp32_64/Dxe/ComponentName.c @@ -20,27 +20,6 @@ Abstract: #include "Snp.h"
//
-// EFI Component Name Functions
-//
-EFI_STATUS
-EFIAPI
-SimpleNetworkComponentNameGetDriverName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN CHAR8 *Language,
- OUT CHAR16 **DriverName
- );
-
-EFI_STATUS
-EFIAPI
-SimpleNetworkComponentNameGetControllerName (
- IN EFI_COMPONENT_NAME_PROTOCOL *This,
- IN EFI_HANDLE ControllerHandle,
- IN EFI_HANDLE ChildHandle OPTIONAL,
- IN CHAR8 *Language,
- OUT CHAR16 **ControllerName
- );
-
-//
// EFI Component Name Protocol
//
EFI_COMPONENT_NAME_PROTOCOL gSimpleNetworkComponentName = {
diff --git a/EdkModulePkg/Universal/Network/Snp32_64/Dxe/Snp.h b/EdkModulePkg/Universal/Network/Snp32_64/Dxe/Snp.h index 3055b8683a..31cbc8eb83 100644 --- a/EdkModulePkg/Universal/Network/Snp32_64/Dxe/Snp.h +++ b/EdkModulePkg/Universal/Network/Snp32_64/Dxe/Snp.h @@ -121,6 +121,29 @@ SNP_DRIVER; extern EFI_COMPONENT_NAME_PROTOCOL gSimpleNetworkComponentName;
extern EFI_DRIVER_BINDING_PROTOCOL gSimpleNetworkDriverBinding;
+extern EFI_PCI_IO_PROTOCOL *mPciIoFncs;
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+SimpleNetworkComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+SimpleNetworkComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
//
// Virtual to physical mapping for all UNDI 3.0s.
//
diff --git a/EdkModulePkg/Universal/Network/Snp32_64/Dxe/callback.c b/EdkModulePkg/Universal/Network/Snp32_64/Dxe/callback.c index 54574cb4ab..2a9c953f89 100644 --- a/EdkModulePkg/Universal/Network/Snp32_64/Dxe/callback.c +++ b/EdkModulePkg/Universal/Network/Snp32_64/Dxe/callback.c @@ -33,7 +33,6 @@ STATIC EFI_LOCK mLock; //
// End Global variables
//
-extern EFI_PCI_IO_PROTOCOL *mPciIoFncs;
VOID
snp_undi32_callback_v2p_30 (
diff --git a/EdkModulePkg/Universal/StatusCode/Dxe/Ipf/DxeStatusCodeIpf.c b/EdkModulePkg/Universal/StatusCode/Dxe/Ipf/DxeStatusCodeIpf.c index eee0c943f6..cbd7a61b1c 100644 --- a/EdkModulePkg/Universal/StatusCode/Dxe/Ipf/DxeStatusCodeIpf.c +++ b/EdkModulePkg/Universal/StatusCode/Dxe/Ipf/DxeStatusCodeIpf.c @@ -44,6 +44,7 @@ @return Always return EFI_SUCCESS.
**/
+STATIC
EFI_STATUS
EFIAPI
ReportDispatcher (
@@ -100,6 +101,7 @@ DXE_STATUS_CODE_CONTROLLER gDxeStatusCode = { @return Always return EFI_SUCCESS.
**/
+STATIC
EFI_STATUS
EFIAPI
ReportDispatcher (
diff --git a/EdkModulePkg/Universal/StatusCode/Pei/PeiStatusCode.c b/EdkModulePkg/Universal/StatusCode/Pei/PeiStatusCode.c index 0671201233..d47be70661 100644 --- a/EdkModulePkg/Universal/StatusCode/Pei/PeiStatusCode.c +++ b/EdkModulePkg/Universal/StatusCode/Pei/PeiStatusCode.c @@ -17,45 +17,6 @@ #include "PeiStatusCode.h"
-/**
- Report status code to all supported device.
-
-
- @param PeiServices
-
- @param Type Indicates the type of status code being reported.
- The type EFI_STATUS_CODE_TYPE is defined in "Related Definitions" below.
- @param Value Describes the current status of a hardware or software entity.
- This includes information about the class and subclass that is used to classify the entity
- as well as an operation. For progress codes, the operation is the current activity.
- For error codes, it is the exception. For debug codes, it is not defined at this time.
- Type EFI_STATUS_CODE_VALUE is defined in "Related Definitions" below.
- Specific values are discussed in the Intel? Platform Innovation Framework for EFI Status Code Specification.
- @param Instance The enumeration of a hardware or software entity within the system.
- A system may contain multiple entities that match a class/subclass pairing.
- The instance differentiates between them. An instance of 0 indicates that instance
- information is unavailable, not meaningful, or not relevant. Valid instance numbers start with 1.
- @param CallerId This optional parameter may be used to identify the caller.
- This parameter allows the status code driver to apply different rules to different callers.
- @param Data This optional parameter may be used to pass additional data.
- Type EFI_STATUS_CODE_DATA is defined in "Related Definitions" below.
- The contents of this data type may have additional GUID-specific data. The standard GUIDs and
- their associated data structures are defined in the Intel? Platform Innovation Framework for EFI Status Codes Specification.
-
- @return Always return EFI_SUCCESS.
-
-**/
-EFI_STATUS
-EFIAPI
-ReportDispatcher (
- IN EFI_PEI_SERVICES **PeiServices,
- IN EFI_STATUS_CODE_TYPE Type,
- IN EFI_STATUS_CODE_VALUE Value,
- IN UINT32 Instance,
- IN EFI_GUID *CallerId OPTIONAL,
- IN EFI_STATUS_CODE_DATA *Data OPTIONAL
- );
-
STATIC
EFI_PEI_PROGRESS_CODE_PPI mStatusCodePpi = {
ReportDispatcher
diff --git a/EdkModulePkg/Universal/StatusCode/Pei/PeiStatusCode.h b/EdkModulePkg/Universal/StatusCode/Pei/PeiStatusCode.h index 88ea9ce260..2a8e0dd5dc 100644 --- a/EdkModulePkg/Universal/StatusCode/Pei/PeiStatusCode.h +++ b/EdkModulePkg/Universal/StatusCode/Pei/PeiStatusCode.h @@ -97,4 +97,43 @@ MemoryStatusCodeReportWorker ( IN UINT32 Instance
);
+/**
+ Report status code to all supported device.
+
+
+ @param PeiServices
+
+ @param Type Indicates the type of status code being reported.
+ The type EFI_STATUS_CODE_TYPE is defined in "Related Definitions" below.
+ @param Value Describes the current status of a hardware or software entity.
+ This includes information about the class and subclass that is used to classify the entity
+ as well as an operation. For progress codes, the operation is the current activity.
+ For error codes, it is the exception. For debug codes, it is not defined at this time.
+ Type EFI_STATUS_CODE_VALUE is defined in "Related Definitions" below.
+ Specific values are discussed in the Intel? Platform Innovation Framework for EFI Status Code Specification.
+ @param Instance The enumeration of a hardware or software entity within the system.
+ A system may contain multiple entities that match a class/subclass pairing.
+ The instance differentiates between them. An instance of 0 indicates that instance
+ information is unavailable, not meaningful, or not relevant. Valid instance numbers start with 1.
+ @param CallerId This optional parameter may be used to identify the caller.
+ This parameter allows the status code driver to apply different rules to different callers.
+ @param Data This optional parameter may be used to pass additional data.
+ Type EFI_STATUS_CODE_DATA is defined in "Related Definitions" below.
+ The contents of this data type may have additional GUID-specific data. The standard GUIDs and
+ their associated data structures are defined in the Intel? Platform Innovation Framework for EFI Status Codes Specification.
+
+ @return Always return EFI_SUCCESS.
+
+**/
+EFI_STATUS
+EFIAPI
+ReportDispatcher (
+ IN EFI_PEI_SERVICES **PeiServices,
+ IN EFI_STATUS_CODE_TYPE Type,
+ IN EFI_STATUS_CODE_VALUE Value,
+ IN UINT32 Instance,
+ IN EFI_GUID *CallerId OPTIONAL,
+ IN EFI_STATUS_CODE_DATA *Data OPTIONAL
+ );
+
#endif
diff --git a/EdkModulePkg/Universal/UserInterface/SetupBrowser/Dxe/Setup.c b/EdkModulePkg/Universal/UserInterface/SetupBrowser/Dxe/Setup.c index 407f7694ba..8a873b3a5e 100644 --- a/EdkModulePkg/Universal/UserInterface/SetupBrowser/Dxe/Setup.c +++ b/EdkModulePkg/Universal/UserInterface/SetupBrowser/Dxe/Setup.c @@ -108,6 +108,7 @@ FUNCTIION_KEY_SETTING gFunctionKeySettingTable[] = { },
};
+STATIC
EFI_STATUS
InitializeBinaryStructures (
IN EFI_HII_HANDLE *Handle,
@@ -118,12 +119,14 @@ InitializeBinaryStructures ( EFI_FILE_FORM_TAGS **FileFormTagsHead
);
+STATIC
EFI_STATUS
InitializeTagStructures (
IN EFI_IFR_BINARY *BinaryData,
OUT EFI_FILE_FORM_TAGS *FileFormTags
);
+STATIC
UI_MENU_OPTION *
DisplayHomePage (
IN UINTN NumberOfIfrImages,
@@ -131,6 +134,7 @@ DisplayHomePage ( IN UINT8 *CallbackData
);
+STATIC
EFI_STATUS
GetIfrBinaryData (
IN EFI_HII_PROTOCOL *Hii,
@@ -139,6 +143,7 @@ GetIfrBinaryData ( IN EFI_IFR_BINARY *BinaryData
);
+STATIC
EFI_STATUS
InstallPrint (
VOID
@@ -759,6 +764,7 @@ Returns: return ;
}
+STATIC
EFI_STATUS
InitializeTagStructures (
IN EFI_IFR_BINARY *BinaryData,
@@ -1706,6 +1712,7 @@ PopulateHomePage ( return Status;
}
+STATIC
UI_MENU_OPTION *
DisplayHomePage (
IN UINTN NumberOfIfrImages,
@@ -1733,6 +1740,7 @@ DisplayHomePage ( return Selection;
}
+STATIC
EFI_STATUS
InitializeBinaryStructures (
IN EFI_HII_HANDLE *Handle,
@@ -2044,6 +2052,7 @@ InitializeBinaryStructures ( return Status;
}
+STATIC
EFI_STATUS
GetIfrBinaryData (
IN EFI_HII_PROTOCOL *Hii,
@@ -2204,6 +2213,7 @@ Returns: EFI_HANDLE PrintHandle = NULL;
EFI_PRINT_PROTOCOL mPrintProtocol = { UnicodeVSPrint };
+STATIC
EFI_STATUS
InstallPrint (
VOID
diff --git a/EdkModulePkg/Universal/Variable/RuntimeDxe/Ipf/InitVariable.c b/EdkModulePkg/Universal/Variable/RuntimeDxe/Ipf/InitVariable.c index da71705dae..b4b29cf7c6 100644 --- a/EdkModulePkg/Universal/Variable/RuntimeDxe/Ipf/InitVariable.c +++ b/EdkModulePkg/Universal/Variable/RuntimeDxe/Ipf/InitVariable.c @@ -24,7 +24,6 @@ Revision History //
// Don't use module globals after the SetVirtualAddress map is signaled
//
-extern ESAL_VARIABLE_GLOBAL *mVariableModuleGlobal;
STATIC
SAL_RETURN_REGS
diff --git a/EdkModulePkg/Universal/Variable/RuntimeDxe/Variable.h b/EdkModulePkg/Universal/Variable/RuntimeDxe/Variable.h index 014df50c3d..3d0264de78 100644 --- a/EdkModulePkg/Universal/Variable/RuntimeDxe/Variable.h +++ b/EdkModulePkg/Universal/Variable/RuntimeDxe/Variable.h @@ -75,6 +75,8 @@ typedef struct { UINT32 FvbInstance;
} ESAL_VARIABLE_GLOBAL;
+extern ESAL_VARIABLE_GLOBAL *mVariableModuleGlobal;
+
//
// Functions
//
|