YueHaibing a3e23f719f 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 <hulkci@huawei.com>
Fixes: d0d668371679 ("net: don't decrement kobj reference count on init failure")
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2019-03-19 13:45:58 -07:00
..
2018-12-25 17:07:49 +09:00
2019-01-23 11:18:00 -08:00
2018-11-10 16:55:11 -08:00
2018-10-22 19:59:20 -07:00
2019-01-27 10:38:04 -08:00
2019-02-21 16:23:56 -08:00
2019-03-09 15:53:03 -08:00
2019-03-08 14:48:40 -08:00
2018-07-24 14:10:42 -07:00
2019-03-11 15:40:14 -07:00
2019-03-16 01:27:51 +01:00
2019-03-15 15:29:47 -07:00