Commit 9877db7d authored by Ville Syrjälä's avatar Ville Syrjälä

drm/i915: Parametrize PFIT_PIPE

Make the PFIT_PIPE stuff less ugly via parametrization.
Signed-off-by: default avatarVille Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200212161738.28141-2-ville.syrjala@linux.intel.comReviewed-by: default avatarJani Nikula <jani.nikula@intel.com>
parent 5fb908eb
...@@ -434,8 +434,7 @@ void intel_gmch_panel_fitting(struct intel_crtc *intel_crtc, ...@@ -434,8 +434,7 @@ void intel_gmch_panel_fitting(struct intel_crtc *intel_crtc,
/* 965+ wants fuzzy fitting */ /* 965+ wants fuzzy fitting */
/* FIXME: handle multiple panels by failing gracefully */ /* FIXME: handle multiple panels by failing gracefully */
if (INTEL_GEN(dev_priv) >= 4) if (INTEL_GEN(dev_priv) >= 4)
pfit_control |= ((intel_crtc->pipe << PFIT_PIPE_SHIFT) | pfit_control |= PFIT_PIPE(intel_crtc->pipe) | PFIT_FILTER_FUZZY;
PFIT_FILTER_FUZZY);
out: out:
if ((pfit_control & PFIT_ENABLE) == 0) { if ((pfit_control & PFIT_ENABLE) == 0) {
......
...@@ -4928,6 +4928,7 @@ enum { ...@@ -4928,6 +4928,7 @@ enum {
#define PFIT_ENABLE (1 << 31) #define PFIT_ENABLE (1 << 31)
#define PFIT_PIPE_MASK (3 << 29) #define PFIT_PIPE_MASK (3 << 29)
#define PFIT_PIPE_SHIFT 29 #define PFIT_PIPE_SHIFT 29
#define PFIT_PIPE(pipe) ((pipe) << 29)
#define VERT_INTERP_DISABLE (0 << 10) #define VERT_INTERP_DISABLE (0 << 10)
#define VERT_INTERP_BILINEAR (1 << 10) #define VERT_INTERP_BILINEAR (1 << 10)
#define VERT_INTERP_MASK (3 << 10) #define VERT_INTERP_MASK (3 << 10)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment