lov_exit and osc_exit explicitly called lu_device_type_fini() right
before calling class_unregister_type().
However class_unregister_type() will call lu_device_type_fini() too,
which means lov_device_type and osc_device_type will be finalized
twice.
This can be fixed by removing lu_device_type_fini() calls from
lov_exit and osc_exit.
Signed-off-by: Liang Zhen <liang@whamcloud.com>
Change-Id: I12dea692f4d2bdd75bb1640b71c6dcc392b94478
Reviewed-on: http://review.whamcloud.com/2823
Tested-by: Hudson
Reviewed-by: Fan Yong <yong.fan@whamcloud.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@whamcloud.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
{
int rc;
- lu_device_type_fini(&lov_device_type);
- lu_kmem_fini(lov_caches);
-
if (quota_interface)
PORTAL_SYMBOL_PUT(lov_quota_interface);
class_unregister_type(LUSTRE_LOV_NAME);
rc = cfs_mem_cache_destroy(lov_oinfo_slab);
LASSERT(rc == 0);
+
+ lu_kmem_fini(lov_caches);
}
MODULE_AUTHOR("Sun Microsystems, Inc. <http://www.lustre.org/>");
#ifdef __KERNEL__
static void /*__exit*/ osc_exit(void)
{
- lu_device_type_fini(&osc_device_type);
-
- osc_quota_exit();
- class_unregister_type(LUSTRE_OSC_NAME);
- lu_kmem_fini(osc_caches);
+ osc_quota_exit();
+ class_unregister_type(LUSTRE_OSC_NAME);
+ lu_kmem_fini(osc_caches);
}
MODULE_AUTHOR("Sun Microsystems, Inc. <http://www.lustre.org/>");