drm/connector: Add helper to compare HDR metadata
authorMaxime Ripard <maxime@cerno.tech>
Fri, 19 Mar 2021 12:05:53 +0000 (13:05 +0100)
committerpopcornmix <popcornmix@gmail.com>
Mon, 12 Apr 2021 17:08:50 +0000 (18:08 +0100)
commit6bd46342fadfdfb0a40d674f9161104f2e691873
tree5360f758a69d4425f683866e5051b140cce6e1a3
parent8debbd4e09a9c24732ff23a80a50ecfcb0bdc05a
drm/connector: Add helper to compare HDR metadata

All the drivers that support the HDR metadata property have a similar
function to compare the metadata from one connector state to the next,
and force a mode change if they differ.

All these functions run pretty much the same code, so let's turn it into
an helper that can be shared across those drivers.

Signed-off-by: Maxime Ripard <maxime@cerno.tech>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
drivers/gpu/drm/drm_connector.c
drivers/gpu/drm/i915/display/intel_atomic.c
include/drm/drm_connector.h