diff options
Diffstat (limited to 'drivers/staging/lustre/lustre/lov/lov_ea.c')
-rw-r--r-- | drivers/staging/lustre/lustre/lov/lov_ea.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/staging/lustre/lustre/lov/lov_ea.c b/drivers/staging/lustre/lustre/lov/lov_ea.c index 2bcfaeaff6fa..3f51b573e1fb 100644 --- a/drivers/staging/lustre/lustre/lov/lov_ea.c +++ b/drivers/staging/lustre/lustre/lov/lov_ea.c @@ -95,7 +95,7 @@ struct lov_stripe_md *lsm_alloc_plain(__u16 stripe_count, int *size) oinfo_ptrs_size = sizeof(struct lov_oinfo *) * stripe_count; *size = sizeof(struct lov_stripe_md) + oinfo_ptrs_size; - OBD_ALLOC_LARGE(lsm, *size); + lsm = libcfs_kvzalloc(*size, GFP_NOFS); if (!lsm) return NULL; @@ -111,7 +111,7 @@ struct lov_stripe_md *lsm_alloc_plain(__u16 stripe_count, int *size) err: while (--i >= 0) OBD_SLAB_FREE(lsm->lsm_oinfo[i], lov_oinfo_slab, sizeof(*loi)); - OBD_FREE_LARGE(lsm, *size); + kvfree(lsm); return NULL; } @@ -123,8 +123,7 @@ void lsm_free_plain(struct lov_stripe_md *lsm) for (i = 0; i < stripe_count; i++) OBD_SLAB_FREE(lsm->lsm_oinfo[i], lov_oinfo_slab, sizeof(struct lov_oinfo)); - OBD_FREE_LARGE(lsm, sizeof(struct lov_stripe_md) + - stripe_count * sizeof(struct lov_oinfo *)); + kvfree(lsm); } static void lsm_unpackmd_common(struct lov_stripe_md *lsm, |