diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2015-09-24 20:36:33 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-09-24 23:04:53 -0700 |
commit | 9861f72074c77a8a065622c1be7e9c4277e600eb (patch) | |
tree | cba58d3959606f2f4d7dd5ea95f8a79ac73fd2ad /firmware/qlogic | |
parent | 38737e490d4ea91660d3cec83ef88c4e6d360ae4 (diff) | |
download | talos-op-linux-9861f72074c77a8a065622c1be7e9c4277e600eb.tar.gz talos-op-linux-9861f72074c77a8a065622c1be7e9c4277e600eb.zip |
net: fix net_device refcounting
of_find_net_device_by_node() uses class_find_device() internally to
lookup the corresponding network device. class_find_device() returns
a reference to the embedded struct device, with its refcount
incremented.
Add a comment to the definition in net/core/net-sysfs.c indicating the
need to drop this refcount, and fix the DSA code to drop this refcount
when the OF-generated platform data is cleaned up and freed. Also
arrange for the ref to be dropped when handling errors.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'firmware/qlogic')
0 files changed, 0 insertions, 0 deletions