f2fs: attach inline_data after setting compression
authorJaegeuk Kim <jaegeuk@kernel.org>
Wed, 1 Jun 2022 01:27:09 +0000 (18:27 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 29 Jun 2022 07:03:27 +0000 (09:03 +0200)
commitf650029de357bee182233f635589e8afea90ba44
treebf01be94fa5b68c0764d503a63e720133664db8f
parentd98b5032c9d046c946099fa09a01657f194796ad
f2fs: attach inline_data after setting compression

commit 4cde00d50707c2ef6647b9b96b2cb40b6eb24397 upstream.

This fixes the below corruption.

[345393.335389] F2FS-fs (vdb): sanity_check_inode: inode (ino=6d0, mode=33206) should not have inline_data, run fsck to fix

Cc: <stable@vger.kernel.org>
Fixes: 677a82b44ebf ("f2fs: fix to do sanity check for inline inode")
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/f2fs/namei.c