Linux CXL
 help / color / mirror / Atom feed
From: Dave Jiang <dave.jiang@intel.com>
To: Miklos Szeredi <mszeredi@redhat.com>, fuse-devel@lists.linux.dev
Cc: John Groves <john@groves.net>,
	Amir Goldstein <amir73il@gmail.com>,
	"Darrick J . Wong" <djwong@kernel.org>,
	Vishal Verma <vishal.l.verma@intel.com>,
	Alison Schofield <alison.schofield@intel.com>,
	nvdimm@lists.linux.dev, linux-cxl@vger.kernel.org,
	"Gregory Price (Meta)" <gourry@gourry.net>
Subject: Re: [PATCH v5 02/10] dax: use READ_ONCE() in dax_holder()
Date: Fri, 16 Oct 2026 08:20:56 -0700	[thread overview]
Message-ID: <a9b64ee5-4f90-4f42-b680-0d9a77cf64af@intel.com> (raw)
In-Reply-To: <20261016151638.2962413-3-mszeredi@redhat.com>



On 10/16/26 8:16 AM, Miklos Szeredi wrote:
> A future fuse patch will utilize dax_holder() in RCU context to make sure
> that the holder can't be freed by a racing fs_put_dax.
> 
> This patch just makes sure that dax_holder() works properly in such a
> context by adding READ_ONCE() (equivalent to rcu_dereference minus sanity
> checks).
> 
> Fixing XFS is out of scope for this patchset.
> 
> Reviewed-by: Gregory Price (Meta) <gourry@gourry.net>
> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>

Reviewed-by: Dave Jiang <dave.jiang@intel.com>

> ---
>  drivers/dax/super.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/dax/super.c b/drivers/dax/super.c
> index 25836f389bde..76e8d3654629 100644
> --- a/drivers/dax/super.c
> +++ b/drivers/dax/super.c
> @@ -642,7 +642,7 @@ EXPORT_SYMBOL_GPL(put_dax);
>   */
>  void *dax_holder(struct dax_device *dax_dev)
>  {
> -	return dax_dev->holder_data;
> +	return READ_ONCE(dax_dev->holder_data);
>  }
>  EXPORT_SYMBOL_GPL(dax_holder);
>  


  reply	other threads:[~2026-10-16 15:20 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-16 15:16 [PATCH v5 00/10] fuse: DAX device based extent maps (famfs) Miklos Szeredi
2026-10-16 15:16 ` [PATCH v5 01/10] dax: add fsdev_dax_from_file() Miklos Szeredi
2026-10-16 15:20   ` Dave Jiang
2026-10-16 15:28   ` Gregory Price
2026-10-16 15:16 ` [PATCH v5 02/10] dax: use READ_ONCE() in dax_holder() Miklos Szeredi
2026-10-16 15:20   ` Dave Jiang [this message]
2026-10-16 15:16 ` [PATCH v5 03/10] fuse: add helpers for EIO return value with kernel message Miklos Szeredi
2026-10-16 15:16 ` [PATCH v5 04/10] fuse: support 64 bit, server allocated backing ID Miklos Szeredi
2026-10-16 15:16 ` [PATCH v5 05/10] fuse: support opening 64 bit " Miklos Szeredi
2026-10-16 15:16 ` [PATCH v5 06/10] fuse: add support for opening dax device as backing Miklos Szeredi
2026-10-16 15:16 ` [PATCH v5 07/10] fuse: add extent map data structure Miklos Szeredi
2026-10-16 15:16 ` [PATCH v5 08/10] fuse: add extent map I/O support Miklos Szeredi
2026-10-16 15:16 ` [PATCH v5 09/10] fuse: add support for striped backing Miklos Szeredi
2026-10-16 15:16 ` [PATCH v5 10/10] fuse: resolve extent maps in O(1) when possible Miklos Szeredi
2026-10-20 16:50 ` [PATCH v5 00/10] fuse: DAX device based extent maps (famfs) John Groves

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=a9b64ee5-4f90-4f42-b680-0d9a77cf64af@intel.com \
    --to=dave.jiang@intel.com \
    --cc=alison.schofield@intel.com \
    --cc=amir73il@gmail.com \
    --cc=djwong@kernel.org \
    --cc=fuse-devel@lists.linux.dev \
    --cc=gourry@gourry.net \
    --cc=john@groves.net \
    --cc=linux-cxl@vger.kernel.org \
    --cc=mszeredi@redhat.com \
    --cc=nvdimm@lists.linux.dev \
    --cc=vishal.l.verma@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