]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
USB: usblp: fix use-after-free on disconnect
authorJohan Hovold <johan@kernel.org>
Tue, 15 Oct 2019 17:55:22 +0000 (19:55 +0200)
committerStefan Bader <stefan.bader@canonical.com>
Tue, 12 Nov 2019 18:04:44 +0000 (19:04 +0100)
commit920e658e6d8e48ec01e4efb06efa13a983c681cb
tree3b7df311c79934c4db5b7e967b304748ca2fa2e5
parenta978791912eea49b9d5c0c061db02b37b30e1195
USB: usblp: fix use-after-free on disconnect

BugLink: https://bugs.launchpad.net/bugs/1851876
commit 7a759197974894213621aa65f0571b51904733d6 upstream.

A recent commit addressing a runtime PM use-count regression, introduced
a use-after-free by not making sure we held a reference to the struct
usb_interface for the lifetime of the driver data.

Fixes: 9a31535859bf ("USB: usblp: fix runtime PM after driver unbind")
Cc: stable <stable@vger.kernel.org>
Reported-by: syzbot+cd24df4d075c319ebfc5@syzkaller.appspotmail.com
Signed-off-by: Johan Hovold <johan@kernel.org>
Link: https://lore.kernel.org/r/20191015175522.18490-1-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/class/usblp.c