From e582b6c7e7f9d0b1e30e8017e4082d3a9ede3310 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Thu, 31 Mar 2016 18:38:20 -0700 Subject: drm/vc4: Add support for gamma ramps. We could possibly save a bit of power by not requesting gamma conversion when the ramp happens to be 1:1, but at least if all the CRTCs are off the SRAM will be disabled. This should fix brightness sliders in a lot of fullscreen games. Signed-off-by: Eric Anholt --- drivers/gpu/drm/vc4/vc4_regs.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'drivers/gpu/drm/vc4/vc4_regs.h') diff --git a/drivers/gpu/drm/vc4/vc4_regs.h b/drivers/gpu/drm/vc4/vc4_regs.h index bf42a8e87111..6163b95c5411 100644 --- a/drivers/gpu/drm/vc4/vc4_regs.h +++ b/drivers/gpu/drm/vc4/vc4_regs.h @@ -390,6 +390,12 @@ #define SCALER_DISPBASE2 0x0000006c #define SCALER_DISPALPHA2 0x00000070 #define SCALER_GAMADDR 0x00000078 +# define SCALER_GAMADDR_AUTOINC BIT(31) +/* Enables all gamma ramp SRAMs, not just those of CRTCs with gamma + * enabled. + */ +# define SCALER_GAMADDR_SRAMENB BIT(30) + #define SCALER_GAMDATA 0x000000e0 #define SCALER_DLIST_START 0x00002000 #define SCALER_DLIST_SIZE 0x00004000 -- cgit v1.2.3