From 5157e072c83919f4d0f05ec5d91eb671fdca5753 Mon Sep 17 00:00:00 2001 From: Mark Harmstone Date: Thu, 24 Oct 2024 17:09:37 +0100 Subject: [PATCH] btrfs-progs: tests: add image with compressed extent to fsck-tests/065-valid-log-tree Add a test that when checking for missing csums in the log tree, btrfs check considers the compressed rather than uncompressed size of the extent. See commit "btrfs-progs: check: handle compressed extents when checking tree log". The log tree in compressed.img.xz: log tree key (TREE_LOG ROOT_ITEM 5) leaf 5373952 items 4 free space 15952 generation 7 owner TREE_LOG leaf 5373952 flags 0x1(WRITTEN) backref revision 1 checksum stored 61faf6f2 checksum calced 61faf6f2 fs uuid 70d417f0-0173-49ca-bdf1-b789a798974d chunk uuid b7ec3806-ea09-4f18-a5ef-126a2d79105e item 0 key (257 INODE_ITEM 0) itemoff 16123 itemsize 160 generation 7 transid 7 size 4096 nbytes 0 block group 0 mode 100644 links 1 uid 0 gid 0 rdev 0 sequence 1 flags 0x0(none) atime 1721050040.375996658 (2024-07-15 14:27:20) ctime 1721050040.375996658 (2024-07-15 14:27:20) mtime 1721050040.375996658 (2024-07-15 14:27:20) otime 0.2820488960 (1970-01-01 01:00:00) item 1 key (257 INODE_REF 256) itemoff 16109 itemsize 14 index 2 namelen 4 name: file item 2 key (257 EXTENT_DATA 0) itemoff 16056 itemsize 53 generation 7 type 1 (regular) extent data disk byte 13631488 nr 4096 extent data offset 0 nr 8192 ram 8192 extent compression 1 (zlib) item 3 key (EXTENT_CSUM EXTENT_CSUM 13631488) itemoff 16052 itemsize 4 range start 13631488 end 13635584 length 4096 Signed-off-by: Mark Harmstone [ Move the image to 065-valid-log tree ] Signed-off-by: Qu Wenruo --- .../065-valid-log-tree/compressed.img.xz | Bin 0 -> 1316 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 tests/fsck-tests/065-valid-log-tree/compressed.img.xz diff --git a/tests/fsck-tests/065-valid-log-tree/compressed.img.xz b/tests/fsck-tests/065-valid-log-tree/compressed.img.xz new file mode 100644 index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