aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/advansys
diff options
context:
space:
mode:
authorWarner Losh <imp@FreeBSD.org>1998-10-10 00:44:12 +0000
committerWarner Losh <imp@FreeBSD.org>1998-10-10 00:44:12 +0000
commit19bed41a5df7cc0eeda8d761596af8272bc420aa (patch)
treefaa1c734d623a6b64c21b1bfd271cbc16f6c780a /sys/dev/advansys
parent51f3fe7ab284f0f713287674fa0ffb6d29c30f89 (diff)
Notes
Diffstat (limited to 'sys/dev/advansys')
-rw-r--r--sys/dev/advansys/adv_isa.c22
1 files changed, 21 insertions, 1 deletions
diff --git a/sys/dev/advansys/adv_isa.c b/sys/dev/advansys/adv_isa.c
index aa311d6c91095..37f534ee432f5 100644
--- a/sys/dev/advansys/adv_isa.c
+++ b/sys/dev/advansys/adv_isa.c
@@ -44,7 +44,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: adv_isa.c,v 1.3 1997/02/22 09:35:51 peter Exp $
+ * $Id: adv_isa.c,v 1.4 1998/09/15 07:03:39 gibbs Exp $
*/
#include <sys/param.h>
@@ -149,6 +149,13 @@ advisaprobe(struct isa_device *id)
if (port_addr == 0)
/* Already been attached */
continue;
+ /*
+ * Make sure that we do not conflict with another device's
+ * I/O address.
+ */
+ if (haveseen_isadev(id, CC_IOADDR))
+ continue;
+
if (adv_find_signature(I386_BUS_SPACE_IO, port_addr)) {
/*
* Got one. Now allocate our softc
@@ -263,6 +270,18 @@ advisaprobe(struct isa_device *id)
adv->overrun_physbase = overrun_physbase;
+ /*
+ * OK, check to make sure that we're not stepping on
+ * someone else's IRQ or DRQ
+ */
+ if (haveseen_isadev(id, CC_DRQ)) {
+ printf("advisaprobe: Aha card at I/O 0x%x's "
+ "drq %d conflicts, ignoring card.\n",
+ id->id_iobase, id->id_drq);
+ adv_free(adv);
+ return 0;
+ }
+
if (adv_init(adv) != 0) {
adv_free(adv);
return (0);
@@ -295,6 +314,7 @@ advisaprobe(struct isa_device *id)
id->id_irq = 1 << adv_get_chip_irq(adv);
else
adv_set_chip_irq(adv, ffs(id->id_irq) - 1);
+
id->id_intr = adv_isa_intr;
/* Mark as probed */