drm/i915: Provide a device level .mode_valid() hook
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Tue, 14 Nov 2017 18:32:58 +0000 (20:32 +0200)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Mon, 29 Jan 2018 19:55:07 +0000 (21:55 +0200)
commite995ca0b8139c5f6807095464e969931b443f55a
treed08d7fd4f0bb93e7414ae2b4ce16a974296cf429
parent75a655e0a26cf0bfbaaa8df0ff5a9d1807bb1f4e
drm/i915: Provide a device level .mode_valid() hook

We never support certain mode flags etc. Reject those early on in the
mode_config.mode_valid() hook. That allows us to remove some duplicated
checks from the connector .mode_valid() hooks, and it guarantees that
we never see those flags even from user mode as the
mode_config.mode_valid() hooks gets executed for those as well.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20171114183258.16976-11-ville.syrjala@linux.intel.com
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/intel_crt.c
drivers/gpu/drm/i915/intel_display.c
drivers/gpu/drm/i915/intel_dsi.c
drivers/gpu/drm/i915/intel_dvo.c
drivers/gpu/drm/i915/intel_fbc.c
drivers/gpu/drm/i915/intel_hdmi.c
drivers/gpu/drm/i915/intel_sdvo.c