• Neil Turton's avatar
    [PATCH] USB Serial patch for old pl2303 devices. · ec58f8e3
    Neil Turton authored
    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!
    ec58f8e3
usb-serial.c 41.4 KB