aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHeloise <os@iscas.ac.cn>2016-05-20 20:04:25 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2016-05-20 20:58:30 -0400
commit4108124f5c46efc951c4c6be947598a21d6b7fde (patch)
treefda4ad7946c066e364c879e3d15ae88b1cce9c66
parent28898fd1a85fa37a59c090271e8be37afe710276 (diff)
fs/efs/super.c: fix return value
When sb_bread() fails, the return value should be -EIO, fix it. Link: http://lkml.kernel.org/r/1463464943-4142-1-git-send-email-os@iscas.ac.cn Signed-off-by: Heloise <os@iscas.ac.cn> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Firo Yang <firogm@gmail.com> Cc: Vladimir Davydov <vdavydov@virtuozzo.com> Cc: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--fs/efs/super.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/efs/super.c b/fs/efs/super.c
index cb68dac4f9d3..368f7dd21c61 100644
--- a/fs/efs/super.c
+++ b/fs/efs/super.c
@@ -275,7 +275,7 @@ static int efs_fill_super(struct super_block *s, void *d, int silent)
275 275
276 if (!bh) { 276 if (!bh) {
277 pr_err("cannot read volume header\n"); 277 pr_err("cannot read volume header\n");
278 return -EINVAL; 278 return -EIO;
279 } 279 }
280 280
281 /* 281 /*
@@ -293,7 +293,7 @@ static int efs_fill_super(struct super_block *s, void *d, int silent)
293 bh = sb_bread(s, sb->fs_start + EFS_SUPER); 293 bh = sb_bread(s, sb->fs_start + EFS_SUPER);
294 if (!bh) { 294 if (!bh) {
295 pr_err("cannot read superblock\n"); 295 pr_err("cannot read superblock\n");
296 return -EINVAL; 296 return -EIO;
297 } 297 }
298 298
299 if (efs_validate_super(sb, (struct efs_super *) bh->b_data)) { 299 if (efs_validate_super(sb, (struct efs_super *) bh->b_data)) {