aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
Diffstat (limited to 'fs')
-rw-r--r--fs/ext3/inode.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/fs/ext3/inode.c b/fs/ext3/inode.c
index c5ee9f0691e3..0f0b1eadb98d 100644
--- a/fs/ext3/inode.c
+++ b/fs/ext3/inode.c
@@ -1009,11 +1009,14 @@ struct buffer_head *ext3_getblk(handle_t *handle, struct inode *inode,
1009 buffer_trace_init(&dummy.b_history); 1009 buffer_trace_init(&dummy.b_history);
1010 err = ext3_get_blocks_handle(handle, inode, block, 1, 1010 err = ext3_get_blocks_handle(handle, inode, block, 1,
1011 &dummy, create, 1); 1011 &dummy, create, 1);
1012 if (err == 1) { 1012 /*
1013 * ext3_get_blocks_handle() returns number of blocks
1014 * mapped. 0 in case of a HOLE.
1015 */
1016 if (err > 0) {
1017 if (err > 1)
1018 WARN_ON(1);
1013 err = 0; 1019 err = 0;
1014 } else if (err >= 0) {
1015 WARN_ON(1);
1016 err = -EIO;
1017 } 1020 }
1018 *errp = err; 1021 *errp = err;
1019 if (!err && buffer_mapped(&dummy)) { 1022 if (!err && buffer_mapped(&dummy)) {