Module Name: src
Committed By: thorpej
Date: Fri Jan 21 19:12:28 UTC 2022
Modified Files:
src/sys/arch/macppc/pci: bandit.c grackle.c u3.c uninorth.c
src/sys/arch/shark/ofw: ofisascr.c vlpci.c
Log Message:
Don't bother with devhandle_from_of() if we're just forwarding along
our own node; use device_handle(self) instead.
To generate a diff of this commit:
cvs rdiff -u -r1.34 -r1.35 src/sys/arch/macppc/pci/bandit.c
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/macppc/pci/grackle.c
cvs rdiff -u -r1.11 -r1.12 src/sys/arch/macppc/pci/u3.c
cvs rdiff -u -r1.22 -r1.23 src/sys/arch/macppc/pci/uninorth.c
cvs rdiff -u -r1.12 -r1.13 src/sys/arch/shark/ofw/ofisascr.c \
src/sys/arch/shark/ofw/vlpci.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/macppc/pci/bandit.c
diff -u src/sys/arch/macppc/pci/bandit.c:1.34 src/sys/arch/macppc/pci/bandit.c:1.35
--- src/sys/arch/macppc/pci/bandit.c:1.34 Sat Aug 7 16:18:58 2021
+++ src/sys/arch/macppc/pci/bandit.c Fri Jan 21 19:12:28 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: bandit.c,v 1.34 2021/08/07 16:18:58 thorpej Exp $ */
+/* $NetBSD: bandit.c,v 1.35 2022/01/21 19:12:28 thorpej Exp $ */
/*-
* Copyright (c) 2000 Tsubai Masanari. All rights reserved.
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bandit.c,v 1.34 2021/08/07 16:18:58 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bandit.c,v 1.35 2022/01/21 19:12:28 thorpej Exp $");
#include <sys/param.h>
#include <sys/device.h>
@@ -153,7 +153,7 @@ bandit_attach(device_t parent, device_t
pba.pba_flags = PCI_FLAGS_IO_OKAY | PCI_FLAGS_MEM_OKAY;
config_found(self, &pba, pcibusprint,
- CFARGS(.devhandle = devhandle_from_of(node)));
+ CFARGS(.devhandle = device_handle(self)));
}
static pcireg_t
Index: src/sys/arch/macppc/pci/grackle.c
diff -u src/sys/arch/macppc/pci/grackle.c:1.18 src/sys/arch/macppc/pci/grackle.c:1.19
--- src/sys/arch/macppc/pci/grackle.c:1.18 Sat Aug 7 16:18:58 2021
+++ src/sys/arch/macppc/pci/grackle.c Fri Jan 21 19:12:28 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: grackle.c,v 1.18 2021/08/07 16:18:58 thorpej Exp $ */
+/* $NetBSD: grackle.c,v 1.19 2022/01/21 19:12:28 thorpej Exp $ */
/*-
* Copyright (c) 2000 Tsubai Masanari. All rights reserved.
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: grackle.c,v 1.18 2021/08/07 16:18:58 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: grackle.c,v 1.19 2022/01/21 19:12:28 thorpej Exp $");
#include <sys/param.h>
#include <sys/device.h>
@@ -146,7 +146,7 @@ grackle_attach(device_t parent, device_t
pba.pba_flags = PCI_FLAGS_IO_OKAY | PCI_FLAGS_MEM_OKAY;
config_found(self, &pba, pcibusprint,
- CFARGS(.devhandle = devhandle_from_of(node)));
+ CFARGS(.devhandle = device_handle(self)));
}
static pcireg_t
Index: src/sys/arch/macppc/pci/u3.c
diff -u src/sys/arch/macppc/pci/u3.c:1.11 src/sys/arch/macppc/pci/u3.c:1.12
--- src/sys/arch/macppc/pci/u3.c:1.11 Sat Aug 7 16:18:58 2021
+++ src/sys/arch/macppc/pci/u3.c Fri Jan 21 19:12:28 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: u3.c,v 1.11 2021/08/07 16:18:58 thorpej Exp $ */
+/* $NetBSD: u3.c,v 1.12 2022/01/21 19:12:28 thorpej Exp $ */
/*
* Copyright 2006 Kyma Systems LLC.
@@ -166,7 +166,7 @@ ibmcpc_attach(device_t parent, device_t
pba.pba_flags = PCI_FLAGS_MEM_OKAY | PCI_FLAGS_IO_OKAY;
config_found(self, &pba, pcibusprint,
- CFARGS(.devhandle = devhandle_from_of(child)));
+ CFARGS(.devhandle = device_handle(self)));
pc++;
}
Index: src/sys/arch/macppc/pci/uninorth.c
diff -u src/sys/arch/macppc/pci/uninorth.c:1.22 src/sys/arch/macppc/pci/uninorth.c:1.23
--- src/sys/arch/macppc/pci/uninorth.c:1.22 Sat Aug 7 16:18:58 2021
+++ src/sys/arch/macppc/pci/uninorth.c Fri Jan 21 19:12:28 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: uninorth.c,v 1.22 2021/08/07 16:18:58 thorpej Exp $ */
+/* $NetBSD: uninorth.c,v 1.23 2022/01/21 19:12:28 thorpej Exp $ */
/*-
* Copyright (c) 2000 Tsubai Masanari. All rights reserved.
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: uninorth.c,v 1.22 2021/08/07 16:18:58 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: uninorth.c,v 1.23 2022/01/21 19:12:28 thorpej Exp $");
#include <sys/param.h>
#include <sys/device.h>
@@ -184,7 +184,7 @@ uninorth_attach(device_t parent, device_
pba.pba_flags = PCI_FLAGS_IO_OKAY | PCI_FLAGS_MEM_OKAY;
config_found(self, &pba, pcibusprint,
- CFARGS(.devhandle = devhandle_from_of(node)));
+ CFARGS(.devhandle = device_handle(self)));
}
static pcireg_t
Index: src/sys/arch/shark/ofw/ofisascr.c
diff -u src/sys/arch/shark/ofw/ofisascr.c:1.12 src/sys/arch/shark/ofw/ofisascr.c:1.13
--- src/sys/arch/shark/ofw/ofisascr.c:1.12 Sat Aug 7 16:19:05 2021
+++ src/sys/arch/shark/ofw/ofisascr.c Fri Jan 21 19:12:28 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: ofisascr.c,v 1.12 2021/08/07 16:19:05 thorpej Exp $ */
+/* $NetBSD: ofisascr.c,v 1.13 2022/01/21 19:12:28 thorpej Exp $ */
/*
* Copyright 1997
@@ -38,7 +38,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ofisascr.c,v 1.12 2021/08/07 16:19:05 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ofisascr.c,v 1.13 2022/01/21 19:12:28 thorpej Exp $");
#include <sys/param.h>
#include <sys/device.h>
@@ -105,5 +105,5 @@ ofisascrattach(device_t parent, device_t
ia.ia_aux = (void *)oba->oba_phandle;
config_found(dev, &ia, NULL,
- CFARGS(.devhandle = devhandle_from_of(oba->oba_phandle)));
+ CFARGS(.devhandle = device_handle(dev)));
}
Index: src/sys/arch/shark/ofw/vlpci.c
diff -u src/sys/arch/shark/ofw/vlpci.c:1.12 src/sys/arch/shark/ofw/vlpci.c:1.13
--- src/sys/arch/shark/ofw/vlpci.c:1.12 Sat Aug 7 16:19:05 2021
+++ src/sys/arch/shark/ofw/vlpci.c Fri Jan 21 19:12:28 2022
@@ -1,4 +1,4 @@
-/* $NetBSD: vlpci.c,v 1.12 2021/08/07 16:19:05 thorpej Exp $ */
+/* $NetBSD: vlpci.c,v 1.13 2022/01/21 19:12:28 thorpej Exp $ */
/*
* Copyright (c) 2017 Jonathan A. Kollasch
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vlpci.c,v 1.12 2021/08/07 16:19:05 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vlpci.c,v 1.13 2022/01/21 19:12:28 thorpej Exp $");
#include "opt_pci.h"
#include "pci.h"
@@ -329,7 +329,7 @@ vlpci_attach(device_t parent, device_t s
vlpci_dump_window(sc, VLPCI_PCI_WND_NO_3);
config_found(self, &pba, pcibusprint,
- CFARGS(.devhandle = devhandle_from_of(oba->oba_phandle)));
+ CFARGS(.devhandle = device_handle(self)));
}
static void