From: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
To: "Ville Syrjälä" <ville.syrjala@linux.intel.com>,
"Rodrigo Vivi" <rodrigo.vivi@intel.com>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH v3 4/6] drm/i915/dp: Do not grab crtc modeset lock in intel_dp_detect()
Date: Mon, 01 Oct 2018 15:01:18 -0700 [thread overview]
Message-ID: <582e9d724154736dc40bdc04e56d70067ff01bc9.camel@intel.com> (raw)
In-Reply-To: <20181001201006.GP9144@intel.com>
On Mon, 2018-10-01 at 23:10 +0300, Ville Syrjälä wrote:
> On Mon, Oct 01, 2018 at 12:48:28PM -0700, Rodrigo Vivi wrote:
> > On Tue, Sep 25, 2018 at 07:54:22PM -0700, Dhinakaran Pandiyan
> > wrote:
> > > A crtc modeset lock was added for link retraining but
> > > intel_dp_retrain_link() knows to take the necessary locks since
> > > commit c85d200e8321 ("drm/i915: Move SST DP link retraining into
> > > the
> > > ->post_hotplug() hook")
> > > v2: Drop AUX power domain reference in the early return path
> > >
> > > Fixes: c85d200e8321 ("drm/i915: Move SST DP link retraining into
> > > the ->post_hotplug() hook")
> >
> > This patch failed on cherry-pick for drm-intel-fixes targeting
> > 4.19.
> >
> > If it still makes sense to have it there please provide a
> > backported version
> > to drm-intel-fixes or let me know if it has dependency on other
> > patches?
>
> This is more of an optimization to not disturb page flips and whatnot
> so much with detect. The double lock is otherwise harmless due to
> ww_mutex.
>
Yeah, let's not backport this.
-DK
> >
> > Thanks,
> > Rodrigo.
> >
> > > Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > > Signed-off-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com
> > > >
> > > ---
> > > drivers/gpu/drm/i915/intel_dp.c | 24 ++++++++++--------------
> > > 1 file changed, 10 insertions(+), 14 deletions(-)
> > >
> > > diff --git a/drivers/gpu/drm/i915/intel_dp.c
> > > b/drivers/gpu/drm/i915/intel_dp.c
> > > index 09229fc66dec..ef28cc0f122c 100644
> > > --- a/drivers/gpu/drm/i915/intel_dp.c
> > > +++ b/drivers/gpu/drm/i915/intel_dp.c
> > > @@ -5079,8 +5079,15 @@ intel_dp_long_pulse(struct intel_connector
> > > *connector,
> > > * Some external monitors do not signal loss of link
> > > synchronization
> > > * with an IRQ_HPD, so force a link status check.
> > > */
> > > - if (!intel_dp_is_edp(intel_dp))
> > > - intel_dp_retrain_link(encoder, ctx);
> > > + if (!intel_dp_is_edp(intel_dp)) {
> > > + int ret;
> > > +
> > > + ret = intel_dp_retrain_link(encoder, ctx);
> > > + if (ret) {
> > > + intel_display_power_put(dev_priv, intel_dp-
> > > >aux_power_domain);
> > > + return ret;
> > > + }
> > > + }
> > >
> > > /*
> > > * Clearing NACK and defer counts to get their exact values
> > > @@ -5130,19 +5137,8 @@ intel_dp_detect(struct drm_connector
> > > *connector,
> > > connector->base.id, connector->name);
> > >
> > > /* If full detect is not performed yet, do a full detect */
> > > - if (!intel_dp->detect_done) {
> > > - struct drm_crtc *crtc;
> > > - int ret;
> > > -
> > > - crtc = connector->state->crtc;
> > > - if (crtc) {
> > > - ret = drm_modeset_lock(&crtc->mutex, ctx);
> > > - if (ret)
> > > - return ret;
> > > - }
> > > -
> > > + if (!intel_dp->detect_done)
> > > status = intel_dp_long_pulse(intel_dp-
> > > >attached_connector, ctx);
> > > - }
> > >
> > > intel_dp->detect_done = false;
> > >
> > > --
> > > 2.14.1
> > >
> > > _______________________________________________
> > > Intel-gfx mailing list
> > > Intel-gfx@lists.freedesktop.org
> > > https://lists.freedesktop.org/mailman/listinfo/intel-gfx
> >
> > _______________________________________________
> > Intel-gfx mailing list
> > Intel-gfx@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/intel-gfx
>
>
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2018-10-01 22:01 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-24 22:45 [PATCH v2 1/6] drm/i915/dp: Fix link retraining comment in intel_dp_long_pulse() Dhinakaran Pandiyan
2018-09-24 22:45 ` [PATCH v2 2/6] drm/i915/dp: Restrict link retrain workaround to external monitors Dhinakaran Pandiyan
2018-10-01 19:49 ` Rodrigo Vivi
2018-10-01 22:00 ` Dhinakaran Pandiyan
2018-10-02 0:30 ` Dhinakaran Pandiyan
2018-10-23 11:56 ` Jani Nikula
2018-10-24 10:49 ` Joonas Lahtinen
2018-10-01 22:30 ` Lyude Paul
2018-09-24 22:45 ` [PATCH v2 3/6] drm/i915/dp: Use a local variable for intel_encoder * Dhinakaran Pandiyan
2018-09-25 20:51 ` Souza, Jose
2018-09-24 22:45 ` [PATCH v2 4/6] drm/i915/dp: Do not grab crtc modeset lock in intel_dp_detect() Dhinakaran Pandiyan
2018-09-25 20:58 ` Souza, Jose
2018-09-26 2:54 ` [PATCH v3 " Dhinakaran Pandiyan
2018-10-01 19:48 ` Rodrigo Vivi
2018-10-01 20:10 ` Ville Syrjälä
2018-10-01 22:01 ` Dhinakaran Pandiyan [this message]
2018-10-01 23:22 ` Rodrigo Vivi
2018-09-24 22:45 ` [PATCH v2 5/6] drm/i915/dp: Kill intel_dp->detect_done flag Dhinakaran Pandiyan
2018-09-25 17:53 ` Ville Syrjälä
2018-09-26 2:31 ` Dhinakaran Pandiyan
2018-09-24 22:45 ` [PATCH v2 6/6] drm/i915/dp: Fix duplication of DEVICE_SERVICE_IRQ handling Dhinakaran Pandiyan
2018-09-25 21:01 ` Souza, Jose
2018-09-24 23:47 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [v2,1/6] drm/i915/dp: Fix link retraining comment in intel_dp_long_pulse() Patchwork
2018-09-25 0:08 ` ✗ Fi.CI.BAT: failure " Patchwork
2018-09-25 6:33 ` Patchwork
2018-09-26 2:08 ` [PATCH v3 4/6] drm/i915/dp: Do not grab crtc modeset lock in intel_dp_detect() Dhinakaran Pandiyan
2018-09-26 3:18 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [v2,1/6] drm/i915/dp: Fix link retraining comment in intel_dp_long_pulse() (rev2) Patchwork
2018-09-26 3:41 ` ✓ Fi.CI.BAT: success " Patchwork
2018-09-26 4:32 ` ✓ Fi.CI.IGT: " Patchwork
2018-10-01 22:30 ` [PATCH v2 1/6] drm/i915/dp: Fix link retraining comment in intel_dp_long_pulse() Lyude Paul
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=582e9d724154736dc40bdc04e56d70067ff01bc9.camel@intel.com \
--to=dhinakaran.pandiyan@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=rodrigo.vivi@intel.com \
--cc=ville.syrjala@linux.intel.com \
/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