diff options
author | Navare, Manasi D <manasi.d.navare@intel.com> | 2016-09-27 16:36:53 -0700 |
---|---|---|
committer | Jani Nikula <jani.nikula@intel.com> | 2016-09-28 11:12:39 +0300 |
commit | 577c543005dbb809b7880ac17c3f760b20af60e2 (patch) | |
tree | 301b2f771a298d1e4dc09c28ab9ebc6b6f811d14 /drivers/gpu/drm/i915/intel_dp.c | |
parent | a04139c4cf289119cdfb6081af602f7a452fb7c2 (diff) | |
download | lwn-577c543005dbb809b7880ac17c3f760b20af60e2.tar.gz lwn-577c543005dbb809b7880ac17c3f760b20af60e2.zip |
drm/i915: Code cleanup to use dev_priv and INTEL_GEN
Replace dev with dev_priv and INTEL_INFO with INTEL_GEN
v1:
* Rebased on drm-nightly (Jani Nikula)
* Separated from the link training patch series
Signed-off-by: Manasi Navare <manasi.d.navare@intel.com>
Reviewed-by: Mika Kahola <mika.kahola@intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1475019413-19811-1-git-send-email-manasi.d.navare@intel.com
Diffstat (limited to 'drivers/gpu/drm/i915/intel_dp.c')
-rw-r--r-- | drivers/gpu/drm/i915/intel_dp.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c index 57da2b7510df..9448d898d80b 100644 --- a/drivers/gpu/drm/i915/intel_dp.c +++ b/drivers/gpu/drm/i915/intel_dp.c @@ -1297,10 +1297,10 @@ intel_dp_sink_rates(struct intel_dp *intel_dp, const int **sink_rates) bool intel_dp_source_supports_hbr2(struct intel_dp *intel_dp) { struct intel_digital_port *dig_port = dp_to_dig_port(intel_dp); - struct drm_device *dev = dig_port->base.base.dev; + struct drm_i915_private *dev_priv = to_i915(dig_port->base.base.dev); - if ((IS_HASWELL(dev) && !IS_HSW_ULX(dev)) || IS_BROADWELL(dev) || - (INTEL_INFO(dev)->gen >= 9)) + if ((IS_HASWELL(dev_priv) && !IS_HSW_ULX(dev_priv)) || + IS_BROADWELL(dev_priv) || (INTEL_GEN(dev_priv) >= 9)) return true; else return false; @@ -1310,13 +1310,13 @@ static int intel_dp_source_rates(struct intel_dp *intel_dp, const int **source_rates) { struct intel_digital_port *dig_port = dp_to_dig_port(intel_dp); - struct drm_device *dev = dig_port->base.base.dev; + struct drm_i915_private *dev_priv = to_i915(dig_port->base.base.dev); int size; - if (IS_BROXTON(dev)) { + if (IS_BROXTON(dev_priv)) { *source_rates = bxt_rates; size = ARRAY_SIZE(bxt_rates); - } else if (IS_SKYLAKE(dev) || IS_KABYLAKE(dev)) { + } else if (IS_SKYLAKE(dev_priv) || IS_KABYLAKE(dev_priv)) { *source_rates = skl_rates; size = ARRAY_SIZE(skl_rates); } else { |