mirror of
https://github.com/torvalds/linux.git
synced 2026-01-25 15:03:52 +08:00
net: lapbether: use netdev_lockdep_set_classes() helper
drivers/net/wan/lapbether.c uses stacked devices. Like similar drivers, it must use netdev_lockdep_set_classes() to avoid LOCKDEP splats. This is similar to commit9bfc9d65a1("hamradio: use netdev_lockdep_set_classes() helper") Fixes:7e4d784f58("net: hold netdev instance lock during rtnetlink operations") Reported-by: syzbot+377b71db585c9c705f8e@syzkaller.appspotmail.com Closes: https://lore.kernel.org/lkml/67cd611c.050a0220.14db68.0073.GAE@google.com/T/#u Signed-off-by: Eric Dumazet <edumazet@google.com> Acked-by: Stanislav Fomichev <sdf@fomichev.me> Link: https://patch.msgid.link/20250327144439.2463509-1-edumazet@google.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
committed by
Jakub Kicinski
parent
4f1eaabb4b
commit
7220e8f4d4
@@ -39,6 +39,7 @@
|
||||
#include <linux/lapb.h>
|
||||
#include <linux/init.h>
|
||||
|
||||
#include <net/netdev_lock.h>
|
||||
#include <net/x25device.h>
|
||||
|
||||
static const u8 bcast_addr[6] = { 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF };
|
||||
@@ -366,6 +367,7 @@ static const struct net_device_ops lapbeth_netdev_ops = {
|
||||
|
||||
static void lapbeth_setup(struct net_device *dev)
|
||||
{
|
||||
netdev_lockdep_set_classes(dev);
|
||||
dev->netdev_ops = &lapbeth_netdev_ops;
|
||||
dev->needs_free_netdev = true;
|
||||
dev->type = ARPHRD_X25;
|
||||
|
||||
Reference in New Issue
Block a user