git: 3a05fa14f9a6 - main - loader/efi: strip trailing whitespace
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 11 Apr 2025 22:04:59 UTC
The branch main has been updated by imp:
URL: https://cgit.FreeBSD.org/src/commit/?id=3a05fa14f9a62370edc26260a4cfabb8a0c5041c
commit 3a05fa14f9a62370edc26260a4cfabb8a0c5041c
Author: Warner Losh <imp@FreeBSD.org>
AuthorDate: 2025-04-11 22:02:58 +0000
Commit: Warner Losh <imp@FreeBSD.org>
CommitDate: 2025-04-11 22:02:58 +0000
loader/efi: strip trailing whitespace
Many of these no-doubt are in upstream, but they are interfering with
the filters I use to judge commits (no traling whitespace). We don't
directly get stuff from upstream. If/when we pull this from contrib
we'll revisit.
Sponsored by: Netflix
---
stand/efi/include/amd64/efibind.h | 22 ++--
stand/efi/include/amd64/pe.h | 6 +-
stand/efi/include/arm64/efibind.h | 18 +--
stand/efi/include/efi_nii.h | 2 +-
stand/efi/include/efidebug.h | 12 +-
stand/efi/include/efidef.h | 10 +-
stand/efi/include/efidevp.h | 14 +--
stand/efi/include/efifs.h | 2 +-
stand/efi/include/efinet.h | 52 ++++----
stand/efi/include/efipart.h | 6 +-
stand/efi/include/efipciio.h | 259 +++++++++++++++++++-------------------
stand/efi/include/efiprot.h | 10 +-
stand/efi/include/efipxebc.h | 6 +-
stand/efi/include/efirng.h | 4 +-
stand/efi/include/efiser.h | 6 +-
stand/efi/include/efiuga.h | 34 ++---
stand/efi/include/i386/efibind.h | 22 ++--
stand/efi/include/i386/pe.h | 14 +--
stand/efi/include/riscv/efibind.h | 18 +--
19 files changed, 258 insertions(+), 259 deletions(-)
diff --git a/stand/efi/include/amd64/efibind.h b/stand/efi/include/amd64/efibind.h
index d005ade221c4..1c974ee39f84 100644
--- a/stand/efi/include/amd64/efibind.h
+++ b/stand/efi/include/amd64/efibind.h
@@ -28,17 +28,17 @@ Revision History
#ifdef EFI_NT_EMULATOR
#define POST_CODE(_Data)
-#else
+#else
#ifdef EFI_DEBUG
#define POST_CODE(_Data) __asm mov eax,(_Data) __asm out 0x80,al
#else
#define POST_CODE(_Data)
- #endif
+ #endif
#endif
#define EFIERR(a) (0x8000000000000000 | a)
#define EFI_ERROR_MASK 0x8000000000000000
-#define EFIERR_OEM(a) (0xc000000000000000 | a)
+#define EFIERR_OEM(a) (0xc000000000000000 | a)
#define BAD_POINTER 0xFBFBFBFBFBFBFBFB
@@ -72,18 +72,18 @@ Revision History
// BOOTSERVICE - prototype for implementation of a boot service interface
// RUNTIMESERVICE - prototype for implementation of a runtime service interface
// RUNTIMEFUNCTION - prototype for implementation of a runtime function that is not a service
-// RUNTIME_CODE - pragma macro for declaring runtime code
+// RUNTIME_CODE - pragma macro for declaring runtime code
//
#ifdef __amd64__
#define EFIAPI __attribute__((ms_abi))
#endif
-#ifndef EFIAPI // Forces EFI calling conventions reguardless of compiler options
+#ifndef EFIAPI // Forces EFI calling conventions reguardless of compiler options
#ifdef _MSC_EXTENSIONS
- #define EFIAPI __cdecl // Force C calling convention for Microsoft C compiler
+ #define EFIAPI __cdecl // Force C calling convention for Microsoft C compiler
#else
- #define EFIAPI // Substitute expresion to force C calling convention
+ #define EFIAPI // Substitute expresion to force C calling convention
#endif
#endif
@@ -100,7 +100,7 @@ Revision History
#define VOLATILE volatile
-#define MEMORY_FENCE()
+#define MEMORY_FENCE()
#ifdef EFI_NO_INTERFACE_DECL
#define EFI_FORWARD_DECLARATION(x)
@@ -149,9 +149,9 @@ Revision History
#define LOAD_INTERNAL_DRIVER(_if, type, name, entry) \
- (_if)->LoadInternal(type, name, NULL)
+ (_if)->LoadInternal(type, name, NULL)
-#else // EFI_NT_EMULATOR
+#else // EFI_NT_EMULATOR
//
// When building similar to FW, link everything together as
@@ -163,7 +163,7 @@ Revision History
#define LOAD_INTERNAL_DRIVER(_if, type, name, entry) \
(_if)->LoadInternal(type, name, entry)
-#endif // EFI_FW_NT
+#endif // EFI_FW_NT
#ifdef __FreeBSD__
#define INTERFACE_DECL(x) struct x
diff --git a/stand/efi/include/amd64/pe.h b/stand/efi/include/amd64/pe.h
index ad5985cc2740..b858ba916c7d 100644
--- a/stand/efi/include/amd64/pe.h
+++ b/stand/efi/include/amd64/pe.h
@@ -1,4 +1,4 @@
-/*
+/*
PE32+ header file
*/
#ifndef _PE_H
@@ -7,7 +7,7 @@
#define IMAGE_DOS_SIGNATURE 0x5A4D // MZ
#define IMAGE_OS2_SIGNATURE 0x454E // NE
#define IMAGE_OS2_SIGNATURE_LE 0x454C // LE
-#define IMAGE_NT_SIGNATURE 0x00004550 // PE00
+#define IMAGE_NT_SIGNATURE 0x00004550 // PE00
#define IMAGE_EDOS_SIGNATURE 0x44454550 // PEED
@@ -129,7 +129,7 @@ typedef struct _IMAGE_OPTIONAL_HEADER {
UINT32 AddressOfEntryPoint;
UINT32 BaseOfCode;
UINT32 BaseOfData;
-
+
//
// NT additional fields.
//
diff --git a/stand/efi/include/arm64/efibind.h b/stand/efi/include/arm64/efibind.h
index 417da1b4d4ff..c81506f79334 100644
--- a/stand/efi/include/arm64/efibind.h
+++ b/stand/efi/include/arm64/efibind.h
@@ -31,10 +31,10 @@ Revision History
//
#define BIT63 0x8000000000000000
-#define PLATFORM_IOBASE_ADDRESS (0xffffc000000 | BIT63)
+#define PLATFORM_IOBASE_ADDRESS (0xffffc000000 | BIT63)
#define PORT_TO_MEMD(_Port) (PLATFORM_IOBASE_ADDRESS | ( ( ( (_Port) & 0xfffc) << 10 ) | ( (_Port) & 0x0fff) ) )
-
-//
+
+//
// Macro's with casts make this much easier to use and read.
//
#define PORT_TO_MEM8D(_Port) (*(UINT8 *)(PORT_TO_MEMD(_Port)))
@@ -45,7 +45,7 @@ Revision History
#define EFIERR(a) (0x8000000000000000 | a)
#define EFI_ERROR_MASK 0x8000000000000000
-#define EFIERR_OEM(a) (0xc000000000000000 | a)
+#define EFIERR_OEM(a) (0xc000000000000000 | a)
#define BAD_POINTER 0xFBFBFBFBFBFBFBFB
#define MAX_ADDRESS 0xFFFFFFFFFFFFFFFF
@@ -77,14 +77,14 @@ Revision History
// BOOTSERVICE - prototype for implementation of a boot service interface
// RUNTIMESERVICE - prototype for implementation of a runtime service interface
// RUNTIMEFUNCTION - prototype for implementation of a runtime function that is not a service
-// RUNTIME_CODE - pragma macro for declaring runtime code
+// RUNTIME_CODE - pragma macro for declaring runtime code
//
-#ifndef EFIAPI // Forces EFI calling conventions reguardless of compiler options
+#ifndef EFIAPI // Forces EFI calling conventions reguardless of compiler options
#ifdef _MSC_EXTENSIONS
- #define EFIAPI __cdecl // Force C calling convention for Microsoft C compiler
+ #define EFIAPI __cdecl // Force C calling convention for Microsoft C compiler
#else
- #define EFIAPI // Substitute expresion to force C calling convention
+ #define EFIAPI // Substitute expresion to force C calling convention
#endif
#endif
@@ -101,7 +101,7 @@ Revision History
//
// BugBug: Need to find out if this is portable across compilers.
//
-void __mfa (void);
+void __mfa (void);
#define MEMORY_FENCE() __mfa()
#ifdef EFI_NO_INTERFACE_DECL
diff --git a/stand/efi/include/efi_nii.h b/stand/efi/include/efi_nii.h
index 069e318428ea..173108c55004 100644
--- a/stand/efi/include/efi_nii.h
+++ b/stand/efi/include/efi_nii.h
@@ -20,7 +20,7 @@ Revision history:
2000-Feb-18 M(f)J GUID updated.
Structure order changed for machine word alignment.
Added StringId[4] to structure.
-
+
2000-Feb-14 M(f)J Genesis.
--*/
diff --git a/stand/efi/include/efidebug.h b/stand/efi/include/efidebug.h
index b43b62d1283c..40a3cd0d5bb2 100644
--- a/stand/efi/include/efidebug.h
+++ b/stand/efi/include/efidebug.h
@@ -32,12 +32,12 @@ extern UINTN EFIDebug;
#define DBGASSERT(a) DbgAssert(__FILE__, __LINE__, #a)
#define DEBUG(a) DbgPrint a
-
+
#else
#define DBGASSERT(a)
#define DEBUG(a)
-
+
#endif
#if EFI_DEBUG_CLEAR_MEMORY
@@ -59,7 +59,7 @@ extern UINTN EFIDebug;
#define D_INFO 0x00000040 // Verbose
#define D_VARIABLE 0x00000100 // Variable
#define D_VAR 0x00000100 // Variable
-#define D_BM 0x00000400 // Boot Manager
+#define D_BM 0x00000400 // Boot Manager
#define D_BLKIO 0x00001000 // BlkIo Driver
#define D_BLKIO_ULTRA 0x00002000 // BlkIo Driver
#define D_NET 0x00004000 // SNI Driver
@@ -90,9 +90,9 @@ extern UINTN EFIDebug;
#else
- #define ASSERT(a)
- #define ASSERT_LOCKED(l)
- #define ASSERT_STRUCT(p,t)
+ #define ASSERT(a)
+ #define ASSERT_LOCKED(l)
+ #define ASSERT_STRUCT(p,t)
#endif
diff --git a/stand/efi/include/efidef.h b/stand/efi/include/efidef.h
index 54be3bb2a0ce..7a63fd185874 100644
--- a/stand/efi/include/efidef.h
+++ b/stand/efi/include/efidef.h
@@ -70,11 +70,11 @@ typedef VOID *EFI_EVENT;
// A GUID
//
-typedef struct {
+typedef struct {
UINT32 Data1;
UINT16 Data2;
UINT16 Data3;
- UINT8 Data4[8];
+ UINT8 Data4[8];
} EFI_GUID;
@@ -82,7 +82,7 @@ typedef struct {
// Time
//
-typedef struct {
+typedef struct {
UINT16 Year; // 1998 - 20XX
UINT8 Month; // 1 - 12
UINT8 Day; // 1 - 31
@@ -179,9 +179,9 @@ typedef enum {
#define EFI_MEMORY_WC 0x0000000000000002
#define EFI_MEMORY_WT 0x0000000000000004
#define EFI_MEMORY_WB 0x0000000000000008
-#define EFI_MEMORY_UCE 0x0000000000000010
+#define EFI_MEMORY_UCE 0x0000000000000010
-// physical memory protection on range
+// physical memory protection on range
#define EFI_MEMORY_WP 0x0000000000001000
#define EFI_MEMORY_RP 0x0000000000002000
#define EFI_MEMORY_XP 0x0000000000004000
diff --git a/stand/efi/include/efidevp.h b/stand/efi/include/efidevp.h
index 409f2b23b9ef..5fe42a3e7e8f 100644
--- a/stand/efi/include/efidevp.h
+++ b/stand/efi/include/efidevp.h
@@ -150,8 +150,8 @@ typedef struct _ACPI_EXTENDED_HID_DEVICE_PATH {
// bits[31:16] - binary number
// Compressed ASCII is 5 bits per character 0b00001 = 'A' 0b11010 = 'Z'
//
-#define PNP_EISA_ID_CONST 0x41d0
-#define EISA_ID(_Name, _Num) ((UINT32) ((_Name) | (_Num) << 16))
+#define PNP_EISA_ID_CONST 0x41d0
+#define EISA_ID(_Name, _Num) ((UINT32) ((_Name) | (_Num) << 16))
#define EISA_PNP_ID(_PNPId) (EISA_ID(PNP_EISA_ID_CONST, (_PNPId)))
#define EFI_PNP_ID(_PNPId) (EISA_ID(PNP_EISA_ID_CONST, (_PNPId)))
@@ -160,7 +160,7 @@ typedef struct _ACPI_EXTENDED_HID_DEVICE_PATH {
/*
*
*/
-#define MESSAGING_DEVICE_PATH 0x03
+#define MESSAGING_DEVICE_PATH 0x03
#define MSG_ATAPI_DP 0x01
typedef struct _ATAPI_DEVICE_PATH {
@@ -174,7 +174,7 @@ typedef struct _ATAPI_DEVICE_PATH {
typedef struct _SCSI_DEVICE_PATH {
EFI_DEVICE_PATH Header;
UINT16 Pun;
- UINT16 Lun;
+ UINT16 Lun;
} SCSI_DEVICE_PATH;
#define MSG_FIBRECHANNEL_DP 0x03
@@ -283,7 +283,7 @@ typedef struct _UART_DEVICE_PATH {
#define DEVICE_PATH_MESSAGING_VT_100_PLUS \
{ 0x7baec70b, 0x57e0, 0x4c76, {0x8e, 0x87, 0x2f, 0x9e, 0x28, 0x08, 0x83, 0x43} }
-
+
#define DEVICE_PATH_MESSAGING_VT_UTF8 \
{ 0xad15a0d6, 0x8bec, 0x4acf, {0xa0, 0x73, 0xd0, 0x1d, 0xe7, 0x7e, 0x2d, 0x88} }
@@ -393,7 +393,7 @@ typedef union {
PCCARD_DEVICE_PATH PcCard;
MEMMAP_DEVICE_PATH MemMap;
VENDOR_DEVICE_PATH Vendor;
- UNKNOWN_DEVICE_VENDOR_DEVICE_PATH UnknownVendor;
+ UNKNOWN_DEVICE_VENDOR_DEVICE_PATH UnknownVendor;
CONTROLLER_DEVICE_PATH Controller;
ACPI_HID_DEVICE_PATH Acpi;
@@ -427,7 +427,7 @@ typedef union {
PCCARD_DEVICE_PATH *PcCard;
MEMMAP_DEVICE_PATH *MemMap;
VENDOR_DEVICE_PATH *Vendor;
- UNKNOWN_DEVICE_VENDOR_DEVICE_PATH *UnknownVendor;
+ UNKNOWN_DEVICE_VENDOR_DEVICE_PATH *UnknownVendor;
CONTROLLER_DEVICE_PATH *Controller;
ACPI_HID_DEVICE_PATH *Acpi;
ACPI_EXTENDED_HID_DEVICE_PATH *ExtendedAcpi;
diff --git a/stand/efi/include/efifs.h b/stand/efi/include/efifs.h
index 3ba238496b23..0197449a9399 100644
--- a/stand/efi/include/efifs.h
+++ b/stand/efi/include/efifs.h
@@ -100,7 +100,7 @@ typedef struct _EFI_LBAL {
UINT32 ArrayCount;
} EFI_LBAL;
-// Array size
+// Array size
#define EFI_LBAL_ARRAY_SIZE(lbal,offs,blks) \
(((blks) - (offs) - (lbal)->Hdr.HeaderSize) / sizeof(EFI_RL))
diff --git a/stand/efi/include/efinet.h b/stand/efi/include/efinet.h
index 9cd13f5a4653..d8bcf9a36bcb 100644
--- a/stand/efi/include/efinet.h
+++ b/stand/efi/include/efinet.h
@@ -172,8 +172,8 @@ typedef struct {
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_START) (
IN struct _EFI_SIMPLE_NETWORK *This
);
@@ -181,8 +181,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_STOP) (
IN struct _EFI_SIMPLE_NETWORK *This
);
@@ -190,8 +190,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_INITIALIZE) (
IN struct _EFI_SIMPLE_NETWORK *This,
IN UINTN ExtraRxBufferSize OPTIONAL,
@@ -201,8 +201,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_RESET) (
IN struct _EFI_SIMPLE_NETWORK *This,
IN BOOLEAN ExtendedVerification
@@ -211,8 +211,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_SHUTDOWN) (
IN struct _EFI_SIMPLE_NETWORK *This
);
@@ -220,8 +220,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_RECEIVE_FILTERS) (
IN struct _EFI_SIMPLE_NETWORK *This,
IN UINT32 Enable,
@@ -234,8 +234,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_STATION_ADDRESS) (
IN struct _EFI_SIMPLE_NETWORK *This,
IN BOOLEAN Reset,
@@ -245,8 +245,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_STATISTICS) (
IN struct _EFI_SIMPLE_NETWORK *This,
IN BOOLEAN Reset,
@@ -257,8 +257,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_MCAST_IP_TO_MAC) (
IN struct _EFI_SIMPLE_NETWORK *This,
IN BOOLEAN IPv6,
@@ -269,8 +269,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_NVDATA) (
IN struct _EFI_SIMPLE_NETWORK *This,
IN BOOLEAN ReadWrite,
@@ -282,8 +282,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_GET_STATUS) (
IN struct _EFI_SIMPLE_NETWORK *This,
OUT UINT32 *InterruptStatus OPTIONAL,
@@ -293,8 +293,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_TRANSMIT) (
IN struct _EFI_SIMPLE_NETWORK *This,
IN UINTN HeaderSize,
@@ -308,8 +308,8 @@ EFI_STATUS
///////////////////////////////////////////////////////////////////////////////
//
-typedef
-EFI_STATUS
+typedef
+EFI_STATUS
(EFIAPI *EFI_SIMPLE_NETWORK_RECEIVE) (
IN struct _EFI_SIMPLE_NETWORK *This,
OUT UINTN *HeaderSize OPTIONAL,
diff --git a/stand/efi/include/efipart.h b/stand/efi/include/efipart.h
index 32a715c8781b..abad72440657 100644
--- a/stand/efi/include/efipart.h
+++ b/stand/efi/include/efipart.h
@@ -15,8 +15,8 @@ Intel Corporation.
Module Name:
efipart.h
-
-Abstract:
+
+Abstract:
Info about disk partitions and Master Boot Records
@@ -54,7 +54,7 @@ typedef struct {
#define MIN_MBR_DEVICE_SIZE 0x80000
#define MBR_ERRATA_PAD 0x40000 // 128 MB
-#define MAX_MBR_PARTITIONS 4
+#define MAX_MBR_PARTITIONS 4
typedef struct {
UINT8 BootStrapCode[440];
UINT8 UniqueMbrSignature[4];
diff --git a/stand/efi/include/efipciio.h b/stand/efi/include/efipciio.h
index 4e9ca153f721..8499ad9e9d7a 100644
--- a/stand/efi/include/efipciio.h
+++ b/stand/efi/include/efipciio.h
@@ -1,15 +1,15 @@
/** @file
- EFI PCI I/O Protocol provides the basic Memory, I/O, PCI configuration,
+ EFI PCI I/O Protocol provides the basic Memory, I/O, PCI configuration,
and DMA interfaces that a driver uses to access its PCI controller.
Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
+ 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.
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
@@ -127,27 +127,27 @@ typedef enum {
EfiPciIoAttributeOperationMaximum
} EFI_PCI_IO_PROTOCOL_ATTRIBUTE_OPERATION;
-/**
+/**
Reads from the memory space of a PCI controller. Returns either when the polling exit criteria is
- satisfied or after a defined duration.
-
+ satisfied or after a defined duration.
+
@param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
@param Width Signifies the width of the memory or I/O operations.
@param BarIndex The BAR index of the standard PCI Configuration header to use as the
- base address for the memory operation to perform.
+ base address for the memory operation to perform.
@param Offset The offset within the selected BAR to start the memory operation.
@param Mask Mask used for the polling criteria.
@param Value The comparison value used for the polling exit criteria.
@param Delay The number of 100 ns units to poll.
@param Result Pointer to the last value read from the memory location.
-
+
@retval EFI_SUCCESS The last data returned from the access matched the poll exit criteria.
@retval EFI_UNSUPPORTED BarIndex not valid for this PCI controller.
@retval EFI_UNSUPPORTED Offset is not valid for the BarIndex of this PCI controller.
@retval EFI_TIMEOUT Delay expired before a match occurred.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
-
+
**/
typedef
EFI_STATUS
@@ -162,25 +162,25 @@ EFI_STATUS
OUT UINT64 *Result
);
-/**
+/**
Enable a PCI driver to access PCI controller registers in the PCI memory or I/O space.
-
+
@param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
@param Width Signifies the width of the memory or I/O operations.
@param BarIndex The BAR index of the standard PCI Configuration header to use as the
- base address for the memory or I/O operation to perform.
- @param Offset The offset within the selected BAR to start the memory or I/O operation.
+ base address for the memory or I/O operation to perform.
+ @param Offset The offset within the selected BAR to start the memory or I/O operation.
@param Count The number of memory or I/O operations to perform.
@param Buffer For read operations, the destination buffer to store the results. For write
- operations, the source buffer to write data from.
-
+ operations, the source buffer to write data from.
+
@retval EFI_SUCCESS The data was read from or written to the PCI controller.
@retval EFI_UNSUPPORTED BarIndex not valid for this PCI controller.
@retval EFI_UNSUPPORTED The address range specified by Offset, Width, and Count is not
- valid for the PCI BAR specified by BarIndex.
+ valid for the PCI BAR specified by BarIndex.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
-
+
**/
typedef
EFI_STATUS
@@ -204,23 +204,22 @@ typedef struct {
EFI_PCI_IO_PROTOCOL_IO_MEM Write;
} EFI_PCI_IO_PROTOCOL_ACCESS;
-/**
+/**
Enable a PCI driver to access PCI controller registers in PCI configuration space.
-
- @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
+
+ @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
@param Width Signifies the width of the memory operations.
@param Offset The offset within the PCI configuration space for the PCI controller.
@param Count The number of PCI configuration operations to perform.
@param Buffer For read operations, the destination buffer to store the results. For write
operations, the source buffer to write data from.
-
-
+
@retval EFI_SUCCESS The data was read from or written to the PCI controller.
@retval EFI_UNSUPPORTED The address range specified by Offset, Width, and Count is not
valid for the PCI configuration header of the PCI controller.
- @retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
- @retval EFI_INVALID_PARAMETER Buffer is NULL or Width is invalid.
-
+ @retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
+ @retval EFI_INVALID_PARAMETER Buffer is NULL or Width is invalid.
+
**/
typedef
EFI_STATUS
@@ -243,33 +242,33 @@ typedef struct {
EFI_PCI_IO_PROTOCOL_CONFIG Write;
} EFI_PCI_IO_PROTOCOL_CONFIG_ACCESS;
-/**
+/**
Enables a PCI driver to copy one region of PCI memory space to another region of PCI
memory space.
-
+
@param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
@param Width Signifies the width of the memory operations.
@param DestBarIndex The BAR index in the standard PCI Configuration header to use as the
- base address for the memory operation to perform.
+ base address for the memory operation to perform.
@param DestOffset The destination offset within the BAR specified by DestBarIndex to
- start the memory writes for the copy operation.
+ start the memory writes for the copy operation.
@param SrcBarIndex The BAR index in the standard PCI Configuration header to use as the
- base address for the memory operation to perform.
+ base address for the memory operation to perform.
@param SrcOffset The source offset within the BAR specified by SrcBarIndex to start
- the memory reads for the copy operation.
+ the memory reads for the copy operation.
@param Count The number of memory operations to perform. Bytes moved is Width
- size * Count, starting at DestOffset and SrcOffset.
-
+ size * Count, starting at DestOffset and SrcOffset.
+
@retval EFI_SUCCESS The data was copied from one memory region to another memory region.
@retval EFI_UNSUPPORTED DestBarIndex not valid for this PCI controller.
@retval EFI_UNSUPPORTED SrcBarIndex not valid for this PCI controller.
@retval EFI_UNSUPPORTED The address range specified by DestOffset, Width, and Count
- is not valid for the PCI BAR specified by DestBarIndex.
+ is not valid for the PCI BAR specified by DestBarIndex.
@retval EFI_UNSUPPORTED The address range specified by SrcOffset, Width, and Count is
- not valid for the PCI BAR specified by SrcBarIndex.
+ not valid for the PCI BAR specified by SrcBarIndex.
@retval EFI_INVALID_PARAMETER Width is invalid.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
-
+
**/
typedef
EFI_STATUS
@@ -283,24 +282,24 @@ EFI_STATUS
IN UINTN Count
);
-/**
+/**
Provides the PCI controller-specific addresses needed to access system memory.
-
+
@param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
@param Operation Indicates if the bus master is going to read or write to system memory.
@param HostAddress The system memory address to map to the PCI controller.
@param NumberOfBytes On input the number of bytes to map. On output the number of bytes
- that were mapped.
+ that were mapped.
@param DeviceAddress The resulting map address for the bus master PCI controller to use to
- access the hosts HostAddress.
+ access the hosts HostAddress.
@param Mapping A resulting value to pass to Unmap().
-
+
@retval EFI_SUCCESS The range was mapped for the returned NumberOfBytes.
- @retval EFI_UNSUPPORTED The HostAddress cannot be mapped as a common buffer.
+ @retval EFI_UNSUPPORTED The HostAddress cannot be mapped as a common buffer.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
@retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
@retval EFI_DEVICE_ERROR The system hardware could not map the requested address.
-
+
**/
typedef
EFI_STATUS
@@ -313,15 +312,15 @@ EFI_STATUS
OUT VOID **Mapping
);
-/**
+/**
Completes the Map() operation and releases any corresponding resources.
-
- @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
+
+ @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
@param Mapping The mapping value returned from Map().
-
+
@retval EFI_SUCCESS The range was unmapped.
@retval EFI_DEVICE_ERROR The data was not committed to the target system memory.
-
+
**/
typedef
EFI_STATUS
@@ -330,25 +329,25 @@ EFI_STATUS
IN VOID *Mapping
);
-/**
+/**
Allocates pages that are suitable for an EfiPciIoOperationBusMasterCommonBuffer
- mapping.
-
+ mapping.
+
@param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
@param Type This parameter is not used and must be ignored.
@param MemoryType The type of memory to allocate, EfiBootServicesData or
- EfiRuntimeServicesData.
- @param Pages The number of pages to allocate.
+ EfiRuntimeServicesData.
+ @param Pages The number of pages to allocate.
@param HostAddress A pointer to store the base system memory address of the
- allocated range.
+ allocated range.
@param Attributes The requested bit mask of attributes for the allocated range.
-
+
@retval EFI_SUCCESS The requested memory pages were allocated.
@retval EFI_UNSUPPORTED Attributes is unsupported. The only legal attribute bits are
- MEMORY_WRITE_COMBINE and MEMORY_CACHED.
+ MEMORY_WRITE_COMBINE and MEMORY_CACHED.
@retval EFI_INVALID_PARAMETER One or more parameters are invalid.
- @retval EFI_OUT_OF_RESOURCES The memory pages could not be allocated.
-
+ @retval EFI_OUT_OF_RESOURCES The memory pages could not be allocated.
+
**/
typedef
EFI_STATUS
@@ -361,17 +360,17 @@ EFI_STATUS
IN UINT64 Attributes
);
-/**
+/**
Frees memory that was allocated with AllocateBuffer().
-
- @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
- @param Pages The number of pages to free.
- @param HostAddress The base system memory address of the allocated range.
-
+
+ @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
+ @param Pages The number of pages to free.
+ @param HostAddress The base system memory address of the allocated range.
+
@retval EFI_SUCCESS The requested memory pages were freed.
@retval EFI_INVALID_PARAMETER The memory range specified by HostAddress and Pages
was not allocated with AllocateBuffer().
-
+
**/
typedef
EFI_STATUS
@@ -381,16 +380,16 @@ EFI_STATUS
IN VOID *HostAddress
);
-/**
+/**
Flushes all PCI posted write transactions from a PCI host bridge to system memory.
-
- @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
-
+
+ @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
+
@retval EFI_SUCCESS The PCI posted write transactions were flushed from the PCI host
- bridge to system memory.
+ bridge to system memory.
@retval EFI_DEVICE_ERROR The PCI posted write transactions were not flushed from the PCI
- host bridge due to a hardware error.
-
+ host bridge due to a hardware error.
+
**/
typedef
EFI_STATUS
@@ -398,18 +397,18 @@ EFI_STATUS
IN EFI_PCI_IO_PROTOCOL *This
);
-/**
+/**
Retrieves this PCI controller's current PCI bus number, device number, and function number.
-
- @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
+
+ @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
@param SegmentNumber The PCI controller's current PCI segment number.
@param BusNumber The PCI controller's current PCI bus number.
@param DeviceNumber The PCI controller's current PCI device number.
@param FunctionNumber The PCI controller's current PCI function number.
-
- @retval EFI_SUCCESS The PCI controller location was returned.
- @retval EFI_INVALID_PARAMETER One or more parameters are invalid.
-
+
+ @retval EFI_SUCCESS The PCI controller location was returned.
+ @retval EFI_INVALID_PARAMETER One or more parameters are invalid.
+
**/
typedef
EFI_STATUS
@@ -421,24 +420,24 @@ EFI_STATUS
OUT UINTN *FunctionNumber
);
-/**
+/**
Performs an operation on the attributes that this PCI controller supports. The operations include
- getting the set of supported attributes, retrieving the current attributes, setting the current
- attributes, enabling attributes, and disabling attributes.
-
- @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
+ getting the set of supported attributes, retrieving the current attributes, setting the current
+ attributes, enabling attributes, and disabling attributes.
+
+ @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
@param Operation The operation to perform on the attributes for this PCI controller.
@param Attributes The mask of attributes that are used for Set, Enable, and Disable
- operations.
+ operations.
@param Result A pointer to the result mask of attributes that are returned for the Get
- and Supported operations.
-
+ and Supported operations.
+
@retval EFI_SUCCESS The operation on the PCI controller's attributes was completed.
- @retval EFI_INVALID_PARAMETER One or more parameters are invalid.
- @retval EFI_UNSUPPORTED one or more of the bits set in
+ @retval EFI_INVALID_PARAMETER One or more parameters are invalid.
+ @retval EFI_UNSUPPORTED one or more of the bits set in
Attributes are not supported by this PCI controller or one of
its parent bridges when Operation is Set, Enable or Disable.
-
+
**/
typedef
EFI_STATUS
@@ -449,27 +448,27 @@ EFI_STATUS
OUT UINT64 *Result OPTIONAL
);
-/**
+/**
Gets the attributes that this PCI controller supports setting on a BAR using
SetBarAttributes(), and retrieves the list of resource descriptors for a BAR.
-
- @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
+
+ @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
@param BarIndex The BAR index of the standard PCI Configuration header to use as the
base address for resource range. The legal range for this field is 0..5.
@param Supports A pointer to the mask of attributes that this PCI controller supports
- setting for this BAR with SetBarAttributes().
+ setting for this BAR with SetBarAttributes().
@param Resources A pointer to the ACPI 2.0 resource descriptors that describe the current
- configuration of this BAR of the PCI controller.
-
- @retval EFI_SUCCESS If Supports is not NULL, then the attributes that the PCI
- controller supports are returned in Supports. If Resources
+ configuration of this BAR of the PCI controller.
+
+ @retval EFI_SUCCESS If Supports is not NULL, then the attributes that the PCI
+ controller supports are returned in Supports. If Resources
is not NULL, then the ACPI 2.0 resource descriptors that the PCI
- controller is currently using are returned in Resources.
+ controller is currently using are returned in Resources.
@retval EFI_INVALID_PARAMETER Both Supports and Attributes are NULL.
@retval EFI_UNSUPPORTED BarIndex not valid for this PCI controller.
@retval EFI_OUT_OF_RESOURCES There are not enough resources available to allocate
- Resources.
-
+ Resources.
+
**/
typedef
EFI_STATUS
@@ -480,29 +479,29 @@ EFI_STATUS
OUT VOID **Resources OPTIONAL
);
-/**
+/**
Sets the attributes for a range of a BAR on a PCI controller.
-
- @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
+
+ @param This A pointer to the EFI_PCI_IO_PROTOCOL instance.
@param Attributes The mask of attributes to set for the resource range specified by
- BarIndex, Offset, and Length.
+ BarIndex, Offset, and Length.
@param BarIndex The BAR index of the standard PCI Configuration header to use as the
base address for resource range. The legal range for this field is 0..5.
@param Offset A pointer to the BAR relative base address of the resource range to be
- modified by the attributes specified by Attributes.
+ modified by the attributes specified by Attributes.
@param Length A pointer to the length of the resource range to be modified by the
- attributes specified by Attributes.
-
- @retval EFI_SUCCESS The set of attributes specified by Attributes for the resource
- range specified by BarIndex, Offset, and Length were
+ attributes specified by Attributes.
+
+ @retval EFI_SUCCESS The set of attributes specified by Attributes for the resource
+ range specified by BarIndex, Offset, and Length were
set on the PCI controller, and the actual resource range is returned
- in Offset and Length.
+ in Offset and Length.
@retval EFI_INVALID_PARAMETER Offset or Length is NULL.
@retval EFI_UNSUPPORTED BarIndex not valid for this PCI controller.
@retval EFI_OUT_OF_RESOURCES There are not enough resources to set the attributes on the
- resource range specified by BarIndex, Offset, and
- Length.
-
+ resource range specified by BarIndex, Offset, and
*** 401 LINES SKIPPED ***