btrfs-progs/kernel-shared
Qu Wenruo 33a21e7578 btrfs-progs: tune: rework the main idea of csum change
The existing attempt for changing csum types is as the following:

- Create a new temporary csum root
- Generate new data csums into the temporary csum root
- Drop the old csum tree and make the temporary one as csum root
- Change the checksums for metadata in-place

Unfortunately after some experiments, the csum root switch method has a
big pitfall, the backref items in extent tree.

Those backref items still point back to the old tree, meaning without a
lot of extra tricks, the extent tree would be corrupted.

Thus we have to go a new single tree variant:

- Generate new data csums into the csum root
  The new data csums would have a different objectid to distinguish
  them.
- Drop the old data csum items
- Change the key objectids of the new csums
- Change the checksums for metadata in-place

This means unfortunately we have to revert most of the old code, and
update the temporary item format.

The new temporary item would only record the target csum type.
At every stage we have a method to determine the progress, thus no need
for an item, but in the future it's still open for change.

Signed-off-by: Qu Wenruo <wqu@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
2023-05-26 18:02:32 +02:00
..
uapi btrfs-progs: tune: rework the main idea of csum change 2023-05-26 18:02:32 +02:00
accessors.c btrfs-progs: sync accessors.[ch] from the kernel 2023-05-26 18:02:28 +02:00
accessors.h btrfs-progs: sync accessors.[ch] from the kernel 2023-05-26 18:02:28 +02:00
async-thread.c btrfs-progs: sync async-thread.[ch] from the kernel 2023-05-26 18:02:29 +02:00
async-thread.h btrfs-progs: sync async-thread.[ch] from the kernel 2023-05-26 18:02:29 +02:00
backref.c btrfs-progs: update read_tree_block to match the kernel definition 2023-05-26 18:02:30 +02:00
backref.h btrfs-progs: move extent_io.c to kernel-shared/ 2020-08-31 17:01:04 +02:00
compression.h btrfs-progs: sync compression.h from kernel 2023-05-26 18:02:31 +02:00
ctree.c btrfs-progs: tune: rework the main idea of csum change 2023-05-26 18:02:32 +02:00
ctree.h btrfs-progs: tune: rework the main idea of csum change 2023-05-26 18:02:32 +02:00
delayed-ref.c btrfs-progs: sync messages.[ch] from the kernel 2023-05-26 18:02:28 +02:00
delayed-ref.h btrfs-progs: unify GPL header comments 2021-09-07 13:58:44 +02:00
dir-item.c btrfs-progs: sync accessors.[ch] from the kernel 2023-05-26 18:02:28 +02:00
disk-io.c btrfs-progs: tune: rework the main idea of csum change 2023-05-26 18:02:32 +02:00
disk-io.h btrfs-progs: replace write_and_map_eb() by write_data_to_disk() 2023-05-26 18:02:31 +02:00
extent-io-tree.c btrfs-progs: sync extent-io-tree.[ch] from kernel 2023-05-26 18:02:31 +02:00
extent-io-tree.h btrfs-progs: sync extent-io-tree.[ch] from kernel 2023-05-26 18:02:31 +02:00
extent-tree.c btrfs-progs: add an atomic parameter to btrfs_buffer_uptodate 2023-05-26 18:02:30 +02:00
extent_io.c btrfs-progs: constify the buffer pointer for write functions 2023-05-26 18:02:31 +02:00
extent_io.h btrfs-progs: constify the buffer pointer for write functions 2023-05-26 18:02:31 +02:00
file-item.c btrfs-progs: tune: rework the main idea of csum change 2023-05-26 18:02:32 +02:00
file-item.h btrfs-progs: sync file-item.h into progs 2023-05-26 18:02:29 +02:00
file.c btrfs-progs: sync file-item.h into progs 2023-05-26 18:02:29 +02:00
free-space-cache.c btrfs-progs: remove root argument from free_extent and inc_extent_ref 2023-05-26 18:02:30 +02:00
free-space-cache.h btrfs-progs: check: batch v1 space cache inodes when clearing 2021-07-22 16:26:05 +02:00
free-space-tree.c btrfs-progs: sync messages.[ch] from the kernel 2023-05-26 18:02:28 +02:00
free-space-tree.h btrfs-progs: properly initialize block group thresholds 2022-05-20 15:54:20 +02:00
inode-item.c btrfs-progs: remove the _nr from the item helpers 2022-03-09 15:13:13 +01:00
inode.c btrfs-progs: sync accessors.[ch] from the kernel 2023-05-26 18:02:28 +02:00
locking.c btrfs-progs: sync locking.h and stub out all the helpers 2023-05-26 18:02:29 +02:00
locking.h btrfs-progs: sync locking.h and stub out all the helpers 2023-05-26 18:02:29 +02:00
messages.c btrfs-progs: add musl compatibility for printf format %pV 2023-05-26 18:02:28 +02:00
messages.h btrfs-progs: sync messages.[ch] from the kernel 2023-05-26 18:02:28 +02:00
misc.h btrfs-progs: sync extent-io-tree.[ch] and misc.h from the kernel 2023-05-26 18:02:29 +02:00
print-tree.c btrfs-progs: tune: rework the main idea of csum change 2023-05-26 18:02:32 +02:00
print-tree.h btrfs-progs: dump-tree: add options to dump checksums 2021-06-19 22:07:49 +02:00
README.md btrfs-progs: add README to kernel-shared tracking the progress 2023-05-26 18:02:32 +02:00
root-tree.c btrfs-progs: remove the _nr from the item helpers 2022-03-09 15:13:13 +01:00
send.h btrfs-progs: sync send.h from kernel 2023-05-26 18:02:32 +02:00
transaction.c btrfs-progs: partial sync of transaction.h from kernel 2023-05-26 18:02:32 +02:00
transaction.h btrfs-progs: partial sync of transaction.h from kernel 2023-05-26 18:02:32 +02:00
tree-checker.c btrfs-progs: sync tree-checker.[ch] from kernel 2023-05-26 18:02:30 +02:00
tree-checker.h btrfs-progs: sync tree-checker.[ch] from kernel 2023-05-26 18:02:30 +02:00
tree-mod-log.h btrfs-progs: sync and stub-out tree-mod-log.h 2023-05-26 18:02:29 +02:00
ulist.c btrfs-progs: sync ulist.[ch] from kernel 2023-05-26 18:02:32 +02:00
ulist.h btrfs-progs: sync ulist.[ch] from kernel 2023-05-26 18:02:32 +02:00
uuid-tree.c btrfs-progs: remove the _nr from the item helpers 2022-03-09 15:13:13 +01:00
volumes.c btrfs-progs: sync tree-checker.[ch] from kernel 2023-05-26 18:02:30 +02:00
volumes.h btrfs-progs: sync tree-checker.[ch] from kernel 2023-05-26 18:02:30 +02:00
zoned.c btrfs-progs: fix -Wmissing-prototypes warnings 2023-05-26 18:02:31 +02:00
zoned.h btrfs-progs: sync messages.[ch] from the kernel 2023-05-26 18:02:28 +02:00

