mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-11 14:53:56 +08:00
xfs: don't leak quotacheck dquots when cow recovery
If we fail a mount on account of cow recovery errors, it's possible that a previous quotacheck left some dquots in memory. The bailout clause of xfs_mountfs forgets to purge these, and so we leak them. Fix that. Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com> Reviewed-by: Brian Foster <bfoster@redhat.com>
This commit is contained in:
parent
8204f8ddaa
commit
77aff8c764
@ -1024,6 +1024,8 @@ xfs_mountfs(
|
|||||||
IRELE(rip);
|
IRELE(rip);
|
||||||
cancel_delayed_work_sync(&mp->m_reclaim_work);
|
cancel_delayed_work_sync(&mp->m_reclaim_work);
|
||||||
xfs_reclaim_inodes(mp, SYNC_WAIT);
|
xfs_reclaim_inodes(mp, SYNC_WAIT);
|
||||||
|
/* Clean out dquots that might be in memory after quotacheck. */
|
||||||
|
xfs_qm_unmount(mp);
|
||||||
out_log_dealloc:
|
out_log_dealloc:
|
||||||
mp->m_flags |= XFS_MOUNT_UNMOUNTING;
|
mp->m_flags |= XFS_MOUNT_UNMOUNTING;
|
||||||
xfs_log_mount_cancel(mp);
|
xfs_log_mount_cancel(mp);
|
||||||
|
Loading…
Reference in New Issue
Block a user