summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMichael Shalayeff <mickey@cvs.openbsd.org>2000-01-27 09:05:34 +0000
committerMichael Shalayeff <mickey@cvs.openbsd.org>2000-01-27 09:05:34 +0000
commit662f48c1f658c1ad87f7e8772f2239a1b1b553fc (patch)
tree52e7d4dedcfcc6010b86bb13f15680e228c9aada /sys
parentfb0a1db9c14de0a49561b24c23b0c84b31d246fd (diff)
isa-avoidance
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/ic/com.c16
1 files changed, 11 insertions, 5 deletions
diff --git a/sys/dev/ic/com.c b/sys/dev/ic/com.c
index 7567fdc2119..4a99d20212e 100644
--- a/sys/dev/ic/com.c
+++ b/sys/dev/ic/com.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: com.c,v 1.54 2000/01/11 04:08:45 mickey Exp $ */
+/* $OpenBSD: com.c,v 1.55 2000/01/27 09:05:33 mickey Exp $ */
/* $NetBSD: com.c,v 1.82.4.1 1996/06/02 09:08:00 mrg Exp $ */
/*
@@ -91,8 +91,6 @@
#include <machine/bus.h>
#include <machine/intr.h>
-#include <dev/isa/isavar.h> /* XXX */
-
#include <dev/ic/comreg.h>
#include <dev/ic/comvar.h>
#include <dev/ic/ns16550reg.h>
@@ -103,6 +101,10 @@
#include "com.h"
+#if NCOM_ISA || NCOM_ISAPNP
+#include <dev/isa/isavar.h> /* XXX */
+#endif
+
/* XXX: These belong elsewhere */
cdev_decl(com);
bdev_decl(com);
@@ -377,7 +379,10 @@ comattach(parent, self, aux)
void *aux;
{
struct com_softc *sc = (void *)self;
- int iobase, irq;
+ int iobase;
+#if NCOM_ISA || NCOM_ISAPNP || NCOM_COMMULTI
+ int irq;
+#endif
bus_space_tag_t iot;
bus_space_handle_t ioh;
#ifdef COM_HAYESP
@@ -589,6 +594,7 @@ comattach(parent, self, aux)
bus_space_write_1(iot, ioh, com_ier, 0);
bus_space_write_1(iot, ioh, com_mcr, 0);
+#if NCOM_ISA || NCOM_ISAPNP || NCOM_COMMULTI
if (irq != IRQUNK) {
#if NCOM_ISA || NCOM_ISAPNP
if (IS_ISA(parent) || IS_ISAPNP(parent)) {
@@ -601,7 +607,7 @@ comattach(parent, self, aux)
#endif
panic("comattach: IRQ but can't have one");
}
-
+#endif
#ifdef KGDB
if (kgdb_dev == makedev(commajor, unit)) {
if (ISSET(sc->sc_hwflags, COM_HW_CONSOLE))