Shared sources with kernel

Status and progress of kernel/userspace synchronization.

  • accessors.c - done, local changes
  • accessors.h - done, local changes
  • async-thread.c - done
  • async-thread.h - done
  • backref.c - todo
  • backref.h - todo
  • compression.h - done
  • ctree.c - partial
  • ctree.h - partial
  • delayed-ref.c - partial
  • delayed-ref.h - partial
  • dir-item.c - partial
  • disk-io.c - todo
  • disk-io.h - todo
  • extent_io.c
  • extent_io.h
  • extent-io-tree.c - done, local changes
  • extent-io-tree.h - done, local changes
  • extent-tree.c - todo
  • file.c - todo
  • file-item.c - todo
  • file-item.h - partial
  • free-space-cache.c - not needed
  • free-space-cache.h - not needed
  • free-space-tree.c - partial
  • free-space-tree.h - partial
  • inode.c - todo
  • inode-item.c - partial
  • locking.c - done, local changes
  • locking.h - done, local changes
  • messages.c - done, local changes
  • messages.h - done, local changes
  • misc.h - done
  • print-tree.c - partial, sync to kernel
  • print-tree.h - partial
  • root-tree.c - partial
  • root-tree.h - done
  • send.h - done
  • transaction.c - todo
  • transaction.h - partial, local changes
  • tree-checker.c - partial, local changes
  • tree-checker.h - partial, local changes
  • tree-mod-log.h - done, local changes
  • ulist.c - done
  • ulist.h - done
  • uuid-tree.c - partial
  • volumes.c - todo, local changes
  • volumes.h - todo, local changes
  • zoned.c - todo
  • zoned.h - todo