diff options
author | Dave Chinner <dchinner@redhat.com> | 2014-06-06 01:18:10 -0400 |
---|---|---|
committer | Dave Chinner <david@fromorbit.com> | 2014-06-06 01:18:10 -0400 |
commit | ed358c0058fc7d97807c92333a4e06117a4be5fe (patch) | |
tree | 3002d3a1a07275100e7be86ec34743ef861342ed /fs/xfs | |
parent | 8f66193c89f0b0259db6b27b4df3deb828c294f9 (diff) |
xfs: convert dir/attr btree threshold to xfs_da_geometry
Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
Diffstat (limited to 'fs/xfs')
-rw-r--r-- | fs/xfs/xfs_attr_leaf.c | 2 | ||||
-rw-r--r-- | fs/xfs/xfs_dir2.c | 2 | ||||
-rw-r--r-- | fs/xfs/xfs_dir2_node.c | 2 | ||||
-rw-r--r-- | fs/xfs/xfs_mount.h | 2 |
4 files changed, 2 insertions, 6 deletions
diff --git a/fs/xfs/xfs_attr_leaf.c b/fs/xfs/xfs_attr_leaf.c index 2c0fdc8a71f6..5be77b3a9bc4 100644 --- a/fs/xfs/xfs_attr_leaf.c +++ b/fs/xfs/xfs_attr_leaf.c | |||
@@ -1949,7 +1949,7 @@ xfs_attr3_leaf_remove( | |||
1949 | tmp = ichdr.usedbytes + xfs_attr3_leaf_hdr_size(leaf) + | 1949 | tmp = ichdr.usedbytes + xfs_attr3_leaf_hdr_size(leaf) + |
1950 | ichdr.count * sizeof(xfs_attr_leaf_entry_t); | 1950 | ichdr.count * sizeof(xfs_attr_leaf_entry_t); |
1951 | 1951 | ||
1952 | return tmp < mp->m_attr_magicpct; /* leaf is < 37% full */ | 1952 | return tmp < args->geo->magicpct; /* leaf is < 37% full */ |
1953 | } | 1953 | } |
1954 | 1954 | ||
1955 | /* | 1955 | /* |
diff --git a/fs/xfs/xfs_dir2.c b/fs/xfs/xfs_dir2.c index 2685552480f0..aafe5e12c8d9 100644 --- a/fs/xfs/xfs_dir2.c +++ b/fs/xfs/xfs_dir2.c | |||
@@ -146,9 +146,7 @@ xfs_da_mount( | |||
146 | 146 | ||
147 | /* XXX: these are to be removed as code is converted to use geo */ | 147 | /* XXX: these are to be removed as code is converted to use geo */ |
148 | mp->m_dir_node_ents = mp->m_dir_geo->node_ents; | 148 | mp->m_dir_node_ents = mp->m_dir_geo->node_ents; |
149 | mp->m_dir_magicpct = mp->m_dir_geo->magicpct; | ||
150 | mp->m_attr_node_ents = mp->m_attr_geo->node_ents; | 149 | mp->m_attr_node_ents = mp->m_attr_geo->node_ents; |
151 | mp->m_attr_magicpct = mp->m_attr_geo->magicpct; | ||
152 | return 0; | 150 | return 0; |
153 | } | 151 | } |
154 | 152 | ||
diff --git a/fs/xfs/xfs_dir2_node.c b/fs/xfs/xfs_dir2_node.c index ef34c197b62f..de5b29965ff5 100644 --- a/fs/xfs/xfs_dir2_node.c +++ b/fs/xfs/xfs_dir2_node.c | |||
@@ -1312,7 +1312,7 @@ xfs_dir2_leafn_remove( | |||
1312 | */ | 1312 | */ |
1313 | *rval = (dp->d_ops->leaf_hdr_size + | 1313 | *rval = (dp->d_ops->leaf_hdr_size + |
1314 | (uint)sizeof(ents[0]) * (leafhdr.count - leafhdr.stale)) < | 1314 | (uint)sizeof(ents[0]) * (leafhdr.count - leafhdr.stale)) < |
1315 | mp->m_dir_magicpct; | 1315 | args->geo->magicpct; |
1316 | return 0; | 1316 | return 0; |
1317 | } | 1317 | } |
1318 | 1318 | ||
diff --git a/fs/xfs/xfs_mount.h b/fs/xfs/xfs_mount.h index 4e3f6cebebc6..78ae7e48aef6 100644 --- a/fs/xfs/xfs_mount.h +++ b/fs/xfs/xfs_mount.h | |||
@@ -148,8 +148,6 @@ typedef struct xfs_mount { | |||
148 | int m_dalign; /* stripe unit */ | 148 | int m_dalign; /* stripe unit */ |
149 | int m_swidth; /* stripe width */ | 149 | int m_swidth; /* stripe width */ |
150 | int m_sinoalign; /* stripe unit inode alignment */ | 150 | int m_sinoalign; /* stripe unit inode alignment */ |
151 | int m_attr_magicpct;/* 37% of the blocksize */ | ||
152 | int m_dir_magicpct; /* 37% of the dir blocksize */ | ||
153 | __uint8_t m_sectbb_log; /* sectlog - BBSHIFT */ | 151 | __uint8_t m_sectbb_log; /* sectlog - BBSHIFT */ |
154 | const struct xfs_nameops *m_dirnameops; /* vector of dir name ops */ | 152 | const struct xfs_nameops *m_dirnameops; /* vector of dir name ops */ |
155 | const struct xfs_dir_ops *m_dir_inode_ops; /* vector of dir inode ops */ | 153 | const struct xfs_dir_ops *m_dir_inode_ops; /* vector of dir inode ops */ |