jbd: Check return value of blkdev_issue_flush()
blkdev_issue_flush() can fail. Make sure the error gets properly propagated. Signed-off-by: Jan Kara <jack@suse.cz>
This commit is contained in:
parent
17dc59ba41
commit
349ecd6a3c
@ -265,8 +265,11 @@ int journal_recover(journal_t *journal)
|
|||||||
if (!err)
|
if (!err)
|
||||||
err = err2;
|
err = err2;
|
||||||
/* Flush disk caches to get replayed data on the permanent storage */
|
/* Flush disk caches to get replayed data on the permanent storage */
|
||||||
if (journal->j_flags & JFS_BARRIER)
|
if (journal->j_flags & JFS_BARRIER) {
|
||||||
blkdev_issue_flush(journal->j_fs_dev, GFP_KERNEL, NULL);
|
err2 = blkdev_issue_flush(journal->j_fs_dev, GFP_KERNEL, NULL);
|
||||||
|
if (!err)
|
||||||
|
err = err2;
|
||||||
|
}
|
||||||
|
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user