UbixOS  2.0
pci.h File Reference
#include <sys/types.h>
Include dependency graph for pci.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  confadd
 
struct  pciConfig
 

Macros

#define countof(a)   (sizeof(a) / sizeof(a[0]))
 

Functions

int pci_init ()
 
uint32_t pciProbe (int bus, int dev, int func)
 
uInt32 pciRead (int bus, int dev, int func, int reg, int bytes)
 
void pciWrite (int bus, int dev, int func, int reg, uInt32 v, int bytes)
 

Macro Definition Documentation

◆ countof

#define countof (   a)    (sizeof(a) / sizeof(a[0]))

Definition at line 98 of file pci.h.

Function Documentation

◆ pci_init()

◆ pciProbe()

◆ pciRead()

uInt32 pciRead ( int  bus,
int  dev,
int  func,
int  reg,
int  bytes 
)

Definition at line 76 of file pci.c.

References confadd::bus, confadd::dev, confadd::enable, confadd::func, inportByte(), inportDWord(), inportWord(), outportDWord(), and confadd::reg.

Referenced by pciProbe().

Here is the call graph for this function:

◆ pciWrite()

void pciWrite ( int  bus,
int  dev,
int  func,
int  reg,
uInt32  v,
int  bytes 
)

Definition at line 108 of file pci.c.

References confadd::bus, confadd::dev, confadd::enable, confadd::func, outportByte(), outportDWord(), outportWord(), and confadd::reg.

Referenced by pciProbe().

Here is the call graph for this function: