diff options
| author | YueHaibing <[email protected]> | 2019-03-19 10:16:53 +0800 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2019-03-19 13:45:58 -0700 |
| commit | a3e23f719f5c4a38ffb3d30c8d7632a4ed8ccd9e (patch) | |
| tree | 18873532e319e52799711a7bfc4bd1e8d69787c4 /lib | |
| parent | 223a960c01227e4dbcb6f9fa06b47d73bda21274 (diff) | |
net-sysfs: call dev_hold if kobject_init_and_add success
In netdev_queue_add_kobject and rx_queue_add_kobject,
if sysfs_create_group failed, kobject_put will call
netdev_queue_release to decrease dev refcont, however
dev_hold has not be called. So we will see this while
unregistering dev:
unregister_netdevice: waiting for bcsh0 to become free. Usage count = -1
Reported-by: Hulk Robot <[email protected]>
Fixes: d0d668371679 ("net: don't decrement kobj reference count on init failure")
Signed-off-by: YueHaibing <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'lib')
0 files changed, 0 insertions, 0 deletions