public inbox for linux-btrfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Josef Bacik <josef@toxicpanda.com>
To: Qu Wenruo <quwenruo.btrfs@gmx.com>
Cc: linux-btrfs@vger.kernel.org, kernel-team@fb.com
Subject: Re: [PATCH 00/20] btrfs-progs: extent tree v2 global root support prep work
Date: Sat, 6 Nov 2021 16:17:47 -0400	[thread overview]
Message-ID: <YYbi6xeChFo8/vKV@localhost.localdomain> (raw)
In-Reply-To: <80f4c9f3-91dd-5afe-efd7-d60c5d4bcdcf@gmx.com>

On Sat, Nov 06, 2021 at 08:55:21AM +0800, Qu Wenruo wrote:
> 
> 
> On 2021/11/6 04:28, Josef Bacik wrote:
> > Hello,
> > 
> > This is a series of patches to do all the prep work needed to support extent
> > tree v2.  These patches are independent of the actual extent tree v2 support,
> > some of them are fixes,
> 
> First half are mostly good, as they are really fixes and independent
> refactors.
> 
> > some of them are purely to pave the way for the global
> > root support.  These patches are mostly around stopping direct access of
> > ->extent_root/->csum_root/->free_space_root, putting these roots into a rb_tree,
> > and changing the code to look up the roots in the rb_tree instead of accessing
> > them directly.  There are a variety of fixes to help make this easier, mostly
> > removing access to these roots that are strictly necessary.  Thanks,
> 
> But the later part for indirect access to previously global trees are
> somewhat questionable.
> 
> The idea of rb-tree caching these trees are no problem, but the callers
> are still passing place holder values to these helpers.
> 
> For current extent-tree, we can pass whatever values and get the root we
> want, but that also means, we need another round of patches to fix all
> the place holders to make them really extent-tree-v2 compatible.
> 
> Thus I'd prefer to see these helpers are called in a proper way in one
> go, which is not really feasible to test in current preparation form.
> 
> Maybe it would be better to put these patches with the real
> extent-tree-v2 code?
>

There's simply too much.  Basically anywhere btrfs_extent_root(fs_info, 0) needs
to be looked at to make sure it's compatible, and trust me I have a loooooot of
patches fixing up the different things that require special handling, and each
of them are beefy by themselves.

It makes it easier for reviewers to grok this way, there's no change for the
!extent_tree_v2 case, and then as the extent tree v2 stuff gets added I make the
necessary changes so they can be properly checked, because lord knows we
probalby fucked some of them up.  Thanks,

Josef 

      reply	other threads:[~2021-11-06 20:17 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-05 20:28 [PATCH 00/20] btrfs-progs: extent tree v2 global root support prep work Josef Bacik
2021-11-05 20:28 ` [PATCH 01/20] btrfs-progs: simplify btrfs_make_block_group Josef Bacik
2021-11-06  0:14   ` Qu Wenruo
2021-11-08 10:13   ` Anand Jain
2021-11-05 20:28 ` [PATCH 02/20] btrfs-progs: check: don't walk down non fs-trees for qgroup check Josef Bacik
2021-11-06  0:14   ` Qu Wenruo
2021-11-05 20:28 ` [PATCH 03/20] btrfs-progs: filesystem-show: close ctree once we're done Josef Bacik
2021-11-08 10:23   ` Anand Jain
2021-11-05 20:28 ` [PATCH 04/20] btrfs-progs: add a helper for setting up a root node Josef Bacik
2021-11-06  0:18   ` Qu Wenruo
2021-11-05 20:28 ` [PATCH 05/20] btrfs-progs: btrfs-shared: stop passing root to csum related functions Josef Bacik
2021-11-06  0:20   ` Qu Wenruo
2021-11-05 20:28 ` [PATCH 06/20] btrfs-progs: check: stop passing csum root around Josef Bacik
2021-11-06  0:21   ` Qu Wenruo
2021-11-05 20:28 ` [PATCH 07/20] btrfs-progs: stop accessing ->csum_root directly Josef Bacik
2021-11-06  0:23   ` Qu Wenruo
2021-11-08 19:19     ` Josef Bacik
2021-11-09  0:56       ` Qu Wenruo
2021-11-09 15:12       ` David Sterba
2021-11-05 20:28 ` [PATCH 08/20] btrfs-progs: image: keep track of seen blocks when walking trees Josef Bacik
2021-11-06  0:26   ` Qu Wenruo
2021-11-05 20:28 ` [PATCH 09/20] btrfs-progs: common: move btrfs_fix_block_accounting to repair.c Josef Bacik
2021-11-06  0:30   ` Qu Wenruo
2021-11-05 20:28 ` [PATCH 10/20] btrfs-progs: check: abstract out the used marking helpers Josef Bacik
2021-11-06  0:37   ` Qu Wenruo
2021-11-05 20:28 ` [PATCH 11/20] btrfs-progs: check: move btrfs_mark_used_tree_blocks to common Josef Bacik
2021-11-05 20:28 ` [PATCH 12/20] btrfs-progs: mark reloc roots as used Josef Bacik
2021-11-06  0:39   ` Qu Wenruo
2021-11-08 19:14     ` Josef Bacik
2021-11-09  0:57       ` Qu Wenruo
2021-11-05 20:28 ` [PATCH 13/20] btrfs-progs: stop accessing ->extent_root directly Josef Bacik
2021-11-06  0:41   ` Qu Wenruo
2021-11-05 20:28 ` [PATCH 14/20] btrfs-progs: stop accessing ->free_space_root directly Josef Bacik
2021-11-06  0:44   ` Qu Wenruo
2021-11-05 20:28 ` [PATCH 15/20] btrfs-progs: track csum, extent, and free space trees in a rb tree Josef Bacik
2021-11-05 20:28 ` [PATCH 16/20] btrfs-progs: check: make reinit work per found root item Josef Bacik
2021-11-05 20:28 ` [PATCH 17/20] btrfs-progs: check: check the global roots for uptodate root nodes Josef Bacik
2021-11-05 20:28 ` [PATCH 18/20] btrfs-progs: check: check all of the csum roots Josef Bacik
2021-11-05 20:28 ` [PATCH 19/20] btrfs-progs: check: fill csum root from all extent roots Josef Bacik
2021-11-05 20:28 ` [PATCH 20/20] btrfs-progs: common: search all extent roots for marking used space Josef Bacik
2021-11-06  0:55 ` [PATCH 00/20] btrfs-progs: extent tree v2 global root support prep work Qu Wenruo
2021-11-06 20:17   ` Josef Bacik [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=YYbi6xeChFo8/vKV@localhost.localdomain \
    --to=josef@toxicpanda.com \
    --cc=kernel-team@fb.com \
    --cc=linux-btrfs@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