xfs
[Top] [All Lists]

[PATCH 03/14] repair: kill B_IS_META flag

To: xfs@xxxxxxxxxxx
Subject: [PATCH 03/14] repair: kill B_IS_META flag
From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date: Wed, 02 Sep 2009 13:55:34 -0400
References: <20090902175531.469184575@xxxxxxxxxxxxxxxxxxxxxx>
User-agent: quilt/0.47-1
B_IS_META is the inverse flag of B_IS_INODE which is not really obvious
from it's use.  So just use !B_IS_INODE to make it more clear.


Signed-off-by: Christoph Hellwig <hch@xxxxxx>

Index: xfsprogs-dev/repair/prefetch.c
===================================================================
--- xfsprogs-dev.orig/repair/prefetch.c 2009-08-20 00:02:25.000000000 +0000
+++ xfsprogs-dev/repair/prefetch.c      2009-08-20 00:05:36.000000000 +0000
@@ -64,7 +64,6 @@
  * the buffer is for an inode or other metadata.
  */
 #define B_IS_INODE(f)  (((f) & 5) == 0)
-#define B_IS_META(f)   (((f) & 5) != 0)
 
 #define DEF_BATCH_BYTES        0x10000
 
@@ -131,7 +130,7 @@
 
        if (fsbno > args->last_bno_read) {
                radix_tree_insert(&args->primary_io_queue, fsbno, bp);
-               if (B_IS_META(flag))
+               if (!B_IS_INODE(flag))
                        radix_tree_tag_set(&args->primary_io_queue, fsbno, 0);
                else {
                        args->inode_bufs_queued++;
@@ -153,7 +152,7 @@
                        (long long)XFS_BUF_ADDR(bp), args->agno, fsbno,
                        args->last_bno_read);
 #endif
-               ASSERT(B_IS_META(flag));
+               ASSERT(!B_IS_INODE(flag));
                XFS_BUF_SET_PRIORITY(bp, B_DIR_META_2);
                radix_tree_insert(&args->secondary_io_queue, fsbno, bp);
        }

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