diff options
author | Kuniyuki Iwashima <[email protected]> | 2024-08-09 16:54:03 -0700 |
---|---|---|
committer | Jakub Kicinski <[email protected]> | 2024-08-15 18:56:13 -0700 |
commit | 6e701eb914124cf260a8b9a4350740f9a7407fc7 (patch) | |
tree | af7b53f89cce64f33d54ae04266f64fb6284b1e4 /tools/perf/scripts/python/stackcollapse.py | |
parent | e3af3d3c5b26c33a7950e34e137584f6056c4319 (diff) |
ipv4: Set ifa->ifa_dev in inet_alloc_ifa().
When a new IPv4 address is assigned via ioctl(SIOCSIFADDR),
inet_set_ifa() sets ifa->ifa_dev if it's different from in_dev
passed as an argument.
In this case, ifa is always a newly allocated object, and
ifa->ifa_dev is NULL.
inet_set_ifa() can be called for an existing reused ifa, then,
this check is always false.
Let's set ifa_dev in inet_alloc_ifa() and remove the check
in inet_set_ifa().
Now, inet_alloc_ifa() is symmetric with inet_rcu_free_ifa().
Signed-off-by: Kuniyuki Iwashima <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions