]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
usb: gadget: uvc: mark incomplete frames with UVC_STREAM_ERR
authorMichael Grzeschik <m.grzeschik@pengutronix.de>
Tue, 13 Feb 2024 23:37:55 +0000 (00:37 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 13 Apr 2024 11:07:38 +0000 (13:07 +0200)
commit0d52e1853bc1a7b0c5b428653688bf667a570afb
treec3942854f793c54a9cf266e526e4955ad6af1ced
parent4b1f991bad566de14ae79bca952d201189cada52
usb: gadget: uvc: mark incomplete frames with UVC_STREAM_ERR

[ Upstream commit 2a3b7af120477d0571b815ccb8600cafd5ebf02f ]

If an frame was transmitted incomplete to the host, we set the
UVC_STREAM_ERR bit in the header for the last request that is going
to be queued. This way the host will know that it should drop the
frame instead of trying to display the corrupted content.

Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de>
Link: https://lore.kernel.org/r/20240214-uvc-error-tag-v1-2-37659a3877fe@pengutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/usb/gadget/function/uvc_video.c