------------[ cut here ]------------ sysfs group 'byte_queue_limits' not found for kobject 'tx-0' WARNING: CPU: 0 PID: 9255 at fs/sysfs/group.c:280 sysfs_remove_group+0x174/0x288 fs/sysfs/group.c:278 Modules linked in: CPU: 0 PID: 9255 Comm: kbnepd bnep0 Not tainted 6.1.116-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 pstate: 60400005 (nZCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--) pc : sysfs_remove_group+0x174/0x288 fs/sysfs/group.c:278 lr : sysfs_remove_group+0x174/0x288 fs/sysfs/group.c:278 sp : ffff8000226d7840 x29: ffff8000226d7840 x28: 1fffe0001b8d08ca x27: 1fffe0001b8d0888 x26: 0000000000000000 x25: 00000000ffffffff x24: 1ffff00002860bdc x23: dfff800000000000 x22: dfff800000000000 x21: ffff0000d82ab020 x20: ffff0000ef87ebc8 x19: ffff8000143065c0 x18: 1fffe0003679ed76 x17: ffff8000159dd000 x16: ffff800008305dfc x15: ffff0001b3cf6bbc x14: 1ffff00002b3c0b0 x13: dfff800000000000 x12: 0000000000000003 x11: 0000000000ff0100 x10: 0000000000000003 x9 : e9cae21035808300 x8 : e9cae21035808300 x7 : ffff80000827d390 x6 : 0000000000000000 x5 : 0000000000000080 x4 : 0000000000000001 x3 : 0000000000000000 x2 : 0000000000000006 x1 : ffff8000123ec5e0 x0 : ffff80019e3c3000 Call trace: sysfs_remove_group+0x174/0x288 fs/sysfs/group.c:278 netdev_queue_update_kobjects+0x3d4/0x470 net/core/net-sysfs.c:1729 remove_queue_kobjects net/core/net-sysfs.c:1828 [inline] netdev_unregister_kobject+0x100/0x204 net/core/net-sysfs.c:1981 unregister_netdevice_many+0x11b8/0x175c net/core/dev.c:10917 unregister_netdevice_queue net/core/dev.c:10821 [inline] unregister_netdevice include/linux/netdevice.h:3045 [inline] unregister_netdev+0x178/0x1f0 net/core/dev.c:10949 bnep_session+0x23c4/0x2584 net/bluetooth/bnep/core.c:525 kthread+0x250/0x2d8 kernel/kthread.c:376 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:864 irq event stamp: 7120 hardirqs last enabled at (7119): [] raw_spin_rq_unlock_irq kernel/sched/sched.h:1367 [inline] hardirqs last enabled at (7119): [] finish_lock_switch+0xbc/0x1e8 kernel/sched/core.c:5000 hardirqs last disabled at (7120): [] el1_dbg+0x24/0x80 arch/arm64/kernel/entry-common.c:405 softirqs last enabled at (7026): [] spin_unlock_bh include/linux/spinlock.h:396 [inline] softirqs last enabled at (7026): [] netif_addr_unlock_bh include/linux/netdevice.h:4480 [inline] softirqs last enabled at (7026): [] dev_mc_flush+0x1b4/0x1f8 net/core/dev_addr_lists.c:1036 softirqs last disabled at (7024): [] local_bh_disable+0x10/0x34 include/linux/bottom_half.h:19 ---[ end trace 0000000000000000 ]--- ================================================================== BUG: KASAN: use-after-free in device_for_each_child+0xa8/0x174 drivers/base/core.c:4015 Read of size 8 at addr ffff0000f16a94c0 by task kbnepd bnep0/9255 CPU: 0 PID: 9255 Comm: kbnepd bnep0 Tainted: G W 6.1.116-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 Call trace: dump_backtrace+0x1c8/0x1f4 arch/arm64/kernel/stacktrace.c:158 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:165 __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x108/0x170 lib/dump_stack.c:106 print_address_description mm/kasan/report.c:284 [inline] print_report+0x174/0x4c0 mm/kasan/report.c:395 kasan_report+0xd4/0x130 mm/kasan/report.c:495 __asan_report_load8_noabort+0x2c/0x38 mm/kasan/report_generic.c:351 device_for_each_child+0xa8/0x174 drivers/base/core.c:4015 pm_runtime_set_memalloc_noio+0xf0/0x210 drivers/base/power/runtime.c:246 netdev_unregister_kobject+0x144/0x204 net/core/net-sysfs.c:1983 unregister_netdevice_many+0x11b8/0x175c net/core/dev.c:10917 unregister_netdevice_queue net/core/dev.c:10821 [inline] unregister_netdevice include/linux/netdevice.h:3045 [inline] unregister_netdev+0x178/0x1f0 net/core/dev.c:10949 bnep_session+0x23c4/0x2584 net/bluetooth/bnep/core.c:525 kthread+0x250/0x2d8 kernel/kthread.c:376 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:864 Allocated by task 7883: kasan_save_stack mm/kasan/common.c:45 [inline] kasan_set_track+0x4c/0x80 mm/kasan/common.c:52 kasan_save_alloc_info+0x24/0x30 mm/kasan/generic.c:505 ____kasan_kmalloc mm/kasan/common.c:374 [inline] __kasan_kmalloc+0xac/0xc4 mm/kasan/common.c:383 kasan_kmalloc include/linux/kasan.h:211 [inline] __do_kmalloc_node mm/slab_common.c:936 [inline] __kmalloc+0xd8/0x1c4 mm/slab_common.c:949 kmalloc include/linux/slab.h:562 [inline] kzalloc include/linux/slab.h:693 [inline] hci_alloc_dev_priv+0x30/0x18a8 net/bluetooth/hci_core.c:2436 hci_alloc_dev include/net/bluetooth/hci_core.h:1470 [inline] __vhci_create_device drivers/bluetooth/hci_vhci.c:308 [inline] vhci_create_device+0xf8/0x6d0 drivers/bluetooth/hci_vhci.c:379 vhci_get_user drivers/bluetooth/hci_vhci.c:436 [inline] vhci_write+0x318/0x3b8 drivers/bluetooth/hci_vhci.c:516 call_write_iter include/linux/fs.h:2265 [inline] new_sync_write fs/read_write.c:491 [inline] vfs_write+0x610/0x91c fs/read_write.c:584 ksys_write+0x15c/0x26c fs/read_write.c:637 __do_sys_write fs/read_write.c:649 [inline] __se_sys_write fs/read_write.c:646 [inline] __arm64_sys_write+0x7c/0x90 fs/read_write.c:646 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2c0 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:140 do_el0_svc+0x64/0x218 arch/arm64/kernel/syscall.c:204 el0_svc+0x58/0x168 arch/arm64/kernel/entry-common.c:637 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655 el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:585 Freed by task 7883: kasan_save_stack mm/kasan/common.c:45 [inline] kasan_set_track+0x4c/0x80 mm/kasan/common.c:52 kasan_save_free_info+0x38/0x5c mm/kasan/generic.c:516 ____kasan_slab_free+0x144/0x1c0 mm/kasan/common.c:236 __kasan_slab_free+0x18/0x28 mm/kasan/common.c:244 kasan_slab_free include/linux/kasan.h:177 [inline] slab_free_hook mm/slub.c:1724 [inline] slab_free_freelist_hook mm/slub.c:1750 [inline] slab_free mm/slub.c:3661 [inline] __kmem_cache_free+0x2c0/0x4b4 mm/slub.c:3674 kfree+0xcc/0x1b8 mm/slab_common.c:988 hci_release_dev+0x1064/0x11cc net/bluetooth/hci_core.c:2767 bt_host_release+0x70/0x88 net/bluetooth/hci_sysfs.c:92 device_release+0x8c/0x1ac kobject_cleanup lib/kobject.c:681 [inline] kobject_release lib/kobject.c:712 [inline] kref_put include/linux/kref.h:65 [inline] kobject_put+0x2a8/0x41c lib/kobject.c:729 put_device+0x28/0x40 drivers/base/core.c:3797 hci_free_dev+0x24/0x34 net/bluetooth/hci_core.c:2559 vhci_release+0x84/0xcc drivers/bluetooth/hci_vhci.c:574 __fput+0x1c8/0x7c8 fs/file_table.c:320 ____fput+0x20/0x30 fs/file_table.c:348 task_work_run+0x240/0x2f0 kernel/task_work.c:203 exit_task_work include/linux/task_work.h:39 [inline] do_exit+0x554/0x1a88 kernel/exit.c:871 do_group_exit+0x194/0x22c kernel/exit.c:1021 __do_sys_exit_group kernel/exit.c:1032 [inline] __se_sys_exit_group kernel/exit.c:1030 [inline] __wake_up_parent+0x0/0x60 kernel/exit.c:1030 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2c0 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:140 do_el0_svc+0x64/0x218 arch/arm64/kernel/syscall.c:204 el0_svc+0x58/0x168 arch/arm64/kernel/entry-common.c:637 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655 el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:585 Last potentially related work creation: kasan_save_stack+0x40/0x70 mm/kasan/common.c:45 __kasan_record_aux_stack+0xcc/0xe8 mm/kasan/generic.c:486 kasan_record_aux_stack_noalloc+0x14/0x20 mm/kasan/generic.c:496 insert_work+0x64/0x384 kernel/workqueue.c:1361 __queue_work+0xd48/0x136c kernel/workqueue.c:1520 queue_work_on+0xc0/0x16c kernel/workqueue.c:1548 queue_work include/linux/workqueue.h:512 [inline] hci_send_acl+0x904/0xc48 net/bluetooth/hci_core.c:3238 l2cap_do_send+0x238/0x350 l2cap_chan_send+0x190c/0x1e5c l2cap_sock_sendmsg+0x184/0x2a8 net/bluetooth/l2cap_sock.c:1162 sock_sendmsg_nosec net/socket.c:718 [inline] __sock_sendmsg net/socket.c:730 [inline] sock_sendmsg net/socket.c:753 [inline] kernel_sendmsg+0x1c8/0x2a0 net/socket.c:777 bnep_tx_frame net/bluetooth/bnep/core.c:466 [inline] bnep_session+0x1f28/0x2584 net/bluetooth/bnep/core.c:509 kthread+0x250/0x2d8 kernel/kthread.c:376 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:864 Second to last potentially related work creation: kasan_save_stack+0x40/0x70 mm/kasan/common.c:45 __kasan_record_aux_stack+0xcc/0xe8 mm/kasan/generic.c:486 kasan_record_aux_stack_noalloc+0x14/0x20 mm/kasan/generic.c:496 insert_work+0x64/0x384 kernel/workqueue.c:1361 __queue_work+0xd48/0x136c kernel/workqueue.c:1520 queue_work_on+0xc0/0x16c kernel/workqueue.c:1548 queue_work include/linux/workqueue.h:512 [inline] hci_recv_frame+0x43c/0x548 net/bluetooth/hci_core.c:2932 vhci_get_user drivers/bluetooth/hci_vhci.c:420 [inline] vhci_write+0x2a4/0x3b8 drivers/bluetooth/hci_vhci.c:516 call_write_iter include/linux/fs.h:2265 [inline] new_sync_write fs/read_write.c:491 [inline] vfs_write+0x610/0x91c fs/read_write.c:584 ksys_write+0x15c/0x26c fs/read_write.c:637 __do_sys_write fs/read_write.c:649 [inline] __se_sys_write fs/read_write.c:646 [inline] __arm64_sys_write+0x7c/0x90 fs/read_write.c:646 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2c0 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:140 do_el0_svc+0x64/0x218 arch/arm64/kernel/syscall.c:204 el0_svc+0x58/0x168 arch/arm64/kernel/entry-common.c:637 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655 el0t_64_sync+0x18c/0x190 arch/arm64/kernel/entry.S:585 The buggy address belongs to the object at ffff0000f16a8000 which belongs to the cache kmalloc-8k of size 8192 The buggy address is located 5312 bytes inside of 8192-byte region [ffff0000f16a8000, ffff0000f16aa000) The buggy address belongs to the physical page: page:00000000e04e1486 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1316a8 head:00000000e04e1486 order:3 compound_mapcount:0 compound_pincount:0 flags: 0x5ffc00000010200(slab|head|node=0|zone=2|lastcpupid=0x7ff) raw: 05ffc00000010200 0000000000000000 dead000000000001 ffff0000c0002c00 raw: 0000000000000000 0000000000020002 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff0000f16a9380: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff0000f16a9400: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff0000f16a9480: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff0000f16a9500: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff0000f16a9580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ================================================================== ================================================================================ UBSAN: array-index-out-of-bounds in kernel/locking/qspinlock.c:131:9 index 15815 is out of range for type 'unsigned long[8]' CPU: 1 PID: 9255 Comm: kbnepd bnep0 Tainted: G B W 6.1.116-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 Call trace: dump_backtrace+0x1c8/0x1f4 arch/arm64/kernel/stacktrace.c:158 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:165 __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x108/0x170 lib/dump_stack.c:106 dump_stack+0x1c/0x58 lib/dump_stack.c:113 ubsan_epilogue lib/ubsan.c:151 [inline] __ubsan_handle_out_of_bounds+0xfc/0x148 lib/ubsan.c:282 decode_tail kernel/locking/qspinlock.c:131 [inline] queued_spin_lock_slowpath+0x9fc/0xe48 kernel/locking/qspinlock.c:471 queued_spin_lock include/asm-generic/qspinlock.h:114 [inline] do_raw_spin_lock+0x330/0x358 kernel/locking/spinlock_debug.c:115 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:111 [inline] _raw_spin_lock_irqsave+0x74/0xb4 kernel/locking/spinlock.c:162 klist_next+0x8c/0x2e4 lib/klist.c:382 next_device drivers/base/core.c:3940 [inline] device_for_each_child+0xc0/0x174 drivers/base/core.c:4019 pm_runtime_set_memalloc_noio+0xf0/0x210 drivers/base/power/runtime.c:246 netdev_unregister_kobject+0x144/0x204 net/core/net-sysfs.c:1983 unregister_netdevice_many+0x11b8/0x175c net/core/dev.c:10917 unregister_netdevice_queue net/core/dev.c:10821 [inline] unregister_netdevice include/linux/netdevice.h:3045 [inline] unregister_netdev+0x178/0x1f0 net/core/dev.c:10949 bnep_session+0x23c4/0x2584 net/bluetooth/bnep/core.c:525 kthread+0x250/0x2d8 kernel/kthread.c:376 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:864 ================================================================================