public inbox for linux-mediatek@lists.infradead.org
 help / color / mirror / Atom feed
From: "Peter Wang (王信友)" <peter.wang@mediatek.com>
To: "linux-scsi@vger.kernel.org" <linux-scsi@vger.kernel.org>,
	"jejb@linux.ibm.com" <jejb@linux.ibm.com>,
	"bvanassche@acm.org" <bvanassche@acm.org>,
	"avri.altman@wdc.com" <avri.altman@wdc.com>,
	"martin.petersen@oracle.com" <martin.petersen@oracle.com>,
	"alim.akhtar@samsung.com" <alim.akhtar@samsung.com>
Cc: "Tun-yu Yu (游敦聿)" <Tun-yu.Yu@mediatek.com>,
	"Alice Chao (趙珮均)" <Alice.Chao@mediatek.com>,
	"Eddie Huang (黃智傑)" <eddie.huang@mediatek.com>,
	"CC Chou (周志杰)" <cc.chou@mediatek.com>,
	"Ed Tsai (蔡宗軒)" <Ed.Tsai@mediatek.com>,
	wsd_upstream <wsd_upstream@mediatek.com>,
	"Chaotian Jing (井朝天)" <Chaotian.Jing@mediatek.com>,
	"Chun-Hung Wu (巫駿宏)" <Chun-hung.Wu@mediatek.com>,
	"Yi-fan Peng (彭羿凡)" <Yi-fan.Peng@mediatek.com>,
	"Qilin Tan (谭麒麟)" <Qilin.Tan@mediatek.com>,
	"linux-mediatek@lists.infradead.org"
	<linux-mediatek@lists.infradead.org>,
	"Jiajie Hao (郝加节)" <jiajie.hao@mediatek.com>,
	"Lin Gui (桂林)" <Lin.Gui@mediatek.com>,
	"Naomi Chu (朱詠田)" <Naomi.Chu@mediatek.com>
Subject: Re: [PATCH v1] ufs: core: Fix runtime suspend error deadlock
Date: Thu, 25 Sep 2025 10:03:21 +0000	[thread overview]
Message-ID: <a6c52b9f7f3f7e1e17a0777cbb0bedcf32b284e1.camel@mediatek.com> (raw)
In-Reply-To: <c2b02246-1ff4-4882-a856-4af888f1a80f@acm.org>

On Wed, 2025-09-24 at 14:51 -0700, Bart Van Assche wrote:
> 
> Hi Peter,
> 
> The UFS error handler is not only triggered by bus errors. It can
> also
> be activated via debugfs. Do you agree that activation via debugfs
> can
> happen concurrently with runtime suspend?
> 
> Thanks,
> 
> Bart.


Hi Bart,

Do you mean that debugfs could schedule EH work just before
suspend? If so, there is indeed a chance that this patch 
might not work as intended. Even if we surround it with 
ufshcd_rpm_get_noresume() and ufshcd_rpm_put(), there is 
still a possibility that runtime PM is ongoing and the suspend
callback hasn't been called yet, so the result would be the 
same, just with a lower chance of occurrence.

Because this patch mainly targets errors that occur during
the suspend process. If the error happens before suspend, 
it’s outside the scope of what this patch is intended to fix. 
But I will add ufshcd_rpm_get_noresume() and ufshcd_rpm_put() 
next version.

Thanks.
Peter


      reply	other threads:[~2025-09-25 10:03 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-23  8:20 [PATCH v1] ufs: core: Fix runtime suspend error deadlock peter.wang
2025-09-23 16:07 ` Bart Van Assche
2025-09-24  9:26   ` Peter Wang (王信友)
2025-09-24 21:51     ` Bart Van Assche
2025-09-25 10:03       ` Peter Wang (王信友) [this message]

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=a6c52b9f7f3f7e1e17a0777cbb0bedcf32b284e1.camel@mediatek.com \
    --to=peter.wang@mediatek.com \
    --cc=Alice.Chao@mediatek.com \
    --cc=Chaotian.Jing@mediatek.com \
    --cc=Chun-hung.Wu@mediatek.com \
    --cc=Ed.Tsai@mediatek.com \
    --cc=Lin.Gui@mediatek.com \
    --cc=Naomi.Chu@mediatek.com \
    --cc=Qilin.Tan@mediatek.com \
    --cc=Tun-yu.Yu@mediatek.com \
    --cc=Yi-fan.Peng@mediatek.com \
    --cc=alim.akhtar@samsung.com \
    --cc=avri.altman@wdc.com \
    --cc=bvanassche@acm.org \
    --cc=cc.chou@mediatek.com \
    --cc=eddie.huang@mediatek.com \
    --cc=jejb@linux.ibm.com \
    --cc=jiajie.hao@mediatek.com \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    --cc=wsd_upstream@mediatek.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