]> Joshua Wise's Git repositories - netwatch.git/blobdiff - include/pci.h
some more haxing
[netwatch.git] / include / pci.h
index 313b3e0d0570f39a5f8cb4ea6d8a9f01065e275e..9f7e6b90a75c1c64f8bfbc4ca86e4edf236eaa6f 100644 (file)
@@ -36,9 +36,25 @@ typedef struct pci_dev {
        pci_bar_t bars[6];
 } pci_dev_t;
 
-typedef int (*pci_probe_fn_t)(pci_dev_t *);
+typedef int (*pci_probe_fn_t)(pci_dev_t *, void *data);
 
 void pci_bus_enum();
-int pci_probe(pci_probe_fn_t probe);
+int pci_probe(pci_probe_fn_t probe, void *data);
+
+typedef struct pci_id {
+       unsigned short vid, did;
+       const char *name, *friendlyname;
+} pci_id_t;
+
+#define PCI_ROM(a,b,c,d) {(a),(b),(c),(d)}
+
+typedef struct pci_driver {
+       const char *name;
+       pci_probe_fn_t probe;
+       pci_id_t *ids;
+       int id_count;
+} pci_driver_t;
+
+int pci_probe_driver(pci_driver_t driver);
 
 #endif
This page took 0.027081 seconds and 4 git commands to generate.