lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1511591971-8615-2-git-send-email-arvind.yadav.cs@gmail.com>
Date:   Sat, 25 Nov 2017 12:09:28 +0530
From:   Arvind Yadav <arvind.yadav.cs@...il.com>
To:     gilad@...yossef.com, gregkh@...uxfoundation.org,
        oleg.drokin@...el.com, andreas.dilger@...el.com,
        jsimmons@...radead.org, paulmck@...ux.vnet.ibm.com,
        vitaly_fertman@...atex.com, yawei.niu@...el.com
Cc:     linux-kernel@...r.kernel.org, linux-crypto@...r.kernel.org,
        driverdev-devel@...uxdriverproject.org, devel@...verdev.osuosl.org,
        lustre-devel@...ts.lustre.org
Subject: [PATCH 1/4] staging: ccree: Remove a attribute group from a kobject

All attribute group created during sys_init_dir() should be removed
in sys_free_dir()

Signed-off-by: Arvind Yadav <arvind.yadav.cs@...il.com>
---
 drivers/staging/ccree/ssi_sysfs.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/ccree/ssi_sysfs.c b/drivers/staging/ccree/ssi_sysfs.c
index 5d39f15..14a3f32 100644
--- a/drivers/staging/ccree/ssi_sysfs.c
+++ b/drivers/staging/ccree/ssi_sysfs.c
@@ -145,8 +145,11 @@ static void sys_free_dir(struct sys_dir *sys_dir)
 
 	kfree(sys_dir->sys_dir_attr_list);
 
-	if (sys_dir->sys_dir_kobj)
+	if (sys_dir->sys_dir_kobj) {
+		sysfs_remove_group(sys_dir->sys_dir_kobj,
+				   &sys_dir->sys_dir_attr_group);
 		kobject_put(sys_dir->sys_dir_kobj);
+	}
 }
 
 int ssi_sysfs_init(struct kobject *sys_dev_obj, struct ssi_drvdata *drvdata)
-- 
2.7.4

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