Fix oopses with usb-serial devices (2.6.0-test4)
Subsystems (2)
PATCH 1/1 Fix oopses with usb-serial devices (2.6.0-test4)
Hi,
Below is a small patch that fixes the oops that happens in the latest 2.6 kernels when you plug in a keyspan or whiteheat usb to serial device. Thanks to Ben for pointing out that there is a problem, and to Pat for finding where the problem was (in my code, not his :)
I'll be sending it on to Linus next week, but here is is for those people who want to use their devices again.
thanks,
greg k-h
# USB: fix oops in keyspan and whiteheat devices when plugged in.
drivers/usb/serial/usb-serial.c +2 -1
@@ -871,7 +871,8 @@/* the ports are cleaned up and released in port_release() */ for (i =0 ; i < serial->num_ports; ++i) -device_unregister (&serial->port[i]->dev); +if (serial->port[i]->dev.parent !=NULL ) +device_unregister (&serial->port[i]->dev);/* If this is a "fake" port, we have to clean it up here, as it will * not get cleaned up in port_release() as it was never registered with