linux/fs/jbd2
Jan Kara 164802e408 jbd2: avoid infinite loop when destroying aborted journal
commit 841df7df19 upstream.

Commit 6f6a6fda29 "jbd2: fix ocfs2 corrupt when updating journal
superblock fails" changed jbd2_cleanup_journal_tail() to return EIO
when the journal is aborted. That makes logic in
jbd2_log_do_checkpoint() bail out which is fine, except that
jbd2_journal_destroy() expects jbd2_log_do_checkpoint() to always make
a progress in cleaning the journal. Without it jbd2_journal_destroy()
just loops in an infinite loop.

Fix jbd2_journal_destroy() to cleanup journal checkpoint lists of
jbd2_log_do_checkpoint() fails with error.

Reported-by: Eryu Guan <guaneryu@gmail.com>
Tested-by: Eryu Guan <guaneryu@gmail.com>
Fixes: 6f6a6fda29
Signed-off-by: Jan Kara <jack@suse.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2015-09-29 19:26:19 +02:00
..
checkpoint.c jbd2: avoid infinite loop when destroying aborted journal 2015-09-29 19:26:19 +02:00
commit.c jbd2: avoid infinite loop when destroying aborted journal 2015-09-29 19:26:19 +02:00
journal.c jbd2: avoid infinite loop when destroying aborted journal 2015-09-29 19:26:19 +02:00
Kconfig jbd2: remove debug dependency on debug_fs and update Kconfig help text 2013-06-12 23:07:51 -04:00
Makefile [PATCH] jbd2: rename jbd2 symbols to avoid duplication of jbd symbols 2006-10-11 11:14:15 -07:00
recovery.c jbd2: fix r_count overflows leading to buffer overflow in journal recovery 2015-05-14 19:11:50 -04:00
revoke.c jbd2: fix r_count overflows leading to buffer overflow in journal recovery 2015-05-14 19:11:50 -04:00
transaction.c ext4: fix NULL pointer dereference when journal restart fails 2015-05-14 18:55:18 -04:00