All of lore.kernel.org
 help / color / mirror / Atom feed
From: hch <hch@lst.de>
To: Hans Holmberg <Hans.Holmberg@wdc.com>
Cc: hch <hch@lst.de>, "cem@kernel.org" <cem@kernel.org>,
	"linux-xfs@vger.kernel.org" <linux-xfs@vger.kernel.org>
Subject: Re: [PATCH] xfs: cache open zone in inode->i_private
Date: Thu, 16 Oct 2025 08:06:29 +0200	[thread overview]
Message-ID: <20251016060629.GA31451@lst.de> (raw)
In-Reply-To: <8e5066f2-4e03-4769-bb78-5f87d94759e3@wdc.com>

On Thu, Oct 16, 2025 at 05:17:31AM +0000, Hans Holmberg wrote:
> > +	 * reused for GC in the meantime.  Skip it in that case.
> > +	 */
> > +	rcu_read_lock();
> > +	oz = VFS_I(ip)->i_private;
> > +	if (oz && (oz->oz_is_gc || !atomic_inc_not_zero(&oz->oz_ref)))
> > +		oz = NULL;
> 
> We still won't steal any open zones for gc(except at mount time), so
> the keep the assert and comment below in stead?

True.  When writing this I thought that a zone pointed to could be
reused as the GC zone, and it could.  But the open zone would not
have the oz_is_gc set in that case, but instead we're protected by
it being marked as full inside the oz still.

I'll bring back the old assert and will write extensive comments
explaining all this for v2.


      reply	other threads:[~2025-10-16  6:06 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-15  6:30 [PATCH] xfs: cache open zone in inode->i_private Christoph Hellwig
2025-10-16  5:17 ` Hans Holmberg
2025-10-16  6:06   ` hch [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=20251016060629.GA31451@lst.de \
    --to=hch@lst.de \
    --cc=Hans.Holmberg@wdc.com \
    --cc=cem@kernel.org \
    --cc=linux-xfs@vger.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.