lkml.org 
[lkml]   [2017]   [Nov]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 2/4] staging: lustre: ldlm: Remove a attribute group from a kobject
Date
All attribute group created during ldlm_setup() should be removed
in ldlm_cleanup().

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
drivers/staging/lustre/lustre/ldlm/ldlm_lockd.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_lockd.c b/drivers/staging/lustre/lustre/ldlm/ldlm_lockd.c
index 2d5a2c9..ada50b6 100644
--- a/drivers/staging/lustre/lustre/ldlm/ldlm_lockd.c
+++ b/drivers/staging/lustre/lustre/ldlm/ldlm_lockd.c
@@ -1093,8 +1093,10 @@ static int ldlm_cleanup(void)
kset_unregister(ldlm_ns_kset);
if (ldlm_svc_kset)
kset_unregister(ldlm_svc_kset);
- if (ldlm_kobj)
+ if (ldlm_kobj) {
+ sysfs_remove_group(ldlm_kobj, &ldlm_attr_group);
kobject_put(ldlm_kobj);
+ }

ldlm_debugfs_cleanup();

--
2.7.4
\
 
 \ /
  Last update: 2017-11-25 07:40    [W:0.360 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site