diff options
Diffstat (limited to 'fs/btrfs/inode-map.c')
-rw-r--r-- | fs/btrfs/inode-map.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/btrfs/inode-map.c b/fs/btrfs/inode-map.c index 1f0ec19b23f6..70107f7c9307 100644 --- a/fs/btrfs/inode-map.c +++ b/fs/btrfs/inode-map.c | |||
@@ -283,7 +283,7 @@ void btrfs_unpin_free_ino(struct btrfs_root *root) | |||
283 | } | 283 | } |
284 | 284 | ||
285 | #define INIT_THRESHOLD ((SZ_32K / 2) / sizeof(struct btrfs_free_space)) | 285 | #define INIT_THRESHOLD ((SZ_32K / 2) / sizeof(struct btrfs_free_space)) |
286 | #define INODES_PER_BITMAP (PAGE_CACHE_SIZE * 8) | 286 | #define INODES_PER_BITMAP (PAGE_SIZE * 8) |
287 | 287 | ||
288 | /* | 288 | /* |
289 | * The goal is to keep the memory used by the free_ino tree won't | 289 | * The goal is to keep the memory used by the free_ino tree won't |
@@ -317,7 +317,7 @@ static void recalculate_thresholds(struct btrfs_free_space_ctl *ctl) | |||
317 | } | 317 | } |
318 | 318 | ||
319 | ctl->extents_thresh = (max_bitmaps - ctl->total_bitmaps) * | 319 | ctl->extents_thresh = (max_bitmaps - ctl->total_bitmaps) * |
320 | PAGE_CACHE_SIZE / sizeof(*info); | 320 | PAGE_SIZE / sizeof(*info); |
321 | } | 321 | } |
322 | 322 | ||
323 | /* | 323 | /* |
@@ -481,12 +481,12 @@ again: | |||
481 | 481 | ||
482 | spin_lock(&ctl->tree_lock); | 482 | spin_lock(&ctl->tree_lock); |
483 | prealloc = sizeof(struct btrfs_free_space) * ctl->free_extents; | 483 | prealloc = sizeof(struct btrfs_free_space) * ctl->free_extents; |
484 | prealloc = ALIGN(prealloc, PAGE_CACHE_SIZE); | 484 | prealloc = ALIGN(prealloc, PAGE_SIZE); |
485 | prealloc += ctl->total_bitmaps * PAGE_CACHE_SIZE; | 485 | prealloc += ctl->total_bitmaps * PAGE_SIZE; |
486 | spin_unlock(&ctl->tree_lock); | 486 | spin_unlock(&ctl->tree_lock); |
487 | 487 | ||
488 | /* Just to make sure we have enough space */ | 488 | /* Just to make sure we have enough space */ |
489 | prealloc += 8 * PAGE_CACHE_SIZE; | 489 | prealloc += 8 * PAGE_SIZE; |
490 | 490 | ||
491 | ret = btrfs_delalloc_reserve_space(inode, 0, prealloc); | 491 | ret = btrfs_delalloc_reserve_space(inode, 0, prealloc); |
492 | if (ret) | 492 | if (ret) |