summaryrefslogtreecommitdiff
path: root/drivers/hid/usbhid
diff options
context:
space:
mode:
authorUdipto Goswami <quic_ugoswami@quicinc.com>2023-01-24 12:11:49 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2023-02-09 13:28:14 +0300
commit3b1534f5bae79f8549e14d3193793b67745038a8 (patch)
treeb1a2b521ede051268ad3aed7917e58fee208c166 /drivers/hid/usbhid
parentf3ce160b301ca7180ec545d875e60e5369101f19 (diff)
downloadlinux-3b1534f5bae79f8549e14d3193793b67745038a8.tar.xz
usb: gadget: f_fs: Fix unbalanced spinlock in __ffs_ep0_queue_wait
[ Upstream commit 921deb9da15851425ccbb6ee409dc2fd8fbdfe6b ] __ffs_ep0_queue_wait executes holding the spinlock of &ffs->ev.waitq.lock and unlocks it after the assignments to usb_request are done. However in the code if the request is already NULL we bail out returning -EINVAL but never unlocked the spinlock. Fix this by adding spin_unlock_irq &ffs->ev.waitq.lock before returning. Fixes: 6a19da111057 ("usb: gadget: f_fs: Prevent race during ffs_ep0_queue_wait") Reviewed-by: John Keeping <john@metanate.com> Signed-off-by: Udipto Goswami <quic_ugoswami@quicinc.com> Link: https://lore.kernel.org/r/20230124091149.18647-1-quic_ugoswami@quicinc.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/hid/usbhid')
0 files changed, 0 insertions, 0 deletions