public inbox for linux-btrfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Sun YangKai <sunk67188@gmail.com>
To: quwenruo.btrfs@gmx.com
Cc: clm@fb.com, dsterba@suse.com, frank.li@vivo.com,
	josef@toxicpanda.com, linux-btrfs@vger.kernel.org,
	linux-kernel@vger.kernel.org, sunk67188@gmail.com
Subject: Re: [PATCH] btrfs: remove BTRFS_REF_LAST from btrfs_ref_type
Date: Tue, 15 Apr 2025 23:46:15 +0800	[thread overview]
Message-ID: <9442545.CDJkKcVGEf@saltykitkat> (raw)
In-Reply-To: <2e158208-4914-4bfb-984a-0d35e8b93225@gmx.com>

> >> History please.
> > 
> > Did you mean change commit msg to below?
> > 
> > 	Commit b28b1f0ce44c ("btrfs: delayed-ref: Introduce better documented
> > 	delayed ref structures") introduce BTRFS_REF_LAST but never use it, So
> > 	let's remove it.
> 
> It's the common practice to leave a last entry for sanity checks.
> 
> But since it's not utilized for anything, I'm fine to remove it.
We can also add comments for all this kind of codes,
so that further readers will understand this common practice better.
> 
> >> The _LAST or _NR suffix can be utilized to do sanity checks, and this is
> >> not part of the on-disk format.> > 
> > IIRC, delayed ref belongs to the extent tree memory kv cache.
> > 
> >> And if this exposed by some automatic tools, please also mention it.
> > 
> > I'm just looking at this code.
> > 
> > Thx,
> > Yangtao



  reply	other threads:[~2025-04-15 23:35 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-15  8:38 [PATCH] btrfs: remove BTRFS_REF_LAST from btrfs_ref_type Yangtao Li
2025-04-15  8:43 ` Qu Wenruo
2025-04-15  8:56   ` 回复: " 李扬韬
2025-04-15  9:16     ` Qu Wenruo
2025-04-15 15:46       ` Sun YangKai [this message]
2025-04-15 16:05       ` David Sterba
2025-04-16 13:25         ` 回复: " 李扬韬
2025-04-16 19:18           ` David Sterba

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=9442545.CDJkKcVGEf@saltykitkat \
    --to=sunk67188@gmail.com \
    --cc=clm@fb.com \
    --cc=dsterba@suse.com \
    --cc=frank.li@vivo.com \
    --cc=josef@toxicpanda.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=quwenruo.btrfs@gmx.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