summaryrefslogtreecommitdiffstats
path: root/src/include/gpxe/pci.h
diff options
context:
space:
mode:
authorMichael Brown2007-01-10 05:22:09 +0100
committerMichael Brown2007-01-10 05:22:09 +0100
commitdad52745227fd06090e73ea535e0b0fe0f667c60 (patch)
tree6be296bedc785a5aab0d055ae148c6ffb1fe285f /src/include/gpxe/pci.h
parentRemove uIP; we haven't used it for quite some time now. (diff)
downloadipxe-dad52745227fd06090e73ea535e0b0fe0f667c60.tar.gz
ipxe-dad52745227fd06090e73ea535e0b0fe0f667c60.tar.xz
ipxe-dad52745227fd06090e73ea535e0b0fe0f667c60.zip
Add "name" field to struct device to allow human-readable hardware device
names. Add "dev" pointer in struct net_device to tie network interfaces back to a hardware device. Force natural alignment of data types in __table() macros. This seems to prevent gcc from taking the unilateral decision to occasionally increase their alignment (which screws up the table packing).
Diffstat (limited to 'src/include/gpxe/pci.h')
-rw-r--r--src/include/gpxe/pci.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/include/gpxe/pci.h b/src/include/gpxe/pci.h
index a27d6f1f..8269dfaa 100644
--- a/src/include/gpxe/pci.h
+++ b/src/include/gpxe/pci.h
@@ -277,8 +277,8 @@ struct pci_device {
* field.
*/
void *priv;
- /** Device name */
- const char *name;
+ /** Driver name */
+ const char *driver_name;
};
/** A PCI driver */
@@ -305,7 +305,7 @@ struct pci_driver {
};
/** Declare a PCI driver */
-#define __pci_driver __table ( pci_drivers, 01 )
+#define __pci_driver __table ( struct pci_driver, pci_drivers, 01 )
#define PCI_DEVFN( slot, func ) ( ( (slot) << 3 ) | (func) )
#define PCI_SLOT( devfn ) ( ( (devfn) >> 3 ) & 0x1f )