diff options
author | Dave Airlie <airlied@redhat.com> | 2017-10-05 21:09:29 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2017-10-05 21:09:29 -0400 |
commit | 00bb09c45cf168c89b93fc3f92c84a1c3236f120 (patch) | |
tree | b65600933ffac25dca7c5ba5bbba5ec7c98fa02a | |
parent | 1b0e19bb0c6f6b209c6b711f47dfc81812706827 (diff) | |
parent | 069d40f5834ad26a58f269225a7e13af17019062 (diff) |
Merge tag 'drm-intel-fixes-2017-10-04' of git://anongit.freedesktop.org/git/drm-intel into drm-fixes
drm/i915 fixes for 4.14-rc4:
All 3 highest GLK bugs fixed by Imre:
- GLK drv reload - Fix DDI Phy init if it was already on.
- GLK suspend resume - Reprogram DMC firmware after s3/s4.
- GLK DC states - Fix idleness calculation.
* tag 'drm-intel-fixes-2017-10-04' of git://anongit.freedesktop.org/git/drm-intel:
drm/i915/glk: Fix DMC/DC state idleness calculation
drm/i915/cnl: Reprogram DMC firmware after S3/S4 resume
drm/i915: Fix DDI PHY init if it was already on
-rw-r--r-- | drivers/gpu/drm/i915/intel_csr.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/intel_ddi.c | 3 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/intel_dpio_phy.c | 20 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/intel_runtime_pm.c | 3 |
4 files changed, 6 insertions, 22 deletions
diff --git a/drivers/gpu/drm/i915/intel_csr.c b/drivers/gpu/drm/i915/intel_csr.c index 965988f79a55..92c1f8e166dc 100644 --- a/drivers/gpu/drm/i915/intel_csr.c +++ b/drivers/gpu/drm/i915/intel_csr.c | |||
@@ -216,7 +216,7 @@ static void gen9_set_dc_state_debugmask(struct drm_i915_private *dev_priv) | |||
216 | 216 | ||
217 | mask = DC_STATE_DEBUG_MASK_MEMORY_UP; | 217 | mask = DC_STATE_DEBUG_MASK_MEMORY_UP; |
218 | 218 | ||
219 | if (IS_BROXTON(dev_priv)) | 219 | if (IS_GEN9_LP(dev_priv)) |
220 | mask |= DC_STATE_DEBUG_MASK_CORES; | 220 | mask |= DC_STATE_DEBUG_MASK_CORES; |
221 | 221 | ||
222 | /* The below bit doesn't need to be cleared ever afterwards */ | 222 | /* The below bit doesn't need to be cleared ever afterwards */ |
diff --git a/drivers/gpu/drm/i915/intel_ddi.c b/drivers/gpu/drm/i915/intel_ddi.c index 4b4fd1f8110b..476681d5940c 100644 --- a/drivers/gpu/drm/i915/intel_ddi.c +++ b/drivers/gpu/drm/i915/intel_ddi.c | |||
@@ -1655,7 +1655,8 @@ bool intel_ddi_get_hw_state(struct intel_encoder *encoder, | |||
1655 | out: | 1655 | out: |
1656 | if (ret && IS_GEN9_LP(dev_priv)) { | 1656 | if (ret && IS_GEN9_LP(dev_priv)) { |
1657 | tmp = I915_READ(BXT_PHY_CTL(port)); | 1657 | tmp = I915_READ(BXT_PHY_CTL(port)); |
1658 | if ((tmp & (BXT_PHY_LANE_POWERDOWN_ACK | | 1658 | if ((tmp & (BXT_PHY_CMNLANE_POWERDOWN_ACK | |
1659 | BXT_PHY_LANE_POWERDOWN_ACK | | ||
1659 | BXT_PHY_LANE_ENABLED)) != BXT_PHY_LANE_ENABLED) | 1660 | BXT_PHY_LANE_ENABLED)) != BXT_PHY_LANE_ENABLED) |
1660 | DRM_ERROR("Port %c enabled but PHY powered down? " | 1661 | DRM_ERROR("Port %c enabled but PHY powered down? " |
1661 | "(PHY_CTL %08x)\n", port_name(port), tmp); | 1662 | "(PHY_CTL %08x)\n", port_name(port), tmp); |
diff --git a/drivers/gpu/drm/i915/intel_dpio_phy.c b/drivers/gpu/drm/i915/intel_dpio_phy.c index 09b670929786..de38d014ed39 100644 --- a/drivers/gpu/drm/i915/intel_dpio_phy.c +++ b/drivers/gpu/drm/i915/intel_dpio_phy.c | |||
@@ -208,12 +208,6 @@ static const struct bxt_ddi_phy_info glk_ddi_phy_info[] = { | |||
208 | }, | 208 | }, |
209 | }; | 209 | }; |
210 | 210 | ||
211 | static u32 bxt_phy_port_mask(const struct bxt_ddi_phy_info *phy_info) | ||
212 | { | ||
213 | return (phy_info->dual_channel * BIT(phy_info->channel[DPIO_CH1].port)) | | ||
214 | BIT(phy_info->channel[DPIO_CH0].port); | ||
215 | } | ||
216 | |||
217 | static const struct bxt_ddi_phy_info * | 211 | static const struct bxt_ddi_phy_info * |
218 | bxt_get_phy_list(struct drm_i915_private *dev_priv, int *count) | 212 | bxt_get_phy_list(struct drm_i915_private *dev_priv, int *count) |
219 | { | 213 | { |
@@ -313,7 +307,6 @@ bool bxt_ddi_phy_is_enabled(struct drm_i915_private *dev_priv, | |||
313 | enum dpio_phy phy) | 307 | enum dpio_phy phy) |
314 | { | 308 | { |
315 | const struct bxt_ddi_phy_info *phy_info; | 309 | const struct bxt_ddi_phy_info *phy_info; |
316 | enum port port; | ||
317 | 310 | ||
318 | phy_info = bxt_get_phy_info(dev_priv, phy); | 311 | phy_info = bxt_get_phy_info(dev_priv, phy); |
319 | 312 | ||
@@ -335,19 +328,6 @@ bool bxt_ddi_phy_is_enabled(struct drm_i915_private *dev_priv, | |||
335 | return false; | 328 | return false; |
336 | } | 329 | } |
337 | 330 | ||
338 | for_each_port_masked(port, bxt_phy_port_mask(phy_info)) { | ||
339 | u32 tmp = I915_READ(BXT_PHY_CTL(port)); | ||
340 | |||
341 | if (tmp & BXT_PHY_CMNLANE_POWERDOWN_ACK) { | ||
342 | DRM_DEBUG_DRIVER("DDI PHY %d powered, but common lane " | ||
343 | "for port %c powered down " | ||
344 | "(PHY_CTL %08x)\n", | ||
345 | phy, port_name(port), tmp); | ||
346 | |||
347 | return false; | ||
348 | } | ||
349 | } | ||
350 | |||
351 | return true; | 331 | return true; |
352 | } | 332 | } |
353 | 333 | ||
diff --git a/drivers/gpu/drm/i915/intel_runtime_pm.c b/drivers/gpu/drm/i915/intel_runtime_pm.c index b66d8e136aa3..b3a087cb0860 100644 --- a/drivers/gpu/drm/i915/intel_runtime_pm.c +++ b/drivers/gpu/drm/i915/intel_runtime_pm.c | |||
@@ -2782,6 +2782,9 @@ static void cnl_display_core_init(struct drm_i915_private *dev_priv, bool resume | |||
2782 | 2782 | ||
2783 | /* 6. Enable DBUF */ | 2783 | /* 6. Enable DBUF */ |
2784 | gen9_dbuf_enable(dev_priv); | 2784 | gen9_dbuf_enable(dev_priv); |
2785 | |||
2786 | if (resume && dev_priv->csr.dmc_payload) | ||
2787 | intel_csr_load_program(dev_priv); | ||
2785 | } | 2788 | } |
2786 | 2789 | ||
2787 | #undef CNL_PROCMON_IDX | 2790 | #undef CNL_PROCMON_IDX |