summaryrefslogtreecommitdiff
path: root/fs/ext4/ext4.h
diff options
context:
space:
mode:
authorAkinobu Mita <akinobu.mita@gmail.com>2010-03-04 04:55:01 (GMT)
committerTheodore Ts'o <tytso@mit.edu>2010-03-04 04:55:01 (GMT)
commit731eb1a03a8445cde2cb23ecfb3580c6fa7bb690 (patch)
tree9978388978604207cc78da1c81b97625857256cb /fs/ext4/ext4.h
parentbda00de7e8569b1fcde27b68fa59e74e14c5f93a (diff)
downloadlinux-fsl-qoriq-731eb1a03a8445cde2cb23ecfb3580c6fa7bb690.tar.xz
ext4: consolidate in_range() definitions
There are duplicate macro definitions of in_range() in mballoc.h and balloc.c. This consolidates these two definitions into ext4.h, and changes extents.c to use in_range() as well. Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu> Cc: Andreas Dilger <adilger@sun.com>
Diffstat (limited to 'fs/ext4/ext4.h')
-rw-r--r--fs/ext4/ext4.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h
index 3d85bbb..9b17916 100644
--- a/fs/ext4/ext4.h
+++ b/fs/ext4/ext4.h
@@ -1819,6 +1819,8 @@ static inline void set_bitmap_uptodate(struct buffer_head *bh)
set_bit(BH_BITMAP_UPTODATE, &(bh)->b_state);
}
+#define in_range(b, first, len) ((b) >= (first) && (b) <= (first) + (len) - 1)
+
#endif /* __KERNEL__ */
#endif /* _EXT4_H */