]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
USB: serial: suppress driver bind attributes
authorJohan Hovold <johan@kernel.org>
Thu, 16 Jan 2020 16:07:05 +0000 (17:07 +0100)
committerKhalid Elmously <khalid.elmously@canonical.com>
Fri, 14 Feb 2020 05:29:37 +0000 (00:29 -0500)
commit04a02c6c64ea6a314489b215ce038e1d13227c27
treed6fc506759b06651124a4c51dc25ded41b59ef11
parentadf5a112411f692fb7d1043f88a7d604b65bbd13
USB: serial: suppress driver bind attributes

BugLink: https://bugs.launchpad.net/bugs/1862259
commit fdb838efa31e1ed9a13ae6ad0b64e30fdbd00570 upstream.

USB-serial drivers must not be unbound from their ports before the
corresponding USB driver is unbound from the parent interface so
suppress the bind and unbind attributes.

Unbinding a serial driver while it's port is open is a sure way to
trigger a crash as any driver state is released on unbind while port
hangup is handled on the parent USB interface level. Drivers for
multiport devices where ports share a resource such as an interrupt
endpoint also generally cannot handle individual ports going away.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Cc: stable <stable@vger.kernel.org>
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
drivers/usb/serial/usb-serial.c