From: Shaohua Li Date: Sun, 1 May 2011 22:11:18 +0000 (-0400) Subject: ext4: remove dead code in ext4_has_free_blocks() X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=dc2070a241cf3f86395afe7b969020d99aad8f00;p=openwrt%2Fstaging%2Fblogic.git ext4: remove dead code in ext4_has_free_blocks() percpu_counter_sum_positive() never returns a negative value. Signed-off-by: Shaohua Li Signed-off-by: "Theodore Ts'o" --- diff --git a/fs/ext4/balloc.c b/fs/ext4/balloc.c index 1c67139ad4b4..9c6cd51c09e3 100644 --- a/fs/ext4/balloc.c +++ b/fs/ext4/balloc.c @@ -507,11 +507,6 @@ static int ext4_has_free_blocks(struct ext4_sb_info *sbi, s64 nblocks) EXT4_FREEBLOCKS_WATERMARK) { free_blocks = percpu_counter_sum_positive(fbc); dirty_blocks = percpu_counter_sum_positive(dbc); - if (dirty_blocks < 0) { - printk(KERN_CRIT "Dirty block accounting " - "went wrong %lld\n", - (long long)dirty_blocks); - } } /* Check whether we have space after * accounting for current dirty blocks & root reserved blocks.