On Sun, 13 Feb 2000 18:00:07 CST,  Chris Radek writes:

> I recently upgraded a machine from an old 3.0-RELEASE to the 20000209
> snapshot.  It was previously running a Boca BB2016 multiport serial
> card ("box" actually) correctly.  Now the master port (16) on the card
> works but none of the others seem to generate interrupts.

Argh, I sent that too soon.  I think I found it.

It was broken in rev 1.274 - look at the current sio.c, line 715: idev
should be the master port and not the port being probed.  It even says
so in the comment.  It took me a large part of an evening to read the
bloody comment.  :-)


Here's the patch:

% diff -u sio.c.orig sio.c
--- sio.c.orig  Sun Feb 13 16:59:49 2000
+++ sio.c       Sun Feb 13 18:23:22 2000
@@ -692,7 +692,7 @@
        idev = dev;
        mcr_image = MCR_IENABLE;
 #ifdef COM_MULTIPORT
-       if (COM_ISMULTIPORT(flags) && !COM_NOTAST4(flags)) {
+       if (COM_ISMULTIPORT(flags)) {
                Port_t xiobase;
                u_long io;
 
@@ -702,14 +702,16 @@
                               device_get_unit(dev), COM_MPMASTER(flags));
                        idev = dev;
                }
-               if (bus_get_resource(idev, SYS_RES_IOPORT, 0, &io, NULL) == 0) {
-                       xiobase = io;
-                       if (bus_get_resource(idev, SYS_RES_IRQ, 0, NULL, NULL))
-                               outb(xiobase + com_scr, 0x80);  /* no irq */
-                       else
-                               outb(xiobase + com_scr, 0);
+               if (!COM_NOTAST4(flags)) {
+                       if (bus_get_resource(idev, SYS_RES_IOPORT, 0, &io, NULL) == 0) 
+{
+                               xiobase = io;
+                               if (bus_get_resource(idev, SYS_RES_IRQ, 0, NULL, NULL))
+                                       outb(xiobase + com_scr, 0x80);  /* no irq */
+                               else
+                                       outb(xiobase + com_scr, 0);
+                       }
+                       mcr_image = 0;
                }
-               mcr_image = 0;
        }
 #endif /* COM_MULTIPORT */
        if (bus_get_resource(idev, SYS_RES_IRQ, 0, NULL, NULL) != 0)




To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to