[RFC 1/3] drm/i915: Add Dark screen detection registers

Jani Nikula jani.nikula at linux.intel.com
Wed Apr 24 09:05:26 UTC 2024


On Wed, 24 Apr 2024, Suraj Kandpal <suraj.kandpal at intel.com> wrote:
> Add Dark screen detection related register and field definitions.

It's time we stopped adding *any* new display registers to i915_reg.h.

BR,
Jani.

>
> Signed-off-by: Suraj Kandpal <suraj.kandpal at intel.com>
> Signed-off-by: Nemesa Garg <nemesa.garg at intel.com>
> ---
>  drivers/gpu/drm/i915/i915_reg.h | 8 ++++++++
>  1 file changed, 8 insertions(+)
>
> diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
> index 8eb6c2bf4557..474b1c263517 100644
> --- a/drivers/gpu/drm/i915/i915_reg.h
> +++ b/drivers/gpu/drm/i915/i915_reg.h
> @@ -1838,6 +1838,14 @@
>  #define VRR_VSYNC_START_MASK		REG_GENMASK(12, 0)
>  #define VRR_VSYNC_START(vsync_start)	REG_FIELD_PREP(VRR_VSYNC_START_MASK, (vsync_start))
>  
> +#define _DARK_SCREEN_PIPE_A		0x60120
> +#define DARK_SCREEN(trans)		_MMIO_TRANS2(trans, _DARK_SCREEN_PIPE_A)
> +#define   DARK_SCREEN_ENABLE		REG_BIT(31)
> +#define   DARK_SCREEN_DETECT		REG_BIT(29)
> +#define   DARK_SCREEN_DONE		REG_BIT(28)
> +#define DARK_SCREEN_COMPARE_MASK	REG_GENMASK(9, 0)
> +#define DARK_SCREEN_COMPARE_VAL(x)	REG_FIELD_PREP(DARK_SCREEN_COMPARE_MASK, (x))
> +
>  /* VGA port control */
>  #define ADPA			_MMIO(0x61100)
>  #define PCH_ADPA                _MMIO(0xe1100)

-- 
Jani Nikula, Intel


More information about the Intel-gfx mailing list