summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authorthorpej <thorpej@NetBSD.org>2021-05-10 23:53:44 +0000
committerthorpej <thorpej@NetBSD.org>2021-05-10 23:53:44 +0000
commitf7becf83e83c37022d5bfc22317ef9689c8291f2 (patch)
tree15ff3c17d80d60d33a3201dce9fc3bf75b24d52e /sys/dev
parent79db7aecba3149e3507d4fc7257d807633620fc0 (diff)
Associate the OpenBoot / OpenFirmware node with attached devices
at config_found() time.
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/sbus/dma_sbus.c5
-rw-r--r--sys/dev/sbus/lebuffer.c8
-rw-r--r--sys/dev/sbus/qec.c8
-rw-r--r--sys/dev/sbus/xbox.c8
4 files changed, 18 insertions, 11 deletions
diff --git a/sys/dev/sbus/dma_sbus.c b/sys/dev/sbus/dma_sbus.c
index 307119317f5..b113212037e 100644
--- a/sys/dev/sbus/dma_sbus.c
+++ b/sys/dev/sbus/dma_sbus.c
@@ -1,4 +1,4 @@
-/* $NetBSD: dma_sbus.c,v 1.36 2021/04/24 23:36:58 thorpej Exp $ */
+/* $NetBSD: dma_sbus.c,v 1.37 2021/05/10 23:53:44 thorpej Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -59,7 +59,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: dma_sbus.c,v 1.36 2021/04/24 23:36:58 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dma_sbus.c,v 1.37 2021/05/10 23:53:44 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -211,6 +211,7 @@ dmaattach_sbus(device_t parent, device_t self, void *aux)
struct sbus_attach_args sax;
sbus_setup_attach_args(sbsc, sbt, sc->sc_dmatag, node, &sax);
(void)config_found(self, (void *)&sax, dmaprint_sbus,
+ CFARG_DEVHANDLE, prom_node_to_devhandle(node),
CFARG_EOL);
sbus_destroy_attach_args(&sax);
}
diff --git a/sys/dev/sbus/lebuffer.c b/sys/dev/sbus/lebuffer.c
index ee41bfc54bc..244a8a3e59f 100644
--- a/sys/dev/sbus/lebuffer.c
+++ b/sys/dev/sbus/lebuffer.c
@@ -1,4 +1,4 @@
-/* $NetBSD: lebuffer.c,v 1.37 2021/04/24 23:36:58 thorpej Exp $ */
+/* $NetBSD: lebuffer.c,v 1.38 2021/05/10 23:53:44 thorpej Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: lebuffer.c,v 1.37 2021/04/24 23:36:58 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: lebuffer.c,v 1.38 2021/05/10 23:53:44 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -124,7 +124,9 @@ lebufattach(device_t parent, device_t self, void *aux)
struct sbus_attach_args sax;
sbus_setup_attach_args(sbsc,
bt, dt, node, &sax);
- (void)config_found(self, (void *)&sax, lebufprint, CFARG_EOL);
+ (void)config_found(self, (void *)&sax, lebufprint,
+ CFARG_DEVHANDLE, prom_node_to_devhandle(node),
+ CFARG_EOL);
sbus_destroy_attach_args(&sax);
}
}
diff --git a/sys/dev/sbus/qec.c b/sys/dev/sbus/qec.c
index c1b295338a9..c433865cca3 100644
--- a/sys/dev/sbus/qec.c
+++ b/sys/dev/sbus/qec.c
@@ -1,4 +1,4 @@
-/* $NetBSD: qec.c,v 1.51 2021/04/24 23:36:58 thorpej Exp $ */
+/* $NetBSD: qec.c,v 1.52 2021/05/10 23:53:44 thorpej Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: qec.c,v 1.51 2021/04/24 23:36:58 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: qec.c,v 1.52 2021/05/10 23:53:44 thorpej Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -207,7 +207,9 @@ qecattach(device_t parent, device_t self, void *aux)
struct sbus_attach_args sax;
sbus_setup_attach_args(sbsc,
sbt, sc->sc_dmatag, node, &sax);
- (void)config_found(self, (void *)&sax, qecprint, CFARG_EOL);
+ (void)config_found(self, (void *)&sax, qecprint,
+ CFARG_DEVHANDLE, prom_node_to_devhandle(node),
+ CFARG_EOL);
sbus_destroy_attach_args(&sax);
}
}
diff --git a/sys/dev/sbus/xbox.c b/sys/dev/sbus/xbox.c
index 625632effc5..1a96dbd7f7e 100644
--- a/sys/dev/sbus/xbox.c
+++ b/sys/dev/sbus/xbox.c
@@ -1,4 +1,4 @@
-/* $NetBSD: xbox.c,v 1.22 2021/04/24 23:36:58 thorpej Exp $ */
+/* $NetBSD: xbox.c,v 1.23 2021/05/10 23:53:44 thorpej Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: xbox.c,v 1.22 2021/04/24 23:36:58 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: xbox.c,v 1.23 2021/05/10 23:53:44 thorpej Exp $");
#include <sys/param.h>
#include <sys/malloc.h>
@@ -149,5 +149,7 @@ xbox_attach(device_t parent, device_t self, void *aux)
xa.xa_bustag = sa->sa_bustag;
xa.xa_dmatag = sa->sa_dmatag;
- (void) config_found(self, (void *)&xa, xbox_print, CFARG_EOL);
+ (void) config_found(self, (void *)&xa, xbox_print,
+ CFARG_DEVHANDLE, prom_node_to_devhandle(node),
+ CFARG_EOL);
}