xfs
[Top] [All Lists]

Re: [GIT PULL] XFS update for 2.6.29

To: Geert Uytterhoeven <geert@xxxxxxxxxxxxxx>
Subject: Re: [GIT PULL] XFS update for 2.6.29
From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date: Thu, 1 Jan 2009 12:03:29 -0500
Cc: Lachlan McIlroy <lachlan@xxxxxxx>, Christoph Hellwig <hch@xxxxxxxxxxxxx>, Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx>, Linux Kernel Development <linux-kernel@xxxxxxxxxxxxxxx>, xfs@xxxxxxxxxxx, Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
In-reply-to: <Pine.LNX.4.64.0901011048090.14380@anakin>
References: <20081230030845.A4F0558AE206@xxxxxxxxxxxxxxxxxxxxxxx> <Pine.LNX.4.64.0901011048090.14380@anakin>
User-agent: Mutt/1.5.18 (2008-05-17)
On Thu, Jan 01, 2009 at 10:50:52AM +0100, Geert Uytterhoeven wrote:
> | fs/xfs/xfs_btree.c: In function 'xfs_btree_readahead_lblock':
> | fs/xfs/xfs_btree.c:736: warning: comparison is always true due to limited 
> range of data type
> | fs/xfs/xfs_btree.c:741: warning: comparison is always true due to limited 
> range of data type
> 
> left/right = xfs_fsblock_t (32 or 64 bit), NULLDFSBNO = xfs_dfsbno_t (64 bit)

Hmm, can't reproduce it here with CONFIG_LBD=n on x86, but the following
patch should fix it:

Index: linux-2.6/fs/xfs/xfs_btree.c
===================================================================
--- linux-2.6.orig/fs/xfs/xfs_btree.c   2009-01-01 15:57:04.606547140 +0100
+++ linux-2.6/fs/xfs/xfs_btree.c        2009-01-01 15:57:24.780673454 +0100
@@ -730,8 +730,8 @@ xfs_btree_readahead_lblock(
        struct xfs_btree_block  *block)
 {
        int                     rval = 0;
-       xfs_fsblock_t           left = be64_to_cpu(block->bb_u.l.bb_leftsib);
-       xfs_fsblock_t           right = be64_to_cpu(block->bb_u.l.bb_rightsib);
+       xfs_dfsbno_t            left = be64_to_cpu(block->bb_u.l.bb_leftsib);
+       xfs_dfsbno_t            right = be64_to_cpu(block->bb_u.l.bb_rightsib);
 
        if ((lr & XFS_BTCUR_LEFTRA) && left != NULLDFSBNO) {
                xfs_btree_reada_bufl(cur->bc_mp, left, 1);

<Prev in Thread] Current Thread [Next in Thread>