summaryrefslogtreecommitdiff
path: root/sys/arch/sgi/xbow
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2009-06-27 16:34:51 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2009-06-27 16:34:51 +0000
commitec0812ae8b83537f3a7048ea954974b085636082 (patch)
treeb6600fe5f09c471715e8f1b76ad040d2f7f60f5c /sys/arch/sgi/xbow
parent99f873339e74f405d16a3038302eb2d5bfbfc309 (diff)
If a device which has not been initialized by ARCS has a non-zero BAR, ignore
it if it does not fit in our extent, and force a suitable address. Prevents extent sanity check panics with some cards.
Diffstat (limited to 'sys/arch/sgi/xbow')
-rw-r--r--sys/arch/sgi/xbow/xbridge.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/arch/sgi/xbow/xbridge.c b/sys/arch/sgi/xbow/xbridge.c
index 804ac7fd6ce..de9a7da1dd3 100644
--- a/sys/arch/sgi/xbow/xbridge.c
+++ b/sys/arch/sgi/xbow/xbridge.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: xbridge.c,v 1.27 2009/06/21 18:03:16 miod Exp $ */
+/* $OpenBSD: xbridge.c,v 1.28 2009/06/27 16:34:50 miod Exp $ */
/*
* Copyright (c) 2008, 2009 Miodrag Vallat.
@@ -1905,7 +1905,8 @@ xbridge_resource_manage(struct xbridge_softc *sc, pcitag_t tag,
*/
break;
case PCI_MAPREG_TYPE_IO:
- if (base != 0) {
+ if (base != 0 && base >= ioex->ex_start &&
+ base + size - 1 <= ioex->ex_end) {
if (extent_alloc_region(ioex, base, size,
EX_NOWAIT))
printf("io address conflict"