All of lore.kernel.org
 help / color / mirror / Atom feed
From: khsieh@codeaurora.org
To: Stephen Boyd <swboyd@chromium.org>
Cc: agross@kernel.org, bjorn.andersson@linaro.org,
	robdclark@gmail.com, sean@poorly.run, vkoul@kernel.org,
	abhinavk@codeaurora.org, aravindh@codeaurora.org,
	linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4 1/2] drm/msm/dp: handle irq_hpd with sink_count = 0 correctly
Date: Fri, 21 May 2021 12:45:35 -0700	[thread overview]
Message-ID: <fc6542f2e760fa92aef73fdb9a789b2d@codeaurora.org> (raw)
In-Reply-To: <CAE-0n50BOV6UofBzqqb+KzcOR7W=h3VD2g4CzeqB6+a0v-aZUQ@mail.gmail.com>

On 2021-05-21 12:18, Stephen Boyd wrote:
> Quoting khsieh@codeaurora.org (2021-05-21 08:21:58)
>> >
>> > Ok. So you're saying that we want to put both events on the queue
>> > regardless, and put IRQ_HPD there first because we want to check the
>> > status bit? Doesn't reading the status bit require the dongle to be
>> > connected though? So if an unplug came in along with an irq_hpd we may
>> > queue both the irq_hpd and the unplug, but when it comes time to
>> > process
>> > the irq_hpd in the kthread the link will be gone and so trying the dpcd
>> > read for the link status will fail?
>> >
>> yes,
>> we had a previous bug with this scenarios already.
>> https://partnerissuetracker.corp.google.com/issues/170598152
>> At this case, dongle produce two interrupts, irq_hpd followed by 
>> unplug
>> immediately (not presented at isr status register at same time), at 
>> the
>> time dongle unplugged form DTU.
>> But due to dp ctrl reset at handling irq_hpd which cause unplug mask 
>> bit
>> be cleared so that unplug interrupt got lost.
>> 
> 
> Again, wouldn't that be too late if the hardirq handler is delayed to
> the point that the two irqs are pending in the isr status register?

yes,
but that not much dp driver can do.
As long as DP driver can recovery (shut down gracefully) and ready for 
next plugin, then i think it should be fine.



  reply	other threads:[~2021-05-21 19:45 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-14 17:35 [PATCH v4 1/2] drm/msm/dp: handle irq_hpd with sink_count = 0 correctly Kuogee Hsieh
2021-05-18 21:42 ` Stephen Boyd
2021-05-19 16:01   ` khsieh
2021-05-19 21:06     ` Stephen Boyd
2021-05-20 16:08       ` khsieh
2021-05-20 19:28         ` Stephen Boyd
2021-05-20 20:05           ` khsieh
2021-05-20 21:28             ` Stephen Boyd
2021-05-20 22:39               ` khsieh
2021-05-21  5:00                 ` Stephen Boyd
2021-05-21 15:21                   ` khsieh
2021-05-21 19:18                     ` Stephen Boyd
2021-05-21 19:45                       ` khsieh [this message]
2021-05-21 20:54                         ` Stephen Boyd
2021-05-20 20:36           ` khsieh

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=fc6542f2e760fa92aef73fdb9a789b2d@codeaurora.org \
    --to=khsieh@codeaurora.org \
    --cc=abhinavk@codeaurora.org \
    --cc=agross@kernel.org \
    --cc=aravindh@codeaurora.org \
    --cc=bjorn.andersson@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robdclark@gmail.com \
    --cc=sean@poorly.run \
    --cc=swboyd@chromium.org \
    --cc=vkoul@kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.