]> git.karo-electronics.de Git - karo-tx-linux.git/commit
ocfs2: rollback the cleared bits if error occurs after ocfs2_block_group_clear_bits
authorJoseph Qi <joseph.qi@huawei.com>
Tue, 7 Apr 2015 23:43:55 +0000 (09:43 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 7 Apr 2015 23:43:55 +0000 (09:43 +1000)
commit3c7856e73aad28fe167335e404adc90bacbd8275
treec2b62119968fe246fc4d8efa3a6e7ed2591e6e30
parent9b3dddd87c9159fd4eef7fb2f539ec6f3f8c8c02
ocfs2: rollback the cleared bits if error occurs after ocfs2_block_group_clear_bits

ocfs2_block_group_clear_bits will clear bits in block group bitmap.
Once it succeeds but fails in the following step, it will cause block
group bitmap mismatch the corresponding count recorded in dinode.
So rollback the cleared bits if error occurs.

Signed-off-by: Joseph Qi <joseph.qi@huawei.com>
Cc: Mark Fasheh <mfasheh@suse.com>
Cc: Joel Becker <jlbec@evilplan.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
fs/ocfs2/suballoc.c