XenevaOS
Loading...
Searching...
No Matches
Classes | Macros | Typedefs | Enumerations | Variables
PciCfg2.h File Reference
#include <Library/BaseLib.h>
Include dependency graph for PciCfg2.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  EFI_PEI_PCI_CFG_PPI_PCI_ADDRESS
 
struct  _EFI_PEI_PCI_CFG2_PPI
 

Macros

#define EFI_PEI_PCI_CFG2_PPI_GUID    { 0x57a449a, 0x1fdc, 0x4c06, { 0xbf, 0xc9, 0xf5, 0x3f, 0x6a, 0x99, 0xbb, 0x92 } }
 
#define EFI_PEI_PCI_CFG_ADDRESS(bus, dev, func, reg)
 

Typedefs

typedef struct _EFI_PEI_PCI_CFG2_PPI EFI_PEI_PCI_CFG2_PPI
 
typedef EFI_STATUS(EFIAPIEFI_PEI_PCI_CFG2_PPI_IO) (IN CONST EFI_PEI_SERVICES **PeiServices, IN CONST EFI_PEI_PCI_CFG2_PPI *This, IN EFI_PEI_PCI_CFG_PPI_WIDTH Width, IN UINT64 Address, IN OUT VOID *Buffer)
 
typedef EFI_STATUS(EFIAPIEFI_PEI_PCI_CFG2_PPI_RW) (IN CONST EFI_PEI_SERVICES **PeiServices, IN CONST EFI_PEI_PCI_CFG2_PPI *This, IN EFI_PEI_PCI_CFG_PPI_WIDTH Width, IN UINT64 Address, IN VOID *SetBits, IN VOID *ClearBits)
 

Enumerations

enum  EFI_PEI_PCI_CFG_PPI_WIDTH {
  EfiPeiPciCfgWidthUint8 = 0 , EfiPeiPciCfgWidthUint16 = 1 , EfiPeiPciCfgWidthUint32 = 2 , EfiPeiPciCfgWidthUint64 = 3 ,
  EfiPeiPciCfgWidthMaximum
}
 

Variables

EFI_GUID gEfiPciCfg2PpiGuid
 

Detailed Description

This file declares PciCfg2 PPI.

This ppi Provides platform or chipset-specific access to the PCI configuration space for a specific PCI segment.

Copyright (c) 2006 - 2018, 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.

Revision Reference:
This PPI is introduced in PI Version 1.0.

Macro Definition Documentation

◆ EFI_PEI_PCI_CFG2_PPI_GUID

#define EFI_PEI_PCI_CFG2_PPI_GUID    { 0x57a449a, 0x1fdc, 0x4c06, { 0xbf, 0xc9, 0xf5, 0x3f, 0x6a, 0x99, 0xbb, 0x92 } }

◆ EFI_PEI_PCI_CFG_ADDRESS

#define EFI_PEI_PCI_CFG_ADDRESS (   bus,
  dev,
  func,
  reg 
)
Value:
(UINT64) ( \
(((UINTN) bus) << 24) | \
(((UINTN) dev) << 16) | \
(((UINTN) func) << 8) | \
(((UINTN) (reg)) < 256 ? ((UINTN) (reg)) : (UINT64) (LShiftU64 ((UINT64) (reg), 32))))
UINT64 UINTN
Definition ProcessorBind.h:118
UINT64 EFIAPI LShiftU64(IN UINT64 Operand, IN UINTN Count)
#define UINTN
Definition acefi.h:222
COMPILER_DEPENDENT_UINT64 UINT64
Definition actypes.h:239

Typedef Documentation

◆ EFI_PEI_PCI_CFG2_PPI

◆ EFI_PEI_PCI_CFG2_PPI_IO

typedef EFI_STATUS(EFIAPI * EFI_PEI_PCI_CFG2_PPI_IO) (IN CONST EFI_PEI_SERVICES **PeiServices, IN CONST EFI_PEI_PCI_CFG2_PPI *This, IN EFI_PEI_PCI_CFG_PPI_WIDTH Width, IN UINT64 Address, IN OUT VOID *Buffer)

Reads from or write to a given location in the PCI configuration space.

Parameters
PeiServicesAn indirect pointer to the PEI Services Table published by the PEI Foundation.
ThisPointer to local data for the interface.
WidthThe width of the access. Enumerated in bytes. See EFI_PEI_PCI_CFG_PPI_WIDTH above.
AddressThe physical address of the access. The format of the address is described by EFI_PEI_PCI_CFG_PPI_PCI_ADDRESS.
BufferA pointer to the buffer of data..
Return values
EFI_SUCCESSThe function completed successfully.
EFI_DEVICE_ERRORThere was a problem with the transaction.
EFI_DEVICE_NOT_READYThe device is not capable of supporting the operation at this time.

◆ EFI_PEI_PCI_CFG2_PPI_RW

typedef EFI_STATUS(EFIAPI * EFI_PEI_PCI_CFG2_PPI_RW) (IN CONST EFI_PEI_SERVICES **PeiServices, IN CONST EFI_PEI_PCI_CFG2_PPI *This, IN EFI_PEI_PCI_CFG_PPI_WIDTH Width, IN UINT64 Address, IN VOID *SetBits, IN VOID *ClearBits)

Performs a read-modify-write operation on the contents from a given location in the PCI configuration space.

Parameters
PeiServicesAn indirect pointer to the PEI Services Table published by the PEI Foundation.
ThisPointer to local data for the interface.
WidthThe width of the access. Enumerated in bytes. Type EFI_PEI_PCI_CFG_PPI_WIDTH is defined in Read().
AddressThe physical address of the access.
SetBitsPoints to value to bitwise-OR with the read configuration value.
                    The size of the value is determined by Width.
ClearBitsPoints to the value to negate and bitwise-AND with the read configuration value. The size of the value is determined by Width.
Return values
EFI_SUCCESSThe function completed successfully.
EFI_DEVICE_ERRORThere was a problem with the transaction.
EFI_DEVICE_NOT_READYThe device is not capable of supporting the operation at this time.

Enumeration Type Documentation

◆ EFI_PEI_PCI_CFG_PPI_WIDTH

EFI_PEI_PCI_CFG_PPI_WIDTH

Enumerator
EfiPeiPciCfgWidthUint8 

8-bit access

EfiPeiPciCfgWidthUint16 

16-bit access

EfiPeiPciCfgWidthUint32 

32-bit access

EfiPeiPciCfgWidthUint64 

64-bit access

EfiPeiPciCfgWidthMaximum 

Variable Documentation

◆ gEfiPciCfg2PpiGuid

EFI_GUID gEfiPciCfg2PpiGuid
extern