drm/rockchip: add support for gamma table
authorMark Yao <mark.yao@rock-chips.com>
Mon, 27 Apr 2015 18:39:35 +0000 (11:39 -0700)
committerHuang, Tao <huangtao@rock-chips.com>
Thu, 11 May 2017 07:31:04 +0000 (15:31 +0800)
commit4a361fa5d433dabe64b0fae49b49c0fcd16982fa
tree69d5fafaef7fa28f7a01ac051213a0c1a1afec50
parent0a22588c5e68ea8a3da6310cca0f1f761227726a
drm/rockchip: add support for gamma table

Introduce support for rockchip gamma table,

Rockchip have two version gamma table design:
The old version design was introduced by Dominik Behr's gamma patch
(https://chromium-review.googlesource.com/272209):
 Gamma table has to be uploaded when the LUT is disabled which only takes
 effect at the end of a frame, therefore actual hardware updates is done
 from a worker and can take more than one frame.

In order to solve gamma table switch issues, after rk3399,
H/W add a gamma table update mechanism, can update without lut disable.

And gamma table's size also has two version:
  one is 10 bit per component, 1024 entries,
  the other one is 8 bit per component, 256 entries

Change-Id: I8145d1c42a28d57f11e95d24be2341011360334d
Signed-off-by: Dominik Behr <dbehr@chromium.org>
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
drivers/gpu/drm/rockchip/rockchip_drm_fbdev.c
drivers/gpu/drm/rockchip/rockchip_drm_fbdev.h
drivers/gpu/drm/rockchip/rockchip_drm_vop.c
drivers/gpu/drm/rockchip/rockchip_drm_vop.h
drivers/gpu/drm/rockchip/rockchip_vop_reg.c
drivers/gpu/drm/rockchip/rockchip_vop_reg.h