mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2026-09-22 09:34:56 +02:00
xfs: don't swallow dquot recovery verification errors
commite2b4a85608upstream. xlog_recover_dquot_commit_pass2() validates the recovered dquot with xfs_dqblk_verify() and, on failure, sets error = -EFSCORRUPTED and jumps to out_release. But out_release unconditionally returns 0, so the corruption error is discarded: the caller xlog_recover_items_pass2() sees success, log recovery proceeds as if the dquot were valid, and the corrupt quota buffer can be written back to disk. Fixes:9c235dfc3d("xfs: dquot recovery does not validate the recovered dquot") Cc: stable@vger.kernel.org # v6.8 Signed-off-by: Long Li <leo.lilong@huawei.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Darrick J. Wong <djwong@kernel.org> Signed-off-by: Carlos Maiolino <cem@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
ed8bfb43de
commit
5b756fbb60
@@ -173,7 +173,7 @@ xlog_recover_dquot_commit_pass2(
|
||||
|
||||
out_release:
|
||||
xfs_buf_relse(bp);
|
||||
return 0;
|
||||
return error;
|
||||
}
|
||||
|
||||
const struct xlog_recover_item_ops xlog_dquot_item_ops = {
|
||||
|
||||
Reference in New Issue
Block a user