TianoCore EDK2 master
Loading...
Searching...
No Matches
PciSegmentLibCommon.h File Reference
#include <Base.h>
#include <IndustryStandard/PciExpress21.h>
#include <Library/BaseLib.h>
#include <Library/DebugLib.h>
#include <Library/IoLib.h>
#include <Library/PciSegmentLib.h>
#include <Library/PciSegmentInfoLib.h>

Go to the source code of this file.

Functions

UINTN PciSegmentLibVirtualAddress (IN UINTN Address)
 
UINTN PciSegmentLibGetEcamAddress (IN UINT64 Address, IN CONST PCI_SEGMENT_INFO *SegmentInfo, IN UINTN Count)
 

Detailed Description

Provide common routines used by BasePciSegmentLibSegmentInfo and DxeRuntimePciSegmentLibSegmentInfo libraries.

Copyright (c) 2017, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file PciSegmentLibCommon.h.

Function Documentation

◆ PciSegmentLibGetEcamAddress()

UINTN PciSegmentLibGetEcamAddress ( IN UINT64  Address,
IN CONST PCI_SEGMENT_INFO SegmentInfo,
IN UINTN  Count 
)

Internal function that converts PciSegmentLib format address that encodes the PCI Bus, Device, Function and Register to ECAM (Enhanced Configuration Access Mechanism) address.

Parameters
AddressThe address that encodes the PCI Bus, Device, Function and Register.
SegmentInfoAn array of PCI_SEGMENT_INFO holding the segment information.
CountNumber of segments.
Return values
ECAMaddress.

Definition at line 34 of file PciSegmentLibCommon.c.

◆ PciSegmentLibVirtualAddress()

UINTN PciSegmentLibVirtualAddress ( IN UINTN  Address)

Return the linear address for the physical address.

Parameters
AddressThe physical address.
Return values
Thelinear address.

Return the virtual address for the physical address.

Parameters
AddressThe physical address.
Return values
Thevirtual address.

Definition at line 22 of file BasePciSegmentLib.c.