ChangeSet 1.897.1.8, 2003/01/08 10:21:15-08:00, neilt@slimy.greenend.org.uk [PATCH] USB Serial patch for old pl2303 devices. I got a PL2303 USB serial converter a few days ago, and got your driver up and running fairly quickly. The problem is that I got an oops when I rmmod-ed the drivers. The pl2303 uses two interfaces but registers only the second (technically wrong, I guess, but should work). When pl2303.o is removed, it attempts to deregister the first interface (which has no effect), so the second interface remains registered with usbserial. The old struct serial still points at the removed pl2303 driver so things go pop when anything touches it. I think the PL2303 hack in usb_serial_probe should not change the "interface" variable, which gets stored in serial->interface, since usbcore will register whatever "ifnum" says. I think that's enough waffle. The patch is below. Keep up the good work! diff -Nru a/drivers/usb/serial/usb-serial.c b/drivers/usb/serial/usb-serial.c --- a/drivers/usb/serial/usb-serial.c Wed Jan 8 11:53:24 2003 +++ b/drivers/usb/serial/usb-serial.c Wed Jan 8 11:53:24 2003 @@ -960,9 +960,7 @@ (dev->descriptor.idProduct == ATEN_PRODUCT_ID))) { if (interface != &dev->actconfig->interface[0]) { /* check out the endpoints of the other interface*/ - //interface = &dev->actconfig->interface[ifnum ^ 1]; - interface = &dev->actconfig->interface[0]; - iface_desc = &interface->altsetting[0]; + iface_desc = &dev->actconfig->interface[0].altsetting[0]; for (i = 0; i < iface_desc->desc.bNumEndpoints; ++i) { endpoint = &iface_desc->endpoint[i].desc; if ((endpoint->bEndpointAddress & 0x80) &&