Kernel is going to reject invalid root generation. Consider the existing checks are causing some error reports, we should handle such problem in advance, so that's the patchset is going to do, check and repair such invalid root generation. Changelog: v2: - Use existing recow_extent_buffer() to do the repair Qu Wenruo (3): btrfs-progs: check/lowmem: Check and repair root generation btrfs-progs: check/original: Check and repair root item geneartion btrfs-progs: fsck-tests: Add test case for invalid root generation check/main.c | 57 +++++++----------- check/mode-common.c | 36 +++++++++++ check/mode-common.h | 1 + check/mode-lowmem.c | 17 ++++++ check/mode-lowmem.h | 1 + .../default_case.img | Bin 0 -> 3072 bytes 6 files changed, 76 insertions(+), 36 deletions(-) create mode 100644 tests/fsck-tests/041-invalid-root-generation/default_case.img -- 2.22.0
