Check for irq conflicts even if conflicts are allowed. Conflicting

irqs can't work (at best, the first one attached wins).  It used to
be necessary to skip this check because of bogus irqs in the sound
drivers, but the sound drivers have been fixed, except possibly the
OSS ones.
This commit is contained in:
Bruce Evans 1997-08-25 22:52:59 +00:00
parent c77b8656bb
commit ccea0a158a
2 changed files with 18 additions and 14 deletions

View File

@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)isa.c 7.2 (Berkeley) 5/13/91
* $Id: isa.c,v 1.2 1997/08/21 04:51:00 smp Exp smp $
* $Id: isa.c,v 1.101 1997/08/21 05:08:07 fsmp Exp $
*/
/*
@ -122,10 +122,14 @@ haveseen(dvp, tmpdvp, checkbits)
u_int checkbits;
{
/*
* Only check against devices that have already been found and are not
* unilaterally allowed to conflict anyway.
* Ignore all conflicts except IRQ ones if conflicts are allowed.
*/
if (tmpdvp->id_alive && !dvp->id_conflicts) {
if (dvp->id_conflicts)
checkbits &= ~(CC_DRQ | CC_IOADDR | CC_MEMADDR);
/*
* Only check against devices that have already been found.
*/
if (tmpdvp->id_alive) {
char const *whatnot;
whatnot = checkbits & CC_ATTACH ? "attach" : "prob";
@ -508,9 +512,8 @@ config_isadev_c(isdp, mp, reconfig)
* a check for IRQs in the next group of checks.
*/
checkbits |= CC_IRQ;
if (haveseen_isadev(isdp, checkbits)) {
if (haveseen_isadev(isdp, checkbits))
return;
}
isdp->id_alive = id_alive;
}
(*dp->attach)(isdp);
@ -998,4 +1001,3 @@ struct isa_device *find_isadev(table, driverp, unit)
return (table);
}

View File

@ -34,7 +34,7 @@
* SUCH DAMAGE.
*
* from: @(#)isa.c 7.2 (Berkeley) 5/13/91
* $Id: isa.c,v 1.2 1997/08/21 04:51:00 smp Exp smp $
* $Id: isa.c,v 1.101 1997/08/21 05:08:07 fsmp Exp $
*/
/*
@ -122,10 +122,14 @@ haveseen(dvp, tmpdvp, checkbits)
u_int checkbits;
{
/*
* Only check against devices that have already been found and are not
* unilaterally allowed to conflict anyway.
* Ignore all conflicts except IRQ ones if conflicts are allowed.
*/
if (tmpdvp->id_alive && !dvp->id_conflicts) {
if (dvp->id_conflicts)
checkbits &= ~(CC_DRQ | CC_IOADDR | CC_MEMADDR);
/*
* Only check against devices that have already been found.
*/
if (tmpdvp->id_alive) {
char const *whatnot;
whatnot = checkbits & CC_ATTACH ? "attach" : "prob";
@ -508,9 +512,8 @@ config_isadev_c(isdp, mp, reconfig)
* a check for IRQs in the next group of checks.
*/
checkbits |= CC_IRQ;
if (haveseen_isadev(isdp, checkbits)) {
if (haveseen_isadev(isdp, checkbits))
return;
}
isdp->id_alive = id_alive;
}
(*dp->attach)(isdp);
@ -998,4 +1001,3 @@ struct isa_device *find_isadev(table, driverp, unit)
return (table);
}