diff options
Diffstat (limited to 'fs/gfs2/quota.c')
-rw-r--r-- | fs/gfs2/quota.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/gfs2/quota.c b/fs/gfs2/quota.c index c69b94a55588..a3deae7416c9 100644 --- a/fs/gfs2/quota.c +++ b/fs/gfs2/quota.c | |||
@@ -251,7 +251,7 @@ static int bh_get(struct gfs2_quota_data *qd) | |||
251 | unsigned int block, offset; | 251 | unsigned int block, offset; |
252 | struct buffer_head *bh; | 252 | struct buffer_head *bh; |
253 | int error; | 253 | int error; |
254 | struct buffer_head bh_map; | 254 | struct buffer_head bh_map = { .b_state = 0, .b_blocknr = 0 }; |
255 | 255 | ||
256 | mutex_lock(&sdp->sd_quota_mutex); | 256 | mutex_lock(&sdp->sd_quota_mutex); |
257 | 257 | ||
@@ -263,7 +263,8 @@ static int bh_get(struct gfs2_quota_data *qd) | |||
263 | block = qd->qd_slot / sdp->sd_qc_per_block; | 263 | block = qd->qd_slot / sdp->sd_qc_per_block; |
264 | offset = qd->qd_slot % sdp->sd_qc_per_block;; | 264 | offset = qd->qd_slot % sdp->sd_qc_per_block;; |
265 | 265 | ||
266 | error = gfs2_block_map(&ip->i_inode, block, 0, &bh_map, 1); | 266 | bh_map.b_size = 1 << ip->i_inode.i_blkbits; |
267 | error = gfs2_block_map(&ip->i_inode, block, 0, &bh_map); | ||
267 | if (error) | 268 | if (error) |
268 | goto fail; | 269 | goto fail; |
269 | error = gfs2_meta_read(ip->i_gl, bh_map.b_blocknr, DIO_WAIT, &bh); | 270 | error = gfs2_meta_read(ip->i_gl, bh_map.b_blocknr, DIO_WAIT, &bh); |