From: Imre Deak <imre.deak@intel.com>
To: intel-gfx@lists.freedesktop.org
Subject: [PATCH 1/2] drm/i915: Clear the shared PLL from the put_dplls() hook
Date: Fri, 5 Jul 2019 17:04:22 +0300 [thread overview]
Message-ID: <20190705140423.28404-1-imre.deak@intel.com> (raw)
For symmetry with the get_dplls() hook which sets the shared_dpll
pointer clear the same pointer from the put_dplls() hook.
Signed-off-by: Imre Deak <imre.deak@intel.com>
---
drivers/gpu/drm/i915/display/intel_display.c | 2 --
drivers/gpu/drm/i915/display/intel_dpll_mgr.c | 18 +++++++++++++-----
2 files changed, 13 insertions(+), 7 deletions(-)
diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
index 919f5ac844c8..280e0f1b7005 100644
--- a/drivers/gpu/drm/i915/display/intel_display.c
+++ b/drivers/gpu/drm/i915/display/intel_display.c
@@ -13285,8 +13285,6 @@ static void intel_modeset_clear_plls(struct intel_atomic_state *state)
if (!needs_modeset(new_crtc_state))
continue;
- new_crtc_state->shared_dpll = NULL;
-
intel_release_shared_dplls(state, crtc);
}
}
diff --git a/drivers/gpu/drm/i915/display/intel_dpll_mgr.c b/drivers/gpu/drm/i915/display/intel_dpll_mgr.c
index f953971e7c3b..722b1deca999 100644
--- a/drivers/gpu/drm/i915/display/intel_dpll_mgr.c
+++ b/drivers/gpu/drm/i915/display/intel_dpll_mgr.c
@@ -323,13 +323,17 @@ static void intel_unreference_shared_dpll(struct intel_atomic_state *state,
static void intel_put_dpll(struct intel_atomic_state *state,
struct intel_crtc *crtc)
{
- struct intel_crtc_state *crtc_state =
+ struct intel_crtc_state *old_crtc_state =
intel_atomic_get_old_crtc_state(state, crtc);
+ struct intel_crtc_state *new_crtc_state =
+ intel_atomic_get_new_crtc_state(state, crtc);
+
+ new_crtc_state->shared_dpll = NULL;
- if (!crtc_state->shared_dpll)
+ if (!old_crtc_state->shared_dpll)
return;
- intel_unreference_shared_dpll(state, crtc, crtc_state->shared_dpll);
+ intel_unreference_shared_dpll(state, crtc, old_crtc_state->shared_dpll);
}
/**
@@ -3008,13 +3012,17 @@ static bool icl_get_dplls(struct intel_atomic_state *state,
static void icl_put_dplls(struct intel_atomic_state *state,
struct intel_crtc *crtc)
{
- struct intel_crtc_state *crtc_state =
+ struct intel_crtc_state *old_crtc_state =
intel_atomic_get_old_crtc_state(state, crtc);
+ struct intel_crtc_state *new_crtc_state =
+ intel_atomic_get_new_crtc_state(state, crtc);
enum icl_port_dpll_id id;
+ new_crtc_state->shared_dpll = NULL;
+
for (id = ICL_PORT_DPLL_DEFAULT; id < ICL_PORT_DPLL_COUNT; id++) {
struct icl_port_dpll *port_dpll =
- &crtc_state->icl_port_dplls[id];
+ &old_crtc_state->icl_port_dplls[id];
if (!port_dpll->pll)
continue;
--
2.17.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next reply other threads:[~2019-07-05 14:04 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-05 14:04 Imre Deak [this message]
2019-07-05 14:04 ` [PATCH 2/2] drm/i915/icl: Clear the shared port PLLs from the new crtc state Imre Deak
2019-07-08 13:16 ` Ville Syrjälä
2019-07-05 15:44 ` ✓ Fi.CI.BAT: success for series starting with [1/2] drm/i915: Clear the shared PLL from the put_dplls() hook Patchwork
2019-07-07 2:42 ` ✓ Fi.CI.IGT: " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190705140423.28404-1-imre.deak@intel.com \
--to=imre.deak@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox