[f2fs-dev] [PATCH 4/4] fsck.f2fs: lookup and relink root inode

2023-05-12 Thread Chao Yu
As Stephanos reported in mailing list: Info: checkpoint state = 1 : unmount [ASSERT] (sanity_check_nid: 362) --> nid[0x3] ino is 0 The root cause is root inode's nat entry is corrupted, this patch add logic to search root inode from all node blocks, try to relink root inode's nat to target node

[f2fs-dev] [PATCH 2/4] fsck.f2fs: use f2fs_is_valid_blkaddr()

2023-05-12 Thread Chao Yu
use f2fs_is_valid_blkaddr() instead of IS_VALID_BLK_ADDR() to check validity of data/node's block address. use is_valid_data_blkaddr() in sanity_check_nid() to check NULL_ADDR as NEW_ADDR, and print the value in error path explicitly. Signed-off-by: Chao Yu --- fsck/dump.c | 5 +++-- fsck/f2f

[f2fs-dev] [PATCH 3/4] fsck.f2fs: add more debug info in fsck_verify()

2023-05-12 Thread Chao Yu
In order to track details of stat info and repair flow. [FSCK] valid_block_count matching with CP [Fail] [0x2, 0x0] [FSCK] valid_node_count matching with CP (de lookup) [Fail] [0x1, 0x0] [FSCK] valid_node_count matching with CP (nat lookup) [Fail] [0x1, 0x0] [FSCK] valid_inode_count m

[f2fs-dev] [PATCH 1/4] fsck.f2fs: wrap openned codes into fsck_sanity_check_nid()

2023-05-12 Thread Chao Yu
read_all_xattrs() is the only user of fsck_sanity_check_nid(), wrap openned codes of read_all_xattrs() into fsck_sanity_check_nid(). Then fsck_sanity_check_nid() can be reused later. Signed-off-by: Chao Yu --- fsck/fsck.c | 16 fsck/fsck.h | 3 +-- fsck/xattr.c | 12 +---

[f2fs-dev] Kernel warnings 6.3.1

2023-05-12 Thread Richard Tresidder via Linux-f2fs-devel
Hi    We're upgrading our systems from using a 5.1.7 based kernel to a 6.3.1 based kernel. I'm experiencing some warnings popping out occasionally from the f2fs driver [  137.225376] WARNING: CPU: 0 PID: 32