μHAL
pcie-open.h File Reference
#include "pcie-defs.h"
Include dependency graph for pcie-open.h:

Go to the source code of this file.

Functions

void dev_open_slot (struct pcie_bars &bars, int slot)
 
void dev_open_slot (struct pcie_bars &bars, const char *slot)
 
void dev_open (struct pcie_bars &bars, const char *pci_address)
 
void dev_open_serial (struct pcie_bars &bars, const char *dev_file)
 
void dev_close (struct pcie_bars &bars)
 

Detailed Description

This file contains the functions used to initialize and destroy a pcie_bars struct.

Function Documentation

◆ dev_close()

void dev_close ( struct pcie_bars bars)

Unmap memory and destroy mutexes of pcie_bars

◆ dev_open()

void dev_open ( struct pcie_bars bars,
const char *  pci_address 
)

Memory map the BARs of PCIe device with address pci_address, found in "/sys/bus/pci/devices/<pci_address>.0/"

◆ dev_open_slot() [1/2]

void dev_open_slot ( struct pcie_bars bars,
const char *  slot 
)

Memory map the BARs of PCIe device in slot, when slot isn't a simple integer

◆ dev_open_slot() [2/2]

void dev_open_slot ( struct pcie_bars bars,
int  slot 
)

Memory map the BARs of PCIe device in slot