mirror of
https://github.com/joel16/android_kernel_sony_msm8994_rework.git
synced 2025-02-21 02:54:17 +00:00
ocfs2: add IO error check in ocfs2_get_sector()
Check for IO error in ocfs2_get_sector(). Signed-off-by: Wengang Wang <wen.gang.wang@oracle.com> Signed-off-by: Mark Fasheh <mfasheh@suse.com>
This commit is contained in:
parent
4442f51826
commit
28d57d4377
@ -1537,6 +1537,13 @@ static int ocfs2_get_sector(struct super_block *sb,
|
|||||||
unlock_buffer(*bh);
|
unlock_buffer(*bh);
|
||||||
ll_rw_block(READ, 1, bh);
|
ll_rw_block(READ, 1, bh);
|
||||||
wait_on_buffer(*bh);
|
wait_on_buffer(*bh);
|
||||||
|
if (!buffer_uptodate(*bh)) {
|
||||||
|
mlog_errno(-EIO);
|
||||||
|
brelse(*bh);
|
||||||
|
*bh = NULL;
|
||||||
|
return -EIO;
|
||||||
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user