linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Boyd <swboyd@chromium.org>
To: khsieh@codeaurora.org
Cc: robdclark@gmail.com, sean@poorly.run, abhinavk@codeaurora.org,
	aravindh@codeaurora.org, airlied@linux.ie, daniel@ffwll.ch,
	linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org,
	freedreno@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 3/3] drm/msm/dp: check main link status before start aux read
Date: Thu, 15 Apr 2021 15:46:59 -0700	[thread overview]
Message-ID: <161852681935.46595.9941294298184495830@swboyd.mtv.corp.google.com> (raw)
In-Reply-To: <78036f23979206070bd9c9df180e2866@codeaurora.org>

Quoting khsieh@codeaurora.org (2021-04-15 15:02:40)
> On 2021-04-15 13:06, Stephen Boyd wrote:
> > 
> > Is it really necessary to have this patch at all? I think there are
> > bigger problems with suspend/resume of the DP driver in relation to the
> > kthread stopping. I hope that the aux channel would start NAKing
> > transfers once the cable is disconnected too, so that we don't need to
> > do an extra check for each aux transfer.
> 
> I am working on duplicate this problem, but it is not happen on me yet 
> so far.
>  From kernel dump, i can see it crash at dp_irq_hdp_handle() after 
> suspended.
> dp_irq_hpd_handle and dp_pm_suspend() are serialized by event_mutex.
> 
> After suspend, ahb clock is disabled.
> Hence next dp_catalog_link_is_connected() crash at acess dp ctrl 
> registers.
> 
> 
> aux channel does not do NAKing immediately if unplugged. Therefore 
> aux_transfer will wait until timeout (HZ/4).
> worst, drm_dp_dpcd_access() will retry 32 times before return dpcd 
> read/write failed.
> This patch try to eliminate the time spinning on waiting for timeout 32 
> times.
> 

Would be useful to have that level of detail in the commit text.

Maybe when the cable is disconnected the DP phy should be shutdown and
some bit in the phy could effectively "cut off" the aux channel and then
NAKs would start coming through here in the DP controller I/O register
space?

  reply	other threads:[~2021-04-15 22:47 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-13 23:11 [PATCH v2 3/3] drm/msm/dp: check main link status before start aux read Kuogee Hsieh
2021-04-14 21:09 ` Stephen Boyd
2021-04-15 17:37   ` khsieh
2021-04-15 20:06     ` Stephen Boyd
2021-04-15 22:02       ` khsieh
2021-04-15 22:46         ` Stephen Boyd [this message]
2021-04-15 23:28           ` [PATCH v3 " Kuogee Hsieh

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=161852681935.46595.9941294298184495830@swboyd.mtv.corp.google.com \
    --to=swboyd@chromium.org \
    --cc=abhinavk@codeaurora.org \
    --cc=airlied@linux.ie \
    --cc=aravindh@codeaurora.org \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=freedreno@lists.freedesktop.org \
    --cc=khsieh@codeaurora.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robdclark@gmail.com \
    --cc=sean@poorly.run \
    /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;
as well as URLs for NNTP newsgroup(s).