aboutsummaryrefslogtreecommitdiffstats
path: root/fs/reiserfs/super.c
diff options
context:
space:
mode:
authorJeff Mahoney <jeffm@suse.com>2006-10-01 02:28:40 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2006-10-01 03:39:27 -0400
commite1fabd3ccf02901374bffa434e0af472749a5bd9 (patch)
tree66d618e98020422874a521142ca2da797c9930f3 /fs/reiserfs/super.c
parent8ef386092d7c2891bd7acefb2a87f878f7e9a0d6 (diff)
[PATCH] reiserfs: fix is_reusable bitmap check to not traverse the bitmap info array
There is a check in is_reusable to determine if a particular block is a bitmap block. It verifies this by going through the array of bitmap block buffer heads and comparing the block number to each one. Bitmap blocks are at defined locations on the disk in both old and current formats. Simply checking against the known good values is enough. This is a trivial optimization for a non-production codepath, but this is the first in a series of patches that will ultimately remove the buffer heads from that array. Signed-off-by: Jeff Mahoney <jeffm@suse.com> Cc: <reiserfs-dev@namesys.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/reiserfs/super.c')
-rw-r--r--fs/reiserfs/super.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/reiserfs/super.c b/fs/reiserfs/super.c
index 80fc3b32802f..db2c581df766 100644
--- a/fs/reiserfs/super.c
+++ b/fs/reiserfs/super.c
@@ -1818,6 +1818,8 @@ static int reiserfs_fill_super(struct super_block *s, void *data, int silent)
1818 if (is_reiserfs_3_5(rs) 1818 if (is_reiserfs_3_5(rs)
1819 || (is_reiserfs_jr(rs) && SB_VERSION(s) == REISERFS_VERSION_1)) 1819 || (is_reiserfs_jr(rs) && SB_VERSION(s) == REISERFS_VERSION_1))
1820 set_bit(REISERFS_3_5, &(sbi->s_properties)); 1820 set_bit(REISERFS_3_5, &(sbi->s_properties));
1821 else if (old_format)
1822 set_bit(REISERFS_OLD_FORMAT, &(sbi->s_properties));
1821 else 1823 else
1822 set_bit(REISERFS_3_6, &(sbi->s_properties)); 1824 set_bit(REISERFS_3_6, &(sbi->s_properties));
1823 1825