aboutsummaryrefslogtreecommitdiff
path: root/sys/powerpc/mambo
diff options
context:
space:
mode:
authorMarcel Moolenaar <marcel@FreeBSD.org>2011-01-29 20:58:38 +0000
committerMarcel Moolenaar <marcel@FreeBSD.org>2011-01-29 20:58:38 +0000
commit6d2d7b8c0d17743d61c63a66ec0a29f18676282f (patch)
treefec042adbb304ebfd29a4edbd235c9e905009e06 /sys/powerpc/mambo
parent696703e5ea1d25b36197d548f9c3ee7a5e294ef3 (diff)
downloadsrc-6d2d7b8c0d17743d61c63a66ec0a29f18676282f.tar.gz
src-6d2d7b8c0d17743d61c63a66ec0a29f18676282f.zip
Notes
Diffstat (limited to 'sys/powerpc/mambo')
-rw-r--r--sys/powerpc/mambo/mambo_openpic.c21
1 files changed, 10 insertions, 11 deletions
diff --git a/sys/powerpc/mambo/mambo_openpic.c b/sys/powerpc/mambo/mambo_openpic.c
index 3edb027780ac..883c9d70209e 100644
--- a/sys/powerpc/mambo/mambo_openpic.c
+++ b/sys/powerpc/mambo/mambo_openpic.c
@@ -56,12 +56,11 @@ __FBSDID("$FreeBSD$");
* Mambo interface
*/
static int openpic_mambo_probe(device_t);
-static uint32_t openpic_mambo_id(device_t dev);
+static int openpic_mambo_attach(device_t);
static int openpicbus_mambo_probe(device_t dev);
static int openpicbus_mambo_attach(device_t dev);
-static struct resource *openpicbus_alloc_resource(device_t bus, device_t dev,
- int type, int *rid, u_long start, u_long end, u_long count,
- u_int flags);
+static struct resource *openpicbus_alloc_resource(device_t bus, device_t dev,
+ int type, int *rid, u_long start, u_long end, u_long count, u_int flags);
static device_method_t openpicbus_mambo_methods[] = {
/* Device interface */
@@ -87,7 +86,7 @@ static driver_t openpicbus_mambo_driver = {
static device_method_t openpic_mambo_methods[] = {
/* Device interface */
DEVMETHOD(device_probe, openpic_mambo_probe),
- DEVMETHOD(device_attach, openpic_attach),
+ DEVMETHOD(device_attach, openpic_mambo_attach),
/* PIC interface */
DEVMETHOD(pic_config, openpic_config),
@@ -97,7 +96,6 @@ static device_method_t openpic_mambo_methods[] = {
DEVMETHOD(pic_ipi, openpic_ipi),
DEVMETHOD(pic_mask, openpic_mask),
DEVMETHOD(pic_unmask, openpic_unmask),
- DEVMETHOD(pic_id, openpic_mambo_id),
{ 0, 0 },
};
@@ -167,14 +165,15 @@ openpicbus_alloc_resource(device_t bus, device_t dev, int type, int *rid,
static int
openpic_mambo_probe(device_t dev)
{
+
device_set_desc(dev, OPENPIC_DEVSTR);
-
return (0);
}
-static uint32_t
-openpic_mambo_id(device_t dev)
+static int
+openpic_mambo_attach(device_t dev)
{
- return (ofw_bus_get_node(device_get_parent(dev)));
+
+ return (openpic_common_attach(dev,
+ ofw_bus_get_node(device_get_parent(dev))));
}
-