|
PCI_ROOT_BRIDGE_INSTANCE * | CreateRootBridge (IN PCI_ROOT_BRIDGE *Bridge) |
|
EFI_STATUS EFIAPI | RootBridgeIoPollMem (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width, IN UINT64 Address, IN UINT64 Mask, IN UINT64 Value, IN UINT64 Delay, OUT UINT64 *Result) |
|
EFI_STATUS EFIAPI | RootBridgeIoPollIo (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width, IN UINT64 Address, IN UINT64 Mask, IN UINT64 Value, IN UINT64 Delay, OUT UINT64 *Result) |
|
EFI_STATUS EFIAPI | RootBridgeIoMemRead (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width, IN UINT64 Address, IN UINTN Count, IN OUT VOID *Buffer) |
|
EFI_STATUS EFIAPI | RootBridgeIoMemWrite (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width, IN UINT64 Address, IN UINTN Count, IN OUT VOID *Buffer) |
|
EFI_STATUS EFIAPI | RootBridgeIoIoRead (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width, IN UINT64 UserAddress, IN UINTN Count, IN OUT VOID *UserBuffer) |
|
EFI_STATUS EFIAPI | RootBridgeIoIoWrite (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width, IN UINT64 UserAddress, IN UINTN Count, IN OUT VOID *UserBuffer) |
|
EFI_STATUS EFIAPI | RootBridgeIoCopyMem (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width, IN UINT64 DestAddress, IN UINT64 SrcAddress, IN UINTN Count) |
|
EFI_STATUS EFIAPI | RootBridgeIoPciRead (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width, IN UINT64 Address, IN UINTN Count, IN OUT VOID *Buffer) |
|
EFI_STATUS EFIAPI | RootBridgeIoPciWrite (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH Width, IN UINT64 Address, IN UINTN Count, IN OUT VOID *Buffer) |
|
EFI_STATUS EFIAPI | RootBridgeIoMap (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_OPERATION Operation, IN VOID *HostAddress, IN OUT UINTN *NumberOfBytes, OUT EFI_PHYSICAL_ADDRESS *DeviceAddress, OUT VOID **Mapping) |
|
EFI_STATUS EFIAPI | RootBridgeIoUnmap (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN VOID *Mapping) |
|
EFI_STATUS EFIAPI | RootBridgeIoAllocateBuffer (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN EFI_ALLOCATE_TYPE Type, IN EFI_MEMORY_TYPE MemoryType, IN UINTN Pages, OUT VOID **HostAddress, IN UINT64 Attributes) |
|
EFI_STATUS EFIAPI | RootBridgeIoFreeBuffer (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN UINTN Pages, OUT VOID *HostAddress) |
|
EFI_STATUS EFIAPI | RootBridgeIoFlush (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This) |
|
EFI_STATUS EFIAPI | RootBridgeIoGetAttributes (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, OUT UINT64 *Supported, OUT UINT64 *Attributes) |
|
EFI_STATUS EFIAPI | RootBridgeIoSetAttributes (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, IN UINT64 Attributes, IN OUT UINT64 *ResourceBase, IN OUT UINT64 *ResourceLength) |
|
EFI_STATUS EFIAPI | RootBridgeIoConfiguration (IN EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL *This, OUT VOID **Resources) |
|
The PCI Root Bridge header file.
Copyright (c) 1999 - 2018, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file PciRootBridge.h.
Retrieves the current resource settings of this PCI root bridge in the form of a set of ACPI resource descriptor.
- Parameters
-
This | - Pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance. |
Resources | - Pointer to the resource descriptor that describe the current configuration of this PCI root bridge. |
- Return values
-
EFI_SUCCESS | - Success. |
EFI_UNSUPPORTED | - Current configuration of the PCI root bridge |
could | not be retrieved. |
Retrieves the current resource settings of this PCI root bridge in the form of a set of ACPI resource descriptors.
There are only two resource descriptor types from the ACPI Specification that may be used to describe the current resources allocated to a PCI root bridge. These are the QWORD Address Space Descriptor, and the End Tag. The QWORD Address Space Descriptor can describe memory, I/O, and bus number ranges for dynamic or fixed resources. The configuration of a PCI root bridge is described with one or more QWORD Address Space Descriptors followed by an End Tag.
- Parameters
-
[in] | This | A pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL. |
[out] | Resources | A pointer to the resource descriptors that describe the current configuration of this PCI root bridge. The storage for the resource descriptors is allocated by this function. The caller must treat the return buffer as read-only data, and the buffer must not be freed by the caller. |
- Return values
-
EFI_SUCCESS | The current configuration of this PCI root bridge was returned in Resources. |
EFI_UNSUPPORTED | The current configuration of this PCI root bridge could not be retrieved. |
Definition at line 1882 of file PciRootBridgeIo.c.
Copy one region of PCI root bridge memory space to be copied to another region of PCI root bridge memory space.
- Parameters
-
This | - A pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance. |
Width | - Signifies the width of the memory operation. |
DestAddress | - Destination address of the memory operation. |
SrcAddress | - Source address of the memory operation. |
Count | - Number of memory operations to perform. |
- Return values
-
EFI_SUCCESS | - The data was copied successfully. |
EFI_INVALID_PARAMETER | - Invalid parameters found. |
EFI_OUT_OF_RESOURCES | - The request could not be completed due to a lack of |
resources. | |
Enables a PCI driver to copy one region of PCI root bridge memory space to another region of PCI root bridge memory space.
The CopyMem() function enables a PCI driver to copy one region of PCI root bridge memory space to another region of PCI root bridge memory space. This is especially useful for video scroll operation on a memory mapped video buffer. The memory operations are carried out exactly as requested. The caller is responsible for satisfying any alignment and memory width restrictions that a PCI root bridge on a platform might require.
- Parameters
-
[in] | This | A pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance. |
[in] | Width | Signifies the width of the memory operations. |
[in] | DestAddress | The destination address of the memory operation. The caller is responsible for aligning the DestAddress if required. |
[in] | SrcAddress | The source address of the memory operation. The caller is responsible for aligning the SrcAddress if required. |
[in] | Count | The number of memory operations to perform. Bytes moved is Width size * Count, starting at DestAddress and SrcAddress. |
- Return values
-
EFI_SUCCESS | The data was copied from one memory region to another memory region. |
EFI_INVALID_PARAMETER | Width is invalid for this PCI root bridge. |
EFI_OUT_OF_RESOURCES | The request could not be completed due to a lack of resources. |
Definition at line 1102 of file PciRootBridgeIo.c.
Flushes all PCI posted write transactions from a PCI host bridge to system memory.
- Parameters
-
This | - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance. |
- Return values
-
EFI_SUCCESS | - PCI posted write transactions were flushed |
from | PCI host bridge to system memory. |
EFI_DEVICE_ERROR | - Fail due to hardware error. |
Flushes all PCI posted write transactions from a PCI host bridge to system memory.
The Flush() function flushes any PCI posted write transactions from a PCI host bridge to system memory. Posted write transactions are generated by PCI bus masters when they perform write transactions to target addresses in system memory. This function does not flush posted write transactions from any PCI bridges. A PCI controller specific action must be taken to guarantee that the posted write transactions have been flushed from the PCI controller and from all the PCI bridges into the PCI host bridge. This is typically done with a PCI read transaction from the PCI controller prior to calling Flush().
- Parameters
-
This | A pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL. |
- Return values
-
EFI_SUCCESS | The PCI posted write transactions were flushed from the PCI host bridge to system memory. |
EFI_DEVICE_ERROR | The PCI posted write transactions were not flushed from the PCI host bridge due to a hardware error. |
Definition at line 1740 of file PciRootBridgeIo.c.
Poll an address in I/O space until an exit condition is met or a timeout occurs.
- Parameters
-
This | - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance. |
Width | - Width of I/O operation. |
Address | - The base address of the I/O operation. |
Mask | - Mask used for polling criteria. |
Value | - Comparison value used for polling exit criteria. |
Delay | - Number of 100ns units to poll. |
Result | - Pointer to the last value read from memory location. |
- Return values
-
EFI_SUCCESS | - Success. |
EFI_INVALID_PARAMETER | - Invalid parameter found. |
EFI_TIMEOUT | - Delay expired before a match occurred. |
EFI_OUT_OF_RESOURCES | - Fail due to lack of resources. |
Reads from the I/O space of a PCI Root Bridge. Returns when either the polling exit criteria is satisfied or after a defined duration.
This function provides a standard way to poll a PCI I/O location. A PCI I/O read operation is performed at the PCI I/O address specified by Address for the width specified by Width. The result of this PCI I/O read operation is stored in Result. This PCI I/O read operation is repeated until either a timeout of Delay 100 ns units has expired, or (Result & Mask) is equal to Value.
- Parameters
-
[in] | This | A pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL. |
[in] | Width | Signifies the width of the I/O operations. |
[in] | Address | The base address of the I/O operations. The caller is responsible for aligning Address if required. |
[in] | Mask | Mask used for the polling criteria. Bytes above Width in Mask are ignored. The bits in the bytes below Width which are zero in Mask are ignored when polling the I/O address. |
[in] | Value | The comparison value used for the polling exit criteria. |
[in] | Delay | The number of 100 ns units to poll. Note that timer available may be of poorer granularity. |
[out] | Result | Pointer to the last value read from the memory location. |
- Return values
-
EFI_SUCCESS | The last data returned from the access matched the poll exit criteria. |
EFI_INVALID_PARAMETER | Width is invalid. |
EFI_INVALID_PARAMETER | Result is NULL. |
EFI_TIMEOUT | Delay expired before a match occurred. |
EFI_OUT_OF_RESOURCES | The request could not be completed due to a lack of resources. |
Definition at line 740 of file PciRootBridgeIo.c.
Poll an address in memory mapped space until an exit condition is met or a timeout occurs.
- Parameters
-
This | - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance. |
Width | - Width of the memory operation. |
Address | - The base address of the memory operation. |
Mask | - Mask used for polling criteria. |
Value | - Comparison value used for polling exit criteria. |
Delay | - Number of 100ns units to poll. |
Result | - Pointer to the last value read from memory location. |
- Return values
-
EFI_SUCCESS | - Success. |
EFI_INVALID_PARAMETER | - Invalid parameter found. |
EFI_TIMEOUT | - Delay expired before a match occurred. |
EFI_OUT_OF_RESOURCES | - Fail due to lack of resources. |
Polls an address in memory mapped I/O space until an exit condition is met, or a timeout occurs.
This function provides a standard way to poll a PCI memory location. A PCI memory read operation is performed at the PCI memory address specified by Address for the width specified by Width. The result of this PCI memory read operation is stored in Result. This PCI memory read operation is repeated until either a timeout of Delay 100 ns units has expired, or (Result & Mask) is equal to Value.
- Parameters
-
[in] | This | A pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL. |
[in] | Width | Signifies the width of the memory operations. |
[in] | Address | The base address of the memory operations. The caller is responsible for aligning Address if required. |
[in] | Mask | Mask used for the polling criteria. Bytes above Width in Mask are ignored. The bits in the bytes below Width which are zero in Mask are ignored when polling the memory address. |
[in] | Value | The comparison value used for the polling exit criteria. |
[in] | Delay | The number of 100 ns units to poll. Note that timer available may be of poorer granularity. |
[out] | Result | Pointer to the last value read from the memory location. |
- Return values
-
EFI_SUCCESS | The last data returned from the access matched the poll exit criteria. |
EFI_INVALID_PARAMETER | Width is invalid. |
EFI_INVALID_PARAMETER | Result is NULL. |
EFI_TIMEOUT | Delay expired before a match occurred. |
EFI_OUT_OF_RESOURCES | The request could not be completed due to a lack of resources. |
Definition at line 636 of file PciRootBridgeIo.c.
Sets the attributes for a resource range on a PCI root bridge.
- Parameters
-
This | - Pointer to EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL instance. |
Attributes | - The mask of attributes to set. |
ResourceBase | - Pointer to the base address of the resource range to be modified by the attributes specified by Attributes. |
ResourceLength | - Pointer to the length of the resource range to be modified. |
- Return values
-
EFI_SUCCESS | - Success. |
EFI_INVALID_PARAMETER | - Invalid parameter found. |
EFI_OUT_OF_RESOURCES | - Not enough resources to set the attributes upon. |
Sets attributes for a resource range on a PCI root bridge.
The SetAttributes() function sets the attributes specified in Attributes for the PCI root bridge on the resource range specified by ResourceBase and ResourceLength. Since the granularity of setting these attributes may vary from resource type to resource type, and from platform to platform, the actual resource range and the one passed in by the caller may differ. As a result, this function may set the attributes specified by Attributes on a larger resource range than the caller requested. The actual range is returned in ResourceBase and ResourceLength. The caller is responsible for verifying that the actual range for which the attributes were set is acceptable.
- Parameters
-
This | A pointer to the EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL. |
Attributes | The mask of attributes to set. If the attribute bit MEMORY_WRITE_COMBINE, MEMORY_CACHED, or MEMORY_DISABLE is set, then the resource range is specified by ResourceBase and ResourceLength. If MEMORY_WRITE_COMBINE, MEMORY_CACHED, and MEMORY_DISABLE are not set, then ResourceBase and ResourceLength are ignored, and may be NULL. |
ResourceBase | A pointer to the base address of the resource range to be modified by the attributes specified by Attributes. |
ResourceLength | A pointer to the length of the resource range to be modified by the attributes specified by Attributes. |
- Return values
-
EFI_SUCCESS | The current configuration of this PCI root bridge was returned in Resources. |
EFI_UNSUPPORTED | The current configuration of this PCI root bridge could not be retrieved. |
Definition at line 1836 of file PciRootBridgeIo.c.