Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a2fe594f authored by Jan Kara's avatar Jan Kara Committed by Linus Torvalds
Browse files

reiserfs: fix hang on umount with quotas when journal is aborted



Call dquot_drop() from reiserfs_dquot_drop() even if we fail to start a
transaction.  Otherwise we never get to dropping references to quota
structures from the inode and umount will hang indefinitely.

Signed-off-by: default avatarJan Kara <jack@suse.cz>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent fbe5498b
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -1890,8 +1890,14 @@ static int reiserfs_dquot_drop(struct inode *inode)
	ret =
	    journal_begin(&th, inode->i_sb,
			  2 * REISERFS_QUOTA_DEL_BLOCKS(inode->i_sb));
	if (ret)
	if (ret) {
		/*
		 * We call dquot_drop() anyway to at least release references
		 * to quota structures so that umount does not hang.
		 */
		dquot_drop(inode);
		goto out;
	}
	ret = dquot_drop(inode);
	err =
	    journal_end(&th, inode->i_sb,