+++ /dev/null
-/*++\r
-\r
-Copyright (c) 2004, Intel Corporation. All rights reserved.<BR>\r
-This program and the accompanying materials \r
-are licensed and made available under the terms and conditions of the BSD License \r
-which accompanies this distribution. The full text of the license may be found at \r
-http://opensource.org/licenses/bsd-license.php \r
- \r
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
-\r
-Module Name:\r
- \r
- EfiCombinationLib.h\r
-\r
-Abstract:\r
-\r
- Library functions that can be called in both PEI and DXE phase\r
-\r
---*/\r
-\r
-#ifndef _EFI_COMBINATION_LIB_H_\r
-#define _EFI_COMBINATION_LIB_H_\r
-\r
-EFI_STATUS\r
-EfiInitializeCommonDriverLib (\r
- IN EFI_HANDLE ImageHandle,\r
- IN VOID *SystemTable\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Initialize lib function calling phase: PEI or DXE\r
- \r
-Arguments:\r
-\r
- ImageHandle - The firmware allocated handle for the EFI image.\r
- \r
- SystemTable - A pointer to the EFI System Table.\r
-\r
-Returns: \r
-\r
- EFI_STATUS always returns EFI_SUCCESS\r
-\r
---*/\r
-;\r
-\r
-EFI_STATUS\r
-EfiCommonIoRead (\r
- IN UINT8 Width,\r
- IN UINTN Address,\r
- IN UINTN Count,\r
- IN OUT VOID *Buffer\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Io read operation.\r
-\r
-Arguments:\r
-\r
- Width - Width of read operation\r
- Address - Start IO address to read\r
- Count - Read count\r
- Buffer - Buffer to store result\r
-\r
-Returns:\r
-\r
- Status code\r
-\r
---*/\r
-;\r
-\r
-EFI_STATUS\r
-EfiCommonIoWrite (\r
- IN UINT8 Width,\r
- IN UINTN Address,\r
- IN UINTN Count,\r
- IN OUT VOID *Buffer\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Io write operation.\r
-\r
-Arguments:\r
-\r
- Width - Width of write operation\r
- Address - Start IO address to write\r
- Count - Write count\r
- Buffer - Buffer to write to the address\r
-\r
-Returns:\r
-\r
- Status code\r
-\r
---*/\r
-;\r
-\r
-EFI_STATUS\r
-EfiCommonPciRead (\r
- IN UINT8 Width,\r
- IN UINT64 Address,\r
- IN UINTN Count,\r
- IN OUT VOID *Buffer\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Pci read operation\r
-\r
-Arguments:\r
-\r
- Width - Width of PCI read\r
- Address - PCI address to read\r
- Count - Read count\r
- Buffer - Output buffer for the read\r
-\r
-Returns:\r
-\r
- Status code\r
-\r
---*/\r
-;\r
-\r
-EFI_STATUS\r
-EfiCommonPciWrite (\r
- IN UINT8 Width,\r
- IN UINT64 Address,\r
- IN UINTN Count,\r
- IN OUT VOID *Buffer\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Pci write operation\r
-\r
-Arguments:\r
-\r
- Width - Width of PCI write\r
- Address - PCI address to write\r
- Count - Write count\r
- Buffer - Buffer to write to the address\r
-\r
-Returns:\r
-\r
- Status code\r
-\r
---*/\r
-;\r
-\r
-EFI_STATUS\r
-EfiCommonStall (\r
- IN UINTN Microseconds\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Induces a fine-grained stall.\r
-\r
-Arguments:\r
-\r
- Microseconds - The number of microseconds to stall execution.\r
-\r
-Returns:\r
-\r
- Status code\r
-\r
---*/\r
-;\r
-\r
-EFI_STATUS\r
-EfiCommonCopyMem (\r
- IN VOID *Destination,\r
- IN VOID *Source,\r
- IN UINTN Length\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Copy Length bytes from Source to Destination.\r
-\r
-Arguments:\r
-\r
- Destination - Target of copy\r
-\r
- Source - Place to copy from\r
-\r
- Length - Number of bytes to copy\r
-\r
-Returns:\r
-\r
- Status code\r
-\r
---*/\r
-;\r
-\r
-EFI_STATUS\r
-EfiCommonAllocatePages (\r
- IN EFI_ALLOCATE_TYPE Type,\r
- IN EFI_MEMORY_TYPE MemoryType,\r
- IN UINTN Pages,\r
- IN OUT EFI_PHYSICAL_ADDRESS *Memory\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Allocates memory pages from the system.\r
-\r
-Arguments:\r
-\r
- Type - The type of allocation to perform.\r
- MemoryType - The type of memory to allocate.\r
- Pages - The number of contiguous pages to allocate.\r
- Memory - Pointer to a physical address.\r
-\r
-Returns:\r
-\r
- EFI_OUT_OF_RESOURCES - The pages could not be allocated.\r
- \r
- EFI_INVALID_PARAMETER - Invalid parameter\r
- \r
- EFI_NOT_FOUND - The requested pages could not be found.\r
- \r
- EFI_SUCCESS - The requested pages were allocated.\r
-\r
---*/\r
-;\r
-\r
-EFI_STATUS\r
-EfiCommonLocateInterface (\r
- IN EFI_GUID *Guid,\r
- OUT VOID **Interface\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Returns the first protocol instance that matches the given protocol.\r
-\r
-Arguments:\r
-\r
- Guid - Provides the protocol to search for.\r
- Interface - On return, a pointer to the first interface that matches Protocol\r
-\r
-Returns:\r
-\r
- Status code\r
-\r
---*/\r
-;\r
-\r
-EFI_STATUS\r
-EfiCommonReportStatusCode (\r
- IN EFI_STATUS_CODE_TYPE CodeType,\r
- IN EFI_STATUS_CODE_VALUE Value,\r
- IN UINT32 Instance,\r
- IN EFI_GUID * CallerId,\r
- IN EFI_STATUS_CODE_DATA * Data OPTIONAL\r
- )\r
-/*++\r
-\r
-Routine Description:\r
-\r
- Status Code reporter\r
-\r
-Arguments:\r
- \r
- CodeType - Type of Status Code.\r
- \r
- Value - Value to output for Status Code.\r
- \r
- Instance - Instance Number of this status code.\r
- \r
- CallerId - ID of the caller of this status code.\r
- \r
- Data - Optional data associated with this status code.\r
-\r
-Returns:\r
-\r
- Status code\r
- \r
---*/\r
-;\r
-\r
-#endif\r