fix > 5 with MFsrc:

| Mar 1 2005 by imp
| Use BUS_PROBE_DEFAULT in preference to 0 and BUS_PROBE_LOW_PRIORITY in
| preference to some random negative number to allow other drivers a
| bite at the apple.

| Sep 2 2003 by jhb
| Use PCIR_BAR(x) instead of PCIR_MAPS.
This commit is contained in:
FUJISHIMA Satsuki 2005-08-28 23:04:34 +00:00
parent a2aefd0e34
commit c34c843e67
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=141205

View File

@ -2,7 +2,7 @@
$FreeBSD$
--- au88x0.c.orig Fri May 10 10:32:55 2002
+++ au88x0.c Thu Aug 5 05:44:30 2004
+++ au88x0.c Sun Aug 7 18:14:57 2005
@@ -29,10 +29,16 @@
*/
@ -30,6 +30,24 @@ $FreeBSD$
printf("sndbuf_alloc failed\n");
return NULL;
}
@@ -768,7 +774,7 @@
}
if (s) device_set_desc(dev, s);
- return s ? 0 : ENXIO;
+ return s ? BUS_PROBE_DEFAULT : ENXIO;
}
static int
@@ -802,7 +808,7 @@
data = pci_read_config(dev, PCIR_COMMAND, 2);
for (i = 0; i < 3; i++) {
- au->regid[i] = PCIR_MAPS + i*4;
+ au->regid[i] = PCIR_BAR(i);
au->regtype[i] = SYS_RES_MEMORY;
au->reg[i] = bus_alloc_resource(dev, au->regtype[i], &au->regid[i], 0, ~0, 1, RF_ACTIVE);
if (!au->reg[i]) {
@@ -852,7 +858,11 @@
/*highaddr*/BUS_SPACE_MAXADDR,
/*filter*/NULL, /*filterarg*/NULL,