From patchwork Wed Nov 12 00:10:49 2008 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Rothwell X-Patchwork-Id: 8213 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from ozlabs.org (localhost [127.0.0.1]) by ozlabs.org (Postfix) with ESMTP id 2F377DDF2F for ; Wed, 12 Nov 2008 11:11:13 +1100 (EST) X-Original-To: linuxppc-dev@ozlabs.org Delivered-To: linuxppc-dev@ozlabs.org Received: from smtps.tip.net.au (chilli.pcug.org.au [203.10.76.44]) by ozlabs.org (Postfix) with ESMTP id 370E5DDDED for ; Wed, 12 Nov 2008 11:10:58 +1100 (EST) Received: from ash.ozlabs.ibm.com (bh02i525f01.au.ibm.com [202.81.18.30]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by smtps.tip.net.au (Postfix) with ESMTP id 2930D368023; Wed, 12 Nov 2008 11:10:55 +1100 (EST) Date: Wed, 12 Nov 2008 11:10:49 +1100 From: Stephen Rothwell To: "Theodore Ts'o" , Subject: [PATCH] ext4: fix some s64 printing warnings Message-Id: <20081112111049.68c604ff.sfr@canb.auug.org.au> X-Mailer: Sylpheed 2.5.0 (GTK+ 2.12.11; i486-pc-linux-gnu) Mime-Version: 1.0 Cc: ppc-dev , linux-ext4@vger.kernel.org, LKML X-BeenThere: linuxppc-dev@ozlabs.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@ozlabs.org Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@ozlabs.org A powerpc ppc64_defconfig build of Linus' current tree produces these warnings: fs/ext4/balloc.c: In function 'ext4_has_free_blocks': fs/ext4/balloc.c:617: warning: format '%lld' expects type 'long long int', but argument 2 has type 's64' fs/ext4/inode.c: In function 'ext4_print_free_blocks': fs/ext4/inode.c:1833: warning: format '%lld' expects type 'long long int', but argument 2 has type 's64' fs/ext4/inode.c:1835: warning: format '%lld' expects type 'long long int', but argument 2 has type 's64' Fix them up with the usual casts. Signed-off-by: Stephen Rothwell --- fs/ext4/balloc.c | 2 +- fs/ext4/inode.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/fs/ext4/balloc.c b/fs/ext4/balloc.c index d2003cd..9ce2fcd 100644 --- a/fs/ext4/balloc.c +++ b/fs/ext4/balloc.c @@ -614,7 +614,7 @@ int ext4_has_free_blocks(struct ext4_sb_info *sbi, s64 nblocks) if (dirty_blocks < 0) { printk(KERN_CRIT "Dirty block accounting " "went wrong %lld\n", - dirty_blocks); + (long long)dirty_blocks); } } /* Check whether we have space after diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c index be21a5a..2a3804e 100644 --- a/fs/ext4/inode.c +++ b/fs/ext4/inode.c @@ -1830,9 +1830,9 @@ static void ext4_print_free_blocks(struct inode *inode) ext4_count_free_blocks(inode->i_sb)); printk(KERN_EMERG "Free/Dirty block details\n"); printk(KERN_EMERG "free_blocks=%lld\n", - percpu_counter_sum(&sbi->s_freeblocks_counter)); + (long long)percpu_counter_sum(&sbi->s_freeblocks_counter)); printk(KERN_EMERG "dirty_blocks=%lld\n", - percpu_counter_sum(&sbi->s_dirtyblocks_counter)); + (long long)percpu_counter_sum(&sbi->s_dirtyblocks_counter)); printk(KERN_EMERG "Block reservation details\n"); printk(KERN_EMERG "i_reserved_data_blocks=%lu\n", EXT4_I(inode)->i_reserved_data_blocks);