提交 b067db49 编写于 作者: M Mariusz Kozlowski 提交者: Greg Kroah-Hartman

kobject: kobject_put cleanup

This patch removes redundant argument checks for kobject_put().
Signed-off-by: NMariusz Kozlowski <m.kozlowski@tuxland.pl>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 f7506536
......@@ -195,7 +195,6 @@ int kobject_add(struct kobject * kobj)
if (error) {
/* unlink does the kobject_put() for us */
unlink(kobj);
if (parent)
kobject_put(parent);
/* be noisy on error issues */
......@@ -420,7 +419,6 @@ void kobject_cleanup(struct kobject * kobj)
t->release(kobj);
if (s)
kset_put(s);
if (parent)
kobject_put(parent);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册