diff options
author | Ville Syrjälä | 2016-06-22 20:57:02 +0200 |
---|---|---|
committer | Ville Syrjälä | 2016-07-07 12:08:25 +0200 |
commit | 2d84d2b367541fa59855e9df20b1f077d72a6fd2 (patch) | |
tree | 5c65a2a38202ac959644cd78e1f091cb54a34789 /drivers/gpu/drm/i915/intel_drv.h | |
parent | drm/i915: Add output_types bitmask into the crtc state (diff) | |
download | kernel-qcow2-linux-2d84d2b367541fa59855e9df20b1f077d72a6fd2.tar.gz kernel-qcow2-linux-2d84d2b367541fa59855e9df20b1f077d72a6fd2.tar.xz kernel-qcow2-linux-2d84d2b367541fa59855e9df20b1f077d72a6fd2.zip |
drm/i915: Unify intel_pipe_has_type() and intel_pipe_will_have_type()
With the introduction of the output_types mask, intel_pipe_has_type()
and intel_pipe_will_have_type() are basically the same thing. Replace
them with a new intel_crtc_has_type() (identical to
intel_pipe_will_have_type() actually).
v2: Rebase
v3: Make intel_crtc_has_type() static inline (Chris)
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> (v2)
Link: http://patchwork.freedesktop.org/patch/msgid/1466621833-5054-5-git-send-email-ville.syrjala@linux.intel.com
Diffstat (limited to 'drivers/gpu/drm/i915/intel_drv.h')
-rw-r--r-- | drivers/gpu/drm/i915/intel_drv.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h index 4d676d0baa87..f4710558150f 100644 --- a/drivers/gpu/drm/i915/intel_drv.h +++ b/drivers/gpu/drm/i915/intel_drv.h @@ -1192,7 +1192,12 @@ int intel_get_pipe_from_crtc_id(struct drm_device *dev, void *data, struct drm_file *file_priv); enum transcoder intel_pipe_to_cpu_transcoder(struct drm_i915_private *dev_priv, enum pipe pipe); -bool intel_pipe_has_type(struct intel_crtc *crtc, enum intel_output_type type); +static inline bool +intel_crtc_has_type(const struct intel_crtc_state *crtc_state, + enum intel_output_type type) +{ + return crtc_state->output_types & (1 << type); +} static inline void intel_wait_for_vblank(struct drm_device *dev, int pipe) { |