Attached is a patch that fixes a bug. With this fix, an MS-124W will
work in MB mode (adaptor=3) as advertised. The patch also moves a sanity
check to a slightly better place in the code.
I am using the MS-124W with a USB serial port, and it certainly moves
the bits correctly. I'm not sure about the latency characteristics of
the usb->serial piece, but it seems to me about the same as on a
computer with a 16550.
--
(jfm3 2838 BCBA 93BA 3058 ED95 A42C 37DB 66D1 B43C 9FD0)
diff -urN alsa-driver-0.9.0.ORIG/drivers/serialmidi.c alsa-driver-0.9.0/drivers/serialmidi.c
--- alsa-driver-0.9.0.ORIG/drivers/serialmidi.c 2003-02-21 19:31:00.000000000 -0500
+++ alsa-driver-0.9.0/drivers/serialmidi.c 2003-02-21 19:32:20.000000000 -0500
@@ -439,10 +439,6 @@
serialmidi_t *serial;
int err;
- if (outs < 1)
- outs = 1;
- if (outs > 16)
- outs = 16;
switch (adaptor) {
case SERIAL_ADAPTOR_SOUNDCANVAS:
break;
@@ -452,11 +448,16 @@
break;
case SERIAL_ADAPTOR_MS124W_MB:
outs = 16;
+ break;
default:
snd_printk(KERN_ERR "Adaptor type is out of range 0-%d (%d)\n",
SERIAL_ADAPTOR_MAX, adaptor);
return -ENODEV;
}
+ if (outs < 1)
+ outs = 1;
+ if (outs > 16)
+ outs = 16;
if ((serial = snd_magic_kcalloc(serialmidi_t, 0, GFP_KERNEL)) == NULL)
return -ENOMEM;