summaryrefslogtreecommitdiffstats
path: root/src/core
diff options
context:
space:
mode:
authorMichael Brown2005-04-27 14:20:54 +0200
committerMichael Brown2005-04-27 14:20:54 +0200
commitf37e0a06d7c8cc87f6db33103249e10ffa965251 (patch)
tree13ca6f6ecf1d3858f79f75bb9194471aeb4a1b93 /src/core
parentMissing include (diff)
downloadipxe-f37e0a06d7c8cc87f6db33103249e10ffa965251.tar.gz
ipxe-f37e0a06d7c8cc87f6db33103249e10ffa965251.tar.xz
ipxe-f37e0a06d7c8cc87f6db33103249e10ffa965251.zip
dev.c uses the new tables infrastructure.
Diffstat (limited to 'src/core')
-rw-r--r--src/core/dev.c19
1 files changed, 9 insertions, 10 deletions
diff --git a/src/core/dev.c b/src/core/dev.c
index 8fa3089dc..f03965d25 100644
--- a/src/core/dev.c
+++ b/src/core/dev.c
@@ -3,19 +3,18 @@
#include "dev.h"
/*
- * Each driver specifies a name, the bus-scanning function
- * (find_bus_boot_device) that it wants to use, a driver information
- * structure (bus_driver) containing e.g. device IDs to be passed to
- * find_bus_boot_device, and a probe function (probe) to be called
- * whenever a suitable device is found.
+ * Each bus driver defines several methods, which are described in
+ * dev.h. This file provides a centralised, bus-independent mechanism
+ * for locating devices and drivers.
*
- * The generic device-probing code knows nothing about particular bus
- * types; it simply passes the driver information structure
- * (bus_driver) to the bus-scanning function (find_bus_boot_device),
- * then passes the result of that function (if not NULL) to the probe
- * function (probe).
*/
+/* Linker symbols for the various tables */
+static struct bus_driver bus_drivers[0] __table_start ( bus_driver );
+static struct bus_driver bus_drivers_end[0] __table_end ( bus_driver );
+static struct device_driver device_drivers[0] __table_start ( device_driver );
+static struct device_driver device_drivers_end[0] __table_end (device_driver );
+
/* Current attempted boot device */
struct dev dev = {
.bus_driver = bus_drivers,