aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/linux-2.6/xfs_buf.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@infradead.org>2010-01-20 16:55:30 -0500
committerAlex Elder <aelder@sgi.com>2010-01-21 14:44:56 -0500
commitbdfb04301fa5fdd95f219539a9a5b9663b1e5fc2 (patch)
tree6d50b1c71d1f227cf1800ee0531a475266ef6da8 /fs/xfs/linux-2.6/xfs_buf.c
parenta14a348bff2f99471a28e5928eb6801224c053d8 (diff)
xfs: replace KM_LARGE with explicit vmalloc use
We use the KM_LARGE flag to make kmem_alloc and friends use vmalloc if necessary. As we only need this for a few boot/mount time allocations just switch to explicit vmalloc calls there. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Alex Elder <aelder@sgi.com>
Diffstat (limited to 'fs/xfs/linux-2.6/xfs_buf.c')
-rw-r--r--fs/xfs/linux-2.6/xfs_buf.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/xfs/linux-2.6/xfs_buf.c b/fs/xfs/linux-2.6/xfs_buf.c
index 730eff1e71a3..44e20e578ba0 100644
--- a/fs/xfs/linux-2.6/xfs_buf.c
+++ b/fs/xfs/linux-2.6/xfs_buf.c
@@ -1525,8 +1525,8 @@ xfs_alloc_bufhash(
1525 1525
1526 btp->bt_hashshift = external ? 3 : 8; /* 8 or 256 buckets */ 1526 btp->bt_hashshift = external ? 3 : 8; /* 8 or 256 buckets */
1527 btp->bt_hashmask = (1 << btp->bt_hashshift) - 1; 1527 btp->bt_hashmask = (1 << btp->bt_hashshift) - 1;
1528 btp->bt_hash = kmem_zalloc((1 << btp->bt_hashshift) * 1528 btp->bt_hash = kmem_zalloc_large((1 << btp->bt_hashshift) *
1529 sizeof(xfs_bufhash_t), KM_SLEEP | KM_LARGE); 1529 sizeof(xfs_bufhash_t));
1530 for (i = 0; i < (1 << btp->bt_hashshift); i++) { 1530 for (i = 0; i < (1 << btp->bt_hashshift); i++) {
1531 spin_lock_init(&btp->bt_hash[i].bh_lock); 1531 spin_lock_init(&btp->bt_hash[i].bh_lock);
1532 INIT_LIST_HEAD(&btp->bt_hash[i].bh_list); 1532 INIT_LIST_HEAD(&btp->bt_hash[i].bh_list);
@@ -1537,7 +1537,7 @@ STATIC void
1537xfs_free_bufhash( 1537xfs_free_bufhash(
1538 xfs_buftarg_t *btp) 1538 xfs_buftarg_t *btp)
1539{ 1539{
1540 kmem_free(btp->bt_hash); 1540 kmem_free_large(btp->bt_hash);
1541 btp->bt_hash = NULL; 1541 btp->bt_hash = NULL;
1542} 1542}
1543 1543