aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/nilfs2/alloc.c2
-rw-r--r--fs/nilfs2/btree.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/fs/nilfs2/alloc.c b/fs/nilfs2/alloc.c
index 2c90e285d7c6..03b8ba933eb2 100644
--- a/fs/nilfs2/alloc.c
+++ b/fs/nilfs2/alloc.c
@@ -34,7 +34,7 @@
34static inline unsigned long 34static inline unsigned long
35nilfs_palloc_groups_per_desc_block(const struct inode *inode) 35nilfs_palloc_groups_per_desc_block(const struct inode *inode)
36{ 36{
37 return (1UL << inode->i_blkbits) / 37 return i_blocksize(inode) /
38 sizeof(struct nilfs_palloc_group_desc); 38 sizeof(struct nilfs_palloc_group_desc);
39} 39}
40 40
diff --git a/fs/nilfs2/btree.c b/fs/nilfs2/btree.c
index 9c7ea176ab0f..06ffa135dfa6 100644
--- a/fs/nilfs2/btree.c
+++ b/fs/nilfs2/btree.c
@@ -119,7 +119,7 @@ nilfs_btree_node_set_nchildren(struct nilfs_btree_node *node, int nchildren)
119 119
120static int nilfs_btree_node_size(const struct nilfs_bmap *btree) 120static int nilfs_btree_node_size(const struct nilfs_bmap *btree)
121{ 121{
122 return 1 << btree->b_inode->i_blkbits; 122 return i_blocksize(btree->b_inode);
123} 123}
124 124
125static int nilfs_btree_nchildren_per_block(const struct nilfs_bmap *btree) 125static int nilfs_btree_nchildren_per_block(const struct nilfs_bmap *btree)