From: Christoph Hellwig Date: Thu, 21 Nov 2024 00:24:37 +0000 (-0800) Subject: xfs_db: metadump metadir rt bitmap and summary files X-Git-Tag: v6.13.0~50 X-Git-Url: http://git.ipfire.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=6ba6f3933ee6af32c4a2187b742788cb21831bc6;p=thirdparty%2Fxfsprogs-dev.git xfs_db: metadump metadir rt bitmap and summary files Don't skip dumping the data fork for regular files that are marked as metadata inodes. This catches rtbitmap and summary inodes on rtgroup enabled file systems where their inode numbers aren't recorded in the superblock. Signed-off-by: Christoph Hellwig Reviewed-by: "Darrick J. Wong" Signed-off-by: "Darrick J. Wong" Reviewed-by: Christoph Hellwig --- diff --git a/db/metadump.c b/db/metadump.c index 144ebfbf..8eb4b8eb 100644 --- a/db/metadump.c +++ b/db/metadump.c @@ -2072,7 +2072,11 @@ process_bmbt_reclist( xfs_agblock_t agbno; int rval = 1; - if (btype == TYP_DATA) + /* + * Ignore regular file data except for metadata inodes, where it is by + * definition metadata. + */ + if (btype == TYP_DATA && !is_metadata_ino(dip)) return 1; convert_extent(&rp[numrecs - 1], &o, &s, &c, &f);