diff options
| author | Marius Strobl <marius@FreeBSD.org> | 2004-08-12 17:41:33 +0000 |
|---|---|---|
| committer | Marius Strobl <marius@FreeBSD.org> | 2004-08-12 17:41:33 +0000 |
| commit | 26280d88d76716790cf28f23fdb0bda56533e9b6 (patch) | |
| tree | e750b2d26d6511903970a6a2a5d73da06845d58b /sys/dev/pcf | |
| parent | 9f7f340a0f9eb8af47d81687feb963fa612242e9 (diff) | |
Notes
Diffstat (limited to 'sys/dev/pcf')
| -rw-r--r-- | sys/dev/pcf/envctrl.c | 8 | ||||
| -rw-r--r-- | sys/dev/pcf/pcf_ebus.c | 15 |
2 files changed, 10 insertions, 13 deletions
diff --git a/sys/dev/pcf/envctrl.c b/sys/dev/pcf/envctrl.c index 74d87c7ac69e..7b5f0649a6d8 100644 --- a/sys/dev/pcf/envctrl.c +++ b/sys/dev/pcf/envctrl.c @@ -46,15 +46,13 @@ __FBSDID("$FreeBSD$"); #include <sys/resource.h> #include <sys/uio.h> +#include <dev/ofw/ofw_bus.h> + #include <machine/bus.h> #include <machine/resource.h> #include <sys/rman.h> -#include <dev/ofw/openfirm.h> - -#include <sparc64/ebus/ebusvar.h> - #include <dev/iicbus/iiconf.h> #include <dev/pcf/pcfvar.h> #include "iicbus_if.h" @@ -95,7 +93,7 @@ static int envctrl_probe(device_t dev) { - if (strcmp("SUNW,envctrl", ebus_get_name(dev)) == 0) { + if (strcmp("SUNW,envctrl", ofw_bus_get_name(dev)) == 0) { device_set_desc(dev, "EBus SUNW,envctrl"); return (0); } diff --git a/sys/dev/pcf/pcf_ebus.c b/sys/dev/pcf/pcf_ebus.c index 13b81102095f..b23c8dd5b5b8 100644 --- a/sys/dev/pcf/pcf_ebus.c +++ b/sys/dev/pcf/pcf_ebus.c @@ -70,15 +70,14 @@ __FBSDID("$FreeBSD$"); #include <sys/module.h> #include <sys/resource.h> +#include <dev/ofw/ofw_bus.h> +#include <dev/ofw/openfirm.h> + #include <machine/bus.h> #include <machine/resource.h> #include <sys/rman.h> -#include <dev/ofw/openfirm.h> - -#include <sparc64/ebus/ebusvar.h> - #include <dev/iicbus/iiconf.h> #include <dev/pcf/pcfvar.h> #include "iicbus_if.h" @@ -117,15 +116,15 @@ static driver_t pcf_ebus_driver = { static int pcf_ebus_probe(device_t dev) { - char *compat; + const char *compat; /* * We must not attach to this i2c device if this is a system with * a boot-bus controller. Additionally testing the compatibility * property will hopefully take care of this. */ - if (strcmp("i2c", ebus_get_name(dev)) == 0) { - compat = ebus_get_compat(dev); + if (strcmp("i2c", ofw_bus_get_name(dev)) == 0) { + compat = ofw_bus_get_compat(dev); if (compat != NULL && strcmp("i2cpcf,8584", compat) == 0) { device_set_desc(dev, "PCF8584 I2C bus controller"); return (0); @@ -146,7 +145,7 @@ pcf_ebus_attach(device_t dev) bzero(sc, sizeof(struct pcf_softc)); /* get OFW node of the pcf */ - if ((node = ebus_get_node(dev)) <= 0) { + if ((node = ofw_bus_get_node(dev)) <= 0) { device_printf(dev, "cannot get OFW node\n"); goto error; } |
