Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-2-0]: src/sys/arch/macppc/pci Pull up revision 1.26 (requested by...
details: https://anonhg.NetBSD.org/src/rev/20ab71b18c86
branches: netbsd-2-0
changeset: 564814:20ab71b18c86
user: tron <tron%NetBSD.org@localhost>
date: Sun Jul 24 10:08:02 2005 +0000
description:
Pull up revision 1.26 (requested by briggs in ticket #1329):
OpenFirmware on machines with the "Grackle" bridge assign an 'AAPL,interrupts'
property instead of 'interrupt-map' and 'interrupt-map-mask' properties.
Adjust for this by checking for the latter, and if they're not present
(and the parent isn't 'pci-bridge'), then look for 'AAPL,interrupts'.
Problem analyzed and patched by Tim Kelly on port-macppc. I modified the
patch to move the fallback into find_node_intr(), tweaking some previously-
disabled code.
diffstat:
sys/arch/macppc/pci/pci_machdep.c | 13 +++++++------
1 files changed, 7 insertions(+), 6 deletions(-)
diffs (36 lines):
diff -r 0b71f3cdbcef -r 20ab71b18c86 sys/arch/macppc/pci/pci_machdep.c
--- a/sys/arch/macppc/pci/pci_machdep.c Mon Jul 18 04:04:04 2005 +0000
+++ b/sys/arch/macppc/pci/pci_machdep.c Sun Jul 24 10:08:02 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pci_machdep.c,v 1.24.2.1 2004/04/09 02:31:12 jmc Exp $ */
+/* $NetBSD: pci_machdep.c,v 1.24.2.2 2005/07/24 10:08:02 tron Exp $ */
/*
* Copyright (c) 1996 Christopher G. Demetriou. All rights reserved.
@@ -43,7 +43,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pci_machdep.c,v 1.24.2.1 2004/04/09 02:31:12 jmc Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pci_machdep.c,v 1.24.2.2 2005/07/24 10:08:02 tron Exp $");
#include <sys/types.h>
#include <sys/param.h>
@@ -494,12 +494,13 @@
#endif
}
-#if 0
- /* XXX This may be wrong... */
- len = OF_getprop(node, "interrupts", intr, 4) ;
+ /*
+ * If all else fails, attempt to get AAPL, interrupts property.
+ * Grackle, at least, uses this instead of above in some cases.
+ */
+ len = OF_getprop(node, "AAPL,interrupts", intr, 4) ;
if (len == 4)
return len;
-#endif
return -1;
}
Home |
Main Index |
Thread Index |
Old Index