]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
usb: musb: fix PM reference leak in musb_irq_work()
authorBixuan Cui <cuibixuan@huawei.com>
Thu, 8 Apr 2021 09:18:36 +0000 (17:18 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 9 Apr 2021 14:02:44 +0000 (16:02 +0200)
commit9535b99533904e9bc1607575aa8e9539a55435d7
treebcc21045eeafc1e797bc1eaa9904521775734a3b
parenta932ee40c276767cd55fadec9e38829bf441db41
usb: musb: fix PM reference leak in musb_irq_work()

pm_runtime_get_sync will increment pm usage counter even it failed.
thus a pairing decrement is needed.
Fix it by replacing it with pm_runtime_resume_and_get to keep usage
counter balanced.

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Bixuan Cui <cuibixuan@huawei.com>
Link: https://lore.kernel.org/r/20210408091836.55227-1-cuibixuan@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/musb/musb_core.c