OvmfPkg[all]  0.1
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
PciCapPciIoLib.h File Reference

Functions

EFI_STATUS EFIAPI PciCapPciIoDeviceInit (IN EFI_PCI_IO_PROTOCOL *PciIo, OUT PCI_CAP_DEV **PciDevice)
 
VOID EFIAPI PciCapPciIoDeviceUninit (IN PCI_CAP_DEV *PciDevice)
 

Detailed Description

Library class layered on top of PciCapLib that allows clients to plug an EFI_PCI_IO_PROTOCOL backend into PciCapLib, for config space access.

Copyright (C) 2018, Red Hat, Inc.

SPDX-License-Identifier: BSD-2-Clause-Patent

Function Documentation

EFI_STATUS EFIAPI PciCapPciIoDeviceInit ( IN EFI_PCI_IO_PROTOCOL *  PciIo,
OUT PCI_CAP_DEV **  PciDevice 
)

Create a PCI_CAP_DEV object from an EFI_PCI_IO_PROTOCOL instance. The config space accessors are based upon EFI_PCI_IO_PROTOCOL.Pci.Read() and EFI_PCI_IO_PROTOCOL.Pci.Write().

Parameters
[in]PciIoEFI_PCI_IO_PROTOCOL representation of the PCI device.
[out]PciDeviceThe PCI_CAP_DEV object constructed as described above. PciDevice can be passed to the PciCapLib APIs.
Return values
EFI_SUCCESSPciDevice has been constructed and output.
EFI_OUT_OF_RESOURCESMemory allocation failed.
VOID EFIAPI PciCapPciIoDeviceUninit ( IN PCI_CAP_DEV PciDevice)

Free the resources used by PciDevice.

Parameters
[in]PciDeviceThe PCI_CAP_DEV object to free, originally produced by PciCapPciIoDeviceInit().