media: uvcvideo: Set the colorspace as sRGB if undefined
authorRicardo Ribalda <ribalda@chromium.org>
Fri, 12 Nov 2021 19:57:10 +0000 (20:57 +0100)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Tue, 7 Dec 2021 10:29:54 +0000 (11:29 +0100)
commite82822fae93ffc2b48362bfbcdef2ad00eaf944b
tree7559a033eb0fde2cd77c9c4a138df94d42ac613d
parent8aa637bf6d70d2fb2ad4d708d8b9dd02b1c095df
media: uvcvideo: Set the colorspace as sRGB if undefined

Never return V4L2_COLORSPACE_DEFAULT. From the standard:

"""
In the absence of this descriptor, or in the case of
“Unspecified” values within the descriptor, color matching
defaults will be assumed. The color matching defaults are
compliant with sRGB since the BT.709 transfer function and
the sRGB transfer function are very similar.
"""

Signed-off-by: Ricardo Ribalda <ribalda@chromium.org>
Tested-by: James Hilliard <james.hilliard1@gmail.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/usb/uvc/uvc_driver.c