From b541c998ca327fb22a1817be98dade1f328c2f06 Mon Sep 17 00:00:00 2001 From: tianzy <tianzy> Date: Fri, 16 Feb 2007 07:00:50 +0000 Subject: [PATCH] fix the warnings b=11471 --- lustre/lov/lov_internal.h | 2 +- lustre/lov/lov_obd.c | 11 +++++------ 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/lustre/lov/lov_internal.h b/lustre/lov/lov_internal.h index 903aeb4ef8..7099226760 100644 --- a/lustre/lov/lov_internal.h +++ b/lustre/lov/lov_internal.h @@ -71,7 +71,7 @@ struct lov_async_page { (LASSERT(((struct lov_async_page *)(c))->lap_magic == LOV_AP_MAGIC), \ (struct lov_async_page *)(c)) -extern kmem_cache_t *lov_oinfo_slab; +extern cfs_mem_cache_t *lov_oinfo_slab; static inline void lov_llh_addref(void *llhp) { diff --git a/lustre/lov/lov_obd.c b/lustre/lov/lov_obd.c index a533d913f9..db81ef9171 100644 --- a/lustre/lov/lov_obd.c +++ b/lustre/lov/lov_obd.c @@ -2628,7 +2628,7 @@ struct obd_ops lov_obd_ops = { static quota_interface_t *quota_interface; extern quota_interface_t lov_quota_interface; -kmem_cache_t *lov_oinfo_slab; +cfs_mem_cache_t *lov_oinfo_slab; int __init lov_init(void) { @@ -2636,9 +2636,8 @@ int __init lov_init(void) int rc, rc2; ENTRY; - lov_oinfo_slab = kmem_cache_create("lov_oinfo", - sizeof(struct lov_oinfo), 0, - SLAB_HWCACHE_ALIGN, NULL, NULL); + lov_oinfo_slab = cfs_mem_cache_create("lov_oinfo", + sizeof(struct lov_oinfo), 0, 0); if (lov_oinfo_slab == NULL) return -ENOMEM; lprocfs_init_vars(lov, &lvars); @@ -2652,7 +2651,7 @@ int __init lov_init(void) if (rc) { if (quota_interface) PORTAL_SYMBOL_PUT(lov_quota_interface); - rc2 = kmem_cache_destroy(lov_oinfo_slab); + rc2 = cfs_mem_cache_destroy(lov_oinfo_slab); LASSERT(rc2 == 0); } @@ -2668,7 +2667,7 @@ static void /*__exit*/ lov_exit(void) PORTAL_SYMBOL_PUT(lov_quota_interface); class_unregister_type(LUSTRE_LOV_NAME); - rc = kmem_cache_destroy(lov_oinfo_slab); + rc = cfs_mem_cache_destroy(lov_oinfo_slab); LASSERT(rc == 0); } -- GitLab