mirror of
https://github.com/torvalds/linux.git
synced 2026-09-22 12:44:03 +02:00
wifi: mac80211: use ifa_dev from event argument
During address teardown, the netdevice's ip_ptr might be cleared before the inetaddr notifier is called. In this case, __in_dev_get_rtnl() returns NULL, causing the notifier to abort early and fail to update the ARP filter. Fix this by using the in_device pointer from the event argument (ifa->ifa_dev) which is guaranteed to be valid. Cc: Ido Schimmel <idosch@nvidia.com> Cc: Kuniyuki Iwashima <kuniyu@google.com> Signed-off-by: Yuyang Huang <yuyanghuang@google.com> Link: https://patch.msgid.link/20260711005405.2861680-3-yuyanghuang@google.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
3cbbc9fa33
commit
e5b14e9ae8
|
|
@ -588,9 +588,7 @@ static int ieee80211_ifa_changed(struct notifier_block *nb,
|
|||
if (sdata->vif.type != NL80211_IFTYPE_STATION)
|
||||
return NOTIFY_DONE;
|
||||
|
||||
idev = __in_dev_get_rtnl(sdata->dev);
|
||||
if (!idev)
|
||||
return NOTIFY_DONE;
|
||||
idev = ifa->ifa_dev;
|
||||
|
||||
ifmgd = &sdata->u.mgd;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user