Commit a1475e77 authored by Maarten Lankhorst's avatar Maarten Lankhorst

drm/i915: Perform dpll commit first, v2.

Warn for the wrong mask in enable only. Disable will have the wrong mask now
because the new state is committed before disabling the old state.

Changes since v1:
- Use crtc_mask (Durgadoss)
- Rebase.
Signed-off-by: default avatarMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1457944075-14123-3-git-send-email-maarten.lankhorst@linux.intel.comReviewed-by: default avatarAnder Conselvan de Oliveira <conselvan2@gmail.com>
parent 2dd66ebd
...@@ -13525,7 +13525,8 @@ static int intel_atomic_commit(struct drm_device *dev, ...@@ -13525,7 +13525,8 @@ static int intel_atomic_commit(struct drm_device *dev,
} }
drm_atomic_helper_swap_state(dev, state); drm_atomic_helper_swap_state(dev, state);
dev_priv->wm.config = to_intel_atomic_state(state)->wm_config; dev_priv->wm.config = intel_state->wm_config;
intel_shared_dpll_commit(state);
if (intel_state->modeset) { if (intel_state->modeset) {
memcpy(dev_priv->min_pixclk, intel_state->min_pixclk, memcpy(dev_priv->min_pixclk, intel_state->min_pixclk,
...@@ -13577,8 +13578,6 @@ static int intel_atomic_commit(struct drm_device *dev, ...@@ -13577,8 +13578,6 @@ static int intel_atomic_commit(struct drm_device *dev,
intel_modeset_update_crtc_state(state); intel_modeset_update_crtc_state(state);
if (intel_state->modeset) { if (intel_state->modeset) {
intel_shared_dpll_commit(state);
drm_atomic_helper_update_legacy_modeset_state(state->dev, state); drm_atomic_helper_update_legacy_modeset_state(state->dev, state);
if (dev_priv->display.modeset_commit_cdclk && if (dev_priv->display.modeset_commit_cdclk &&
......
...@@ -156,7 +156,7 @@ void intel_disable_shared_dpll(struct intel_crtc *crtc) ...@@ -156,7 +156,7 @@ void intel_disable_shared_dpll(struct intel_crtc *crtc)
if (pll == NULL) if (pll == NULL)
return; return;
if (WARN_ON(!(pll->config.crtc_mask & crtc_mask))) if (WARN_ON(!(pll->active_mask & crtc_mask)))
return; return;
DRM_DEBUG_KMS("disable %s (active %x, on? %d) for crtc %d\n", DRM_DEBUG_KMS("disable %s (active %x, on? %d) for crtc %d\n",
......
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