mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Peter Wang <peter.wang@mediatek.com>
To: Po-Wen Kao <powenkao@google.com>, <linux-scsi@vger.kernel.org>
Cc: Konstantin Vyshetsky <vkon@google.com>,
	Alim Akhtar <alim.akhtar@samsung.com>,
	Bart Van Assche <bvanassche@acm.org>,
	Bean Huo <beanhuo@micron.com>,
	Stanley Jhu <stanleyjhu@google.com>,
	"James E . J . Bottomley" <James.Bottomley@HansenPartnership.com>,
	"Martin K . Petersen" <mkp@kernel.org>,
	Can Guo <can.guo@oss.qualcomm.com>,
	<linux-kernel@vger.kernel.org>, Li Qiang <liqiang01@kylinos.cn>,
	John Garry <john.garry@linux.dev>,
	HOYOUNG SEO <hy50.seo@samsung.com>,
	"Hyeoncheol Jeong" <hyenc.jeong@samsung.com>
Subject: Re: [PATCH v2 1/2] scsi: ufs: core: Defer debugfs init until after device init
Date: Tue, 24 Nov 2026 14:15:18 +0800	[thread overview]
Message-ID: <8abfa94806f6cec468551673126497d5e5f65a52.camel@mediatek.com> (raw)
In-Reply-To: <20261124012951.3143833-2-powenkao@google.com>

On Tue, 2026-11-24 at 09:29 +0800, Po-Wen Kao wrote:
> ufshcd_hba_init() currently creates the debugfs hierarchy and fault
> injection attributes before the controller version (hba-
> >ufs_version),
> controller locks, and device descriptor (hba->dev_info.wspecversion)
> are
> initialized.
> 
> Move ufs_debugfs_hba_init() and ufs_fault_inject_hba_init() into
> ufshcd_init() alongside ufs_sysfs_add_nodes(), and move the matching
> ufs_debugfs_hba_exit() from ufshcd_hba_exit() into ufshcd_remove()
> alongside ufs_sysfs_remove_nodes(). Use disable_delayed_work_sync()
> in
> ufs_debugfs_hba_exit() so an in-flight exception event cannot re-
> queue
> debugfs_ee_work while scsi_remove_host() is still tearing down
> devices.
> 
> Moving the exit call symmetrically keeps probe error paths from
> tearing
> down uncreated debugfs state, drains debugfs readers before
> scsi_remove_host() removes the WLUN during unbind, and lets debugfs
> initialization inspect both hba->ufs_version and
> hba->dev_info.wspecversion directly.
> 
> Suggested-by: Peter Wang <peter.wang@mediatek.com>
> Signed-off-by: Brian Kao <powenkao@google.com>
> ---

Reviewed-by: Peter Wang <peter.wang@mediatek.com>

  reply	other threads:[~2026-11-24  6:15 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-24  1:29 [PATCH v2 0/2] scsi: ufs: core: Add debugfs for PA TFS/FEC error counters Po-Wen Kao
2026-11-24  1:29 ` [PATCH v2 1/2] scsi: ufs: core: Defer debugfs init until after device init Po-Wen Kao
2026-11-24  6:15   ` Peter Wang [this message]
2026-11-24  1:29 ` [PATCH v2 2/2] scsi: ufs: core: Add debugfs for PA TFS/FEC error counters Po-Wen Kao
2026-11-24  6:20   ` Peter Wang

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=8abfa94806f6cec468551673126497d5e5f65a52.camel@mediatek.com \
    --to=peter.wang@mediatek.com \
    --cc=James.Bottomley@HansenPartnership.com \
    --cc=alim.akhtar@samsung.com \
    --cc=beanhuo@micron.com \
    --cc=bvanassche@acm.org \
    --cc=can.guo@oss.qualcomm.com \
    --cc=hy50.seo@samsung.com \
    --cc=hyenc.jeong@samsung.com \
    --cc=john.garry@linux.dev \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=liqiang01@kylinos.cn \
    --cc=mkp@kernel.org \
    --cc=powenkao@google.com \
    --cc=stanleyjhu@google.com \
    --cc=vkon@google.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

all inboxes | Powered by JetHome®