summaryrefslogtreecommitdiffstats
path: root/sys/isa/isa_if.m
diff options
context:
space:
mode:
authordfr <dfr@FreeBSD.org>1999-09-01 20:53:43 +0000
committerdfr <dfr@FreeBSD.org>1999-09-01 20:53:43 +0000
commitf351c4f3dc1d761f44335d85fee57eb133919756 (patch)
treef5d858916a67aca8a86dac46559341c270c6d087 /sys/isa/isa_if.m
parentc93ae1166c126cfb59736d68f475ad5948708da7 (diff)
downloadFreeBSD-src-f351c4f3dc1d761f44335d85fee57eb133919756.zip
FreeBSD-src-f351c4f3dc1d761f44335d85fee57eb133919756.tar.gz
This represents essentially a complete rewrite of the ISA PnP code. The
new system is integrated with the ISA bus code more cleanly and allows the future addition of more enumerators such as PnPBIOS and ACPI. This commit also enables the new pcm driver since it is somewhat tied to the new PnP code.
Diffstat (limited to 'sys/isa/isa_if.m')
-rw-r--r--sys/isa/isa_if.m44
1 files changed, 44 insertions, 0 deletions
diff --git a/sys/isa/isa_if.m b/sys/isa/isa_if.m
index 051b0de..2c3ab0f 100644
--- a/sys/isa/isa_if.m
+++ b/sys/isa/isa_if.m
@@ -26,6 +26,10 @@
# $FreeBSD$
#
+CODE {
+#include <isa/isavar.h>
+};
+
INTERFACE isa;
#
@@ -63,3 +67,43 @@ METHOD void delete_resource {
int type;
int rid;
};
+
+#
+# Add a Plug-and-play configuration to the device. Configurations with
+# a lower priority are preferred.
+#
+METHOD int add_config {
+ device_t dev;
+ device_t child;
+ int priority;
+ struct isa_config *config;
+};
+
+#
+# Register a function which can be called to configure a device with
+# a given set of resources. The function will be called with a struct
+# isa_config representing the desired configuration and a flag to
+# state whether the device should be enabled.
+#
+METHOD void set_config_callback {
+ device_t dev;
+ device_t child;
+ isa_config_cb *fn;
+ void *arg;
+};
+
+#
+# A helper method for implementing probe methods for PnP compatible
+# drivers. The driver calls this method with a list of PnP ids and
+# descriptions and it returns zero if one of the ids matches or ENXIO
+# otherwise.
+#
+# If the device is not plug-and-play compatible, this method returns
+# ENOENT, allowing the caller to fall back to heuristic probing
+# techniques.
+#
+METHOD int pnp_probe {
+ device_t dev;
+ device_t child;
+ struct isa_pnp_id *ids;
+};
OpenPOWER on IntegriCloud