]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
[media] adv7604/adv7842: fix quantization range handling
authorHans Verkuil <hans.verkuil@cisco.com>
Tue, 28 Jun 2016 14:43:01 +0000 (11:43 -0300)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Tue, 12 Jul 2016 16:35:46 +0000 (13:35 -0300)
commitfd74246d2ade37cd477178652448410a35bdaca0
treedff71bf9820163b116acb8fb99bff332ccc1432c
parent0a25a0125194639507cf24319d02f5de63d182b5
[media] adv7604/adv7842: fix quantization range handling

Fix a number of bugs that appeared when support for mediabus formats was
added:

- Support for V4L2_DV_RGB_RANGE_FULL/LIMITED should only be enabled
  for HDMI RGB formats, not for YCbCr formats. Since, as the name
  says, this setting is for RGB only. So read the InfoFrame to check
  the format.

- the quantization range for the pixelport depends on whether the
  mediabus code is RGB or not: if it is RGB, then produce full range
  RGB values, otherwise produce limited range YCbCr values.

  This means that the op_656_range and alt_data_sat fields of the
  platform data are no longer used and these will be removed in a
  following patch.

- when setting up a new format the RGB quantization range settings
  were never updated. Do so, since this depends on the format.

- fix the log_status output which was confusing and incorrect.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
drivers/media/i2c/adv7604.c
drivers/media/i2c/adv7842.c