Commit 35dbf4ef authored by Viresh Kumar's avatar Viresh Kumar Committed by Greg Kroah-Hartman

driver core: don't initialize 'parent' in device_add()

'parent' is always overwritten before getting used and there is no need
to initialize it with NULL.
Signed-off-by: default avatarViresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 0dd89119
...@@ -1607,7 +1607,7 @@ int device_private_init(struct device *dev) ...@@ -1607,7 +1607,7 @@ int device_private_init(struct device *dev)
*/ */
int device_add(struct device *dev) int device_add(struct device *dev)
{ {
struct device *parent = NULL; struct device *parent;
struct kobject *kobj; struct kobject *kobj;
struct class_interface *class_intf; struct class_interface *class_intf;
int error = -EINVAL; int error = -EINVAL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment