summaryrefslogtreecommitdiffstats
path: root/pci.h
diff options
context:
space:
mode:
Diffstat (limited to 'pci.h')
-rw-r--r--pci.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/pci.h b/pci.h
index 3629a6a..f21c478 100644
--- a/pci.h
+++ b/pci.h
@@ -7,6 +7,7 @@ int pci_conf_write(unsigned bus, unsigned dev, unsigned fn, unsigned reg,
unsigned len, unsigned long value);
int pci_init(void);
+#define MAKE_PCIE_ADDRESS(bus, device, function) (((bus) & 0xFF)<<20) | (((device) & 0x1F)<<15) | (((function) & 0x7)<<12)
/*
* Under PCI, each device has 256 bytes of configuration address space,