diff options
Diffstat (limited to 'fs/gfs2')
-rw-r--r-- | fs/gfs2/incore.h | 2 | ||||
-rw-r--r-- | fs/gfs2/log.c | 3 |
2 files changed, 2 insertions, 3 deletions
diff --git a/fs/gfs2/incore.h b/fs/gfs2/incore.h index b8025e51cabf..3aac46f6853e 100644 --- a/fs/gfs2/incore.h +++ b/fs/gfs2/incore.h | |||
@@ -616,7 +616,7 @@ struct gfs2_sbd { | |||
616 | unsigned int sd_log_blks_reserved; | 616 | unsigned int sd_log_blks_reserved; |
617 | unsigned int sd_log_commited_buf; | 617 | unsigned int sd_log_commited_buf; |
618 | unsigned int sd_log_commited_databuf; | 618 | unsigned int sd_log_commited_databuf; |
619 | unsigned int sd_log_commited_revoke; | 619 | int sd_log_commited_revoke; |
620 | 620 | ||
621 | unsigned int sd_log_num_buf; | 621 | unsigned int sd_log_num_buf; |
622 | unsigned int sd_log_num_revoke; | 622 | unsigned int sd_log_num_revoke; |
diff --git a/fs/gfs2/log.c b/fs/gfs2/log.c index 4511b08fc451..e5bf4b59d46e 100644 --- a/fs/gfs2/log.c +++ b/fs/gfs2/log.c | |||
@@ -417,7 +417,7 @@ static unsigned int calc_reserved(struct gfs2_sbd *sdp) | |||
417 | databufhdrs_needed = (sdp->sd_log_commited_databuf + | 417 | databufhdrs_needed = (sdp->sd_log_commited_databuf + |
418 | (dbuf_limit - 1)) / dbuf_limit; | 418 | (dbuf_limit - 1)) / dbuf_limit; |
419 | 419 | ||
420 | if (sdp->sd_log_commited_revoke) | 420 | if (sdp->sd_log_commited_revoke > 0) |
421 | revokes = gfs2_struct2blk(sdp, sdp->sd_log_commited_revoke, | 421 | revokes = gfs2_struct2blk(sdp, sdp->sd_log_commited_revoke, |
422 | sizeof(u64)); | 422 | sizeof(u64)); |
423 | 423 | ||
@@ -790,7 +790,6 @@ static void log_refund(struct gfs2_sbd *sdp, struct gfs2_trans *tr) | |||
790 | gfs2_assert_withdraw(sdp, (((int)sdp->sd_log_commited_buf) >= 0) || | 790 | gfs2_assert_withdraw(sdp, (((int)sdp->sd_log_commited_buf) >= 0) || |
791 | (((int)sdp->sd_log_commited_databuf) >= 0)); | 791 | (((int)sdp->sd_log_commited_databuf) >= 0)); |
792 | sdp->sd_log_commited_revoke += tr->tr_num_revoke - tr->tr_num_revoke_rm; | 792 | sdp->sd_log_commited_revoke += tr->tr_num_revoke - tr->tr_num_revoke_rm; |
793 | gfs2_assert_withdraw(sdp, ((int)sdp->sd_log_commited_revoke) >= 0); | ||
794 | reserved = calc_reserved(sdp); | 793 | reserved = calc_reserved(sdp); |
795 | gfs2_assert_withdraw(sdp, sdp->sd_log_blks_reserved + tr->tr_reserved >= reserved); | 794 | gfs2_assert_withdraw(sdp, sdp->sd_log_blks_reserved + tr->tr_reserved >= reserved); |
796 | unused = sdp->sd_log_blks_reserved - reserved + tr->tr_reserved; | 795 | unused = sdp->sd_log_blks_reserved - reserved + tr->tr_reserved; |