aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/Perf-Trace-Util/lib/Perf/Trace/SchedGui.py
diff options
context:
space:
mode:
authorBreno Leitao <[email protected]>2024-04-22 05:38:55 -0700
committerDavid S. Miller <[email protected]>2024-04-24 12:00:16 +0100
commitf8d05679fb3faae478d604177b0c188b340371cd (patch)
treea3ac18731f0c1f73eaf0f543355fa9be968a1410 /tools/perf/scripts/python/Perf-Trace-Util/lib/Perf/Trace/SchedGui.py
parentc6e7f276841d9a31009766f3e6f33e00cf3d93ed (diff)
net: free_netdev: exit earlier if dummy
For dummy devices, exit earlier at free_netdev() instead of executing the whole function. This is necessary, because dummy devices are special, and shouldn't have the second part of the function executed. Otherwise reg_state, which is NETREG_DUMMY, will be overwritten and there will be no way to identify that this is a dummy device. Also, this device do not need the final put_device(), since dummy devices are not registered (through register_netdevice()), where the device reference is increased (at netdev_register_kobject()/device_add()). Suggested-by: Jakub Kicinski <[email protected]> Signed-off-by: Breno Leitao <[email protected]> Reviewed-by: Ido Schimmel <[email protected]> Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/Perf-Trace-Util/lib/Perf/Trace/SchedGui.py')
0 files changed, 0 insertions, 0 deletions