linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Darrick J. Wong" <djwong@kernel.org>
To: John Garry <john.g.garry@oracle.com>
Cc: hch@lst.de, cem@kernel.org, dan.j.williams@intel.com,
	willy@infradead.org, jack@suse.cz, brauner@kernel.org,
	viro@zeniv.linux.org.uk, linux-xfs@vger.kernel.org,
	linux-fsdevel@vger.kernel.org, nvdimm@lists.linux.dev,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 1/3] fs/dax: Reject IOCB_ATOMIC in dax_iomap_rw()
Date: Thu, 24 Jul 2025 09:25:53 -0700	[thread overview]
Message-ID: <20250724162553.GM2672029@frogsfrogsfrogs> (raw)
In-Reply-To: <20250724081215.3943871-2-john.g.garry@oracle.com>

On Thu, Jul 24, 2025 at 08:12:13AM +0000, John Garry wrote:
> The DAX write path does not support IOCB_ATOMIC, so reject it when set.
> 
> Suggested-by: Darrick J. Wong <djwong@kernel.org>
> Signed-off-by: John Garry <john.g.garry@oracle.com>

Reviewed-by: "Darrick J. Wong" <djwong@kernel.org>

--D

> ---
>  fs/dax.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/fs/dax.c b/fs/dax.c
> index ea0c35794bf9..d9ce810fee9e 100644
> --- a/fs/dax.c
> +++ b/fs/dax.c
> @@ -1756,6 +1756,9 @@ dax_iomap_rw(struct kiocb *iocb, struct iov_iter *iter,
>  	loff_t done = 0;
>  	int ret;
>  
> +	if (WARN_ON_ONCE(iocb->ki_flags & IOCB_ATOMIC))
> +		return -EIO;
> +
>  	if (!iomi.len)
>  		return 0;
>  
> -- 
> 2.43.5
> 
> 

  reply	other threads:[~2025-07-24 16:25 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-24  8:12 [PATCH v3 0/3] xfs and DAX atomic writes changes John Garry
2025-07-24  8:12 ` [PATCH v3 1/3] fs/dax: Reject IOCB_ATOMIC in dax_iomap_rw() John Garry
2025-07-24 16:25   ` Darrick J. Wong [this message]
2025-07-24  8:12 ` [PATCH v3 2/3] xfs: disallow atomic writes on DAX John Garry
2025-07-24  8:12 ` [PATCH v3 3/3] xfs: reject max_atomic_write mount option for no reflink John Garry
2025-07-24 16:32   ` Darrick J. Wong
2025-07-25  8:39     ` John Garry
2025-07-25 15:49       ` Darrick J. Wong
2025-08-06  9:15 ` [PATCH v3 0/3] xfs and DAX atomic writes changes John Garry
2025-08-11 12:06   ` Carlos Maiolino
2025-08-11 12:08     ` John Garry
2025-08-11 12:13       ` Carlos Maiolino
2025-08-12  7:33 ` Carlos Maiolino

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=20250724162553.GM2672029@frogsfrogsfrogs \
    --to=djwong@kernel.org \
    --cc=brauner@kernel.org \
    --cc=cem@kernel.org \
    --cc=dan.j.williams@intel.com \
    --cc=hch@lst.de \
    --cc=jack@suse.cz \
    --cc=john.g.garry@oracle.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-xfs@vger.kernel.org \
    --cc=nvdimm@lists.linux.dev \
    --cc=viro@zeniv.linux.org.uk \
    --cc=willy@infradead.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 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).