diff options
author | Jakub Kicinski <kuba@kernel.org> | 2025-01-05 02:00:43 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2025-01-05 02:00:44 +0100 |
commit | a4faa15d28f4afb0a7d6213894175e612f825cd6 (patch) | |
tree | 76fbff0b28fbcdd5bde3bd5d8c3a7d0ab16038b2 /net | |
parent | selftests: tc-testing: reduce rshift value (diff) | |
parent | mac802154: check local interfaces before deleting sdata list (diff) | |
download | linux-a4faa15d28f4afb0a7d6213894175e612f825cd6.tar.xz linux-a4faa15d28f4afb0a7d6213894175e612f825cd6.zip |
Merge tag 'ieee802154-for-net-2025-01-03' of git://git.kernel.org/pub/scm/linux/kernel/git/wpan/wpan
Stefan Schmidt says:
====================
pull-request: ieee802154 for net 2025-01-03
Keisuke Nishimura provided a fix to check for kfifo_alloc() in the ca8210
driver.
Lizhi Xu provided a fix a corrupted list, found by syzkaller, by checking local
interfaces first.
* tag 'ieee802154-for-net-2025-01-03' of git://git.kernel.org/pub/scm/linux/kernel/git/wpan/wpan:
mac802154: check local interfaces before deleting sdata list
ieee802154: ca8210: Add missing check for kfifo_alloc() in ca8210_probe()
====================
Link: https://patch.msgid.link/20250103160046.469363-1-stefan@datenfreihafen.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net')
-rw-r--r-- | net/mac802154/iface.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/net/mac802154/iface.c b/net/mac802154/iface.c index c0e2da5072be..9e4631fade90 100644 --- a/net/mac802154/iface.c +++ b/net/mac802154/iface.c @@ -684,6 +684,10 @@ void ieee802154_if_remove(struct ieee802154_sub_if_data *sdata) ASSERT_RTNL(); mutex_lock(&sdata->local->iflist_mtx); + if (list_empty(&sdata->local->interfaces)) { + mutex_unlock(&sdata->local->iflist_mtx); + return; + } list_del_rcu(&sdata->list); mutex_unlock(&sdata->local->iflist_mtx); |