]> www.infradead.org Git - users/jedix/linux-maple.git/commit
ocfs2: clear journal dirty flag after shutdown journal
authorJunxiao Bi <junxiao.bi@oracle.com>
Fri, 28 Dec 2018 08:32:53 +0000 (00:32 -0800)
committerBrian Maly <brian.maly@oracle.com>
Tue, 8 Jan 2019 15:54:44 +0000 (10:54 -0500)
commit7256781672b4da3dcabd0784f48f541ce67dc0c2
tree49f46fa02c12e5556ba7f8d9df15dd5896d33211
parentb07a410c88308cbddc476dddbeb64d7ce618c2f6
ocfs2: clear journal dirty flag after shutdown journal

Dirty flag of the journal should be cleared at the last stage of umount,
if do it before jbd2_journal_destroy(), then some metadata in uncommitted
transaction could be lost due to io error, but as dirty flag of journal
was already cleared, we can't find that until run a full fsck.  This may
cause system panic or other corruption.

Link: http://lkml.kernel.org/r/20181121020023.3034-3-junxiao.bi@oracle.com
Signed-off-by: Junxiao Bi <junxiao.bi@oracle.com>
Reviewed-by: Yiwen Jiang <jiangyiwen@huawei.com>
Reviewed-by: Joseph Qi <jiangqi903@gmail.com>
Cc: Jun Piao <piaojun@huawei.com>
Cc: Changwei Ge <ge.changwei@h3c.com>
Cc: Joel Becker <jlbec@evilplan.org>
Cc: Mark Fasheh <mfasheh@versity.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
(cherry picked from commit d85400af790dba2aa294f0a77e712f166681f977)

Orabug: 28924775

Signed-off-by: Junxiao Bi <junxiao.bi@oracle.com>
Reviewed-by: Ashish Samant <ashish.samant@oracle.com>
Signed-off-by: Brian Maly <brian.maly@oracle.com>
fs/ocfs2/journal.c