summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/dev/dgb/dgm.c16
-rw-r--r--sys/gnu/i386/isa/dgm.c16
2 files changed, 20 insertions, 12 deletions
diff --git a/sys/dev/dgb/dgm.c b/sys/dev/dgb/dgm.c
index c9d9cab943c4..e274ea70f7ec 100644
--- a/sys/dev/dgb/dgm.c
+++ b/sys/dev/dgb/dgm.c
@@ -1,5 +1,5 @@
/*-
- * $Id: dgm.c,v 1.10 1999/04/28 10:51:58 dt Exp $
+ * $Id: dgm.c,v 1.11 1999/05/02 21:39:52 peter Exp $
*
* This driver and the associated header files support the ISA PC/Xem
* Digiboards. Its evolutionary roots are described below.
@@ -416,9 +416,16 @@ dgmprobe(dev)
/* check type of card and get internal memory characteristics */
- v=inb(sc->port);
+ v = inb(sc->port);
- printf("dgm%d: PC/Xem\n",dev->id_unit);
+ if (!(v & 0x1)) {
+ int second;
+
+ outb(sc->port, 1);
+ second = inb(sc->port);
+ printf("dgm%d: PC/Xem (type %d, %d)\n", dev->id_unit, v, second);
+ } else
+ printf("dgm%d: PC/Xem (type %d)\n", dev->id_unit, v);
sc->type=PCXEM;
sc->mem_seg=0x8000;
@@ -659,8 +666,6 @@ dgmattach(dev)
shrinkmem=0;
}
-/* HERE */
-
port->txptr=mem+( ((bc->tseg)<<4) & 0x7FFF );
port->rxptr=mem+( ((bc->rseg)<<4) & 0x7FFF );
port->txwin=FEPWIN | ((bc->tseg)>>11);
@@ -1886,7 +1891,6 @@ dgmstart(tp)
setwin(sc,0);
head=bc->tin & wmask;
-/*HERE*/
do { tail=bc->tout; } while (tail != bc->tout);
tail=bc->tout & wmask;
diff --git a/sys/gnu/i386/isa/dgm.c b/sys/gnu/i386/isa/dgm.c
index c9d9cab943c4..e274ea70f7ec 100644
--- a/sys/gnu/i386/isa/dgm.c
+++ b/sys/gnu/i386/isa/dgm.c
@@ -1,5 +1,5 @@
/*-
- * $Id: dgm.c,v 1.10 1999/04/28 10:51:58 dt Exp $
+ * $Id: dgm.c,v 1.11 1999/05/02 21:39:52 peter Exp $
*
* This driver and the associated header files support the ISA PC/Xem
* Digiboards. Its evolutionary roots are described below.
@@ -416,9 +416,16 @@ dgmprobe(dev)
/* check type of card and get internal memory characteristics */
- v=inb(sc->port);
+ v = inb(sc->port);
- printf("dgm%d: PC/Xem\n",dev->id_unit);
+ if (!(v & 0x1)) {
+ int second;
+
+ outb(sc->port, 1);
+ second = inb(sc->port);
+ printf("dgm%d: PC/Xem (type %d, %d)\n", dev->id_unit, v, second);
+ } else
+ printf("dgm%d: PC/Xem (type %d)\n", dev->id_unit, v);
sc->type=PCXEM;
sc->mem_seg=0x8000;
@@ -659,8 +666,6 @@ dgmattach(dev)
shrinkmem=0;
}
-/* HERE */
-
port->txptr=mem+( ((bc->tseg)<<4) & 0x7FFF );
port->rxptr=mem+( ((bc->rseg)<<4) & 0x7FFF );
port->txwin=FEPWIN | ((bc->tseg)>>11);
@@ -1886,7 +1891,6 @@ dgmstart(tp)
setwin(sc,0);
head=bc->tin & wmask;
-/*HERE*/
do { tail=bc->tout; } while (tail != bc->tout);
tail=bc->tout & wmask;