From: Christoph Hellwig <hch@infradead.org>
To: Josef Bacik <josef@toxicpanda.com>
Cc: linux-fsdevel@vger.kernel.org
Subject: Re: [LSF/MM/BPF TOPIC] Changing reference counting rules for inodes
Date: Tue, 4 Mar 2025 15:34:00 -0800 [thread overview]
Message-ID: <Z8eN6Nd1iuQC2noS@infradead.org> (raw)
In-Reply-To: <20250303170029.GA3964340@perftesting>
On Mon, Mar 03, 2025 at 12:00:29PM -0500, Josef Bacik wrote:
> Hello,
>
> I've recently gotten annoyed with the current reference counting rules that
> exist in the file system arena, specifically this pattern of having 0
> referenced objects that indicate that they're ready to be reclaimed.
The other way around is worse. E.g. the xfs_buf currently holds a
reference of 1 for buffers on the LRU, which makes a complete mess of
the buf rele and related code. And it prevents us from using the
lockref primitive. Switching it to have a refcount of zero greatly
cleans this up:
http://git.infradead.org/?p=users/hch/xfs.git;a=commitdiff;h=8b46634dd6199f332f09e6f730a7a8801547c8b5
I suspect the inode just needs more clear rules about what state an
inode can be in.
prev parent reply other threads:[~2025-03-04 23:34 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-03 17:00 [LSF/MM/BPF TOPIC] Changing reference counting rules for inodes Josef Bacik
2025-03-04 8:04 ` Dave Chinner
2025-03-04 15:02 ` Josef Bacik
2025-03-04 22:23 ` Dave Chinner
2025-03-04 10:19 ` Christian Brauner
2025-03-04 14:56 ` Josef Bacik
2025-03-04 22:44 ` Matthew Wilcox
2025-03-04 23:34 ` Christoph Hellwig [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=Z8eN6Nd1iuQC2noS@infradead.org \
--to=hch@infradead.org \
--cc=josef@toxicpanda.com \
--cc=linux-fsdevel@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 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).