================================ WARNING: inconsistent lock state 5.13.0-rc7-syzkaller #0 Not tainted -------------------------------- inconsistent {IN-SOFTIRQ-W} -> {SOFTIRQ-ON-W} usage. syz-executor.2/4057 [HC0[0]:SC0[0]:HE1:SE1] takes: ffff88802cded0a0 (slock-AF_BLUETOOTH-BTPROTO_SCO){+.?.}-{2:2}, at: spin_lock include/linux/spinlock.h:354 [inline] ffff88802cded0a0 (slock-AF_BLUETOOTH-BTPROTO_SCO){+.?.}-{2:2}, at: sco_conn_del+0x113/0x2a0 net/bluetooth/sco.c:176 {IN-SOFTIRQ-W} state was registered at: lock_acquire+0x17f/0x720 kernel/locking/lockdep.c:5512 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline] _raw_spin_lock+0x2a/0x40 kernel/locking/spinlock.c:151 spin_lock include/linux/spinlock.h:354 [inline] sco_sock_timeout+0x33/0x170 net/bluetooth/sco.c:83 call_timer_fn+0xf6/0x210 kernel/time/timer.c:1431 expire_timers kernel/time/timer.c:1476 [inline] __run_timers+0x6ff/0x910 kernel/time/timer.c:1745 run_timer_softirq+0x63/0xf0 kernel/time/timer.c:1758 __do_softirq+0x372/0x7a6 kernel/softirq.c:559 invoke_softirq kernel/softirq.c:433 [inline] __irq_exit_rcu+0x245/0x280 kernel/softirq.c:637 irq_exit_rcu+0x5/0x20 kernel/softirq.c:649 sysvec_apic_timer_interrupt+0x91/0xb0 arch/x86/kernel/apic/apic.c:1100 asm_sysvec_apic_timer_interrupt+0x12/0x20 arch/x86/include/asm/idtentry.h:647 check_kcov_mode kernel/kcov.c:165 [inline] write_comp_data kernel/kcov.c:218 [inline] __sanitizer_cov_trace_const_cmp1+0x31/0xa0 kernel/kcov.c:270 tomoyo_path_matches_pattern+0x97/0x260 security/tomoyo/util.c:945 tomoyo_compare_name_union security/tomoyo/file.c:87 [inline] tomoyo_check_path_acl+0x10e/0x1c0 security/tomoyo/file.c:260 tomoyo_check_acl+0x137/0x430 security/tomoyo/domain.c:175 tomoyo_path_permission+0x1af/0x370 security/tomoyo/file.c:586 tomoyo_path_perm+0x3cd/0x650 security/tomoyo/file.c:838 security_inode_getattr+0xc0/0x140 security/security.c:1332 vfs_getattr fs/stat.c:139 [inline] vfs_statx+0x188/0x3d0 fs/stat.c:207 vfs_fstatat fs/stat.c:225 [inline] vfs_lstat include/linux/fs.h:3384 [inline] __do_sys_newlstat fs/stat.c:380 [inline] __se_sys_newlstat fs/stat.c:374 [inline] __x64_sys_newlstat+0xd3/0x150 fs/stat.c:374 do_syscall_64+0x3f/0xb0 arch/x86/entry/common.c:47 entry_SYSCALL_64_after_hwframe+0x44/0xae irq event stamp: 2686525 hardirqs last enabled at (2686525): [] __raw_spin_unlock_irq include/linux/spinlock_api_smp.h:168 [inline] hardirqs last enabled at (2686525): [] _raw_spin_unlock_irq+0x1f/0x40 kernel/locking/spinlock.c:199 hardirqs last disabled at (2686524): [] __raw_spin_lock_irq include/linux/spinlock_api_smp.h:126 [inline] hardirqs last disabled at (2686524): [] _raw_spin_lock_irq+0x89/0xf0 kernel/locking/spinlock.c:167 softirqs last enabled at (2686414): [] spin_unlock_bh include/linux/spinlock.h:399 [inline] softirqs last enabled at (2686414): [] fib6_run_gc+0x20d/0x340 net/ipv6/ip6_fib.c:2339 softirqs last disabled at (2686398): [] spin_trylock_bh include/linux/spinlock.h:414 [inline] softirqs last disabled at (2686398): [] fib6_run_gc+0x97/0x340 net/ipv6/ip6_fib.c:2321 other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(slock-AF_BLUETOOTH-BTPROTO_SCO); lock(slock-AF_BLUETOOTH-BTPROTO_SCO); *** DEADLOCK *** 4 locks held by syz-executor.2/4057: #0: ffffffff8e1b4ac8 (rfkill_global_mutex){+.+.}-{3:3}, at: rfkill_fop_write+0x14d/0x750 net/rfkill/core.c:1260 #1: ffff88801ec40f48 (&hdev->req_lock){+.+.}-{3:3}, at: hci_dev_do_close+0x176/0xfe0 net/bluetooth/hci_core.c:1735 #2: ffff88801ec40078 (&hdev->lock){+.+.}-{3:3}, at: hci_dev_do_close+0x3c3/0xfe0 net/bluetooth/hci_core.c:1772 #3: ffffffff8e0744a8 (hci_cb_list_lock){+.+.}-{3:3}, at: hci_disconn_cfm include/net/bluetooth/hci_core.h:1496 [inline] #3: ffffffff8e0744a8 (hci_cb_list_lock){+.+.}-{3:3}, at: hci_conn_hash_flush+0xb8/0x240 net/bluetooth/hci_conn.c:1608 stack backtrace: CPU: 0 PID: 4057 Comm: syz-executor.2 Not tainted 5.13.0-rc7-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:79 [inline] dump_stack+0x202/0x31e lib/dump_stack.c:120 print_usage_bug+0xd5e/0x1210 kernel/locking/lockdep.c:3808 mark_lock_irq kernel/locking/lockdep.c:3820 [inline] mark_lock+0x1708/0x1eb0 kernel/locking/lockdep.c:4480 mark_usage kernel/locking/lockdep.c:4393 [inline] __lock_acquire+0xd97/0x6040 kernel/locking/lockdep.c:4856 lock_acquire+0x17f/0x720 kernel/locking/lockdep.c:5512 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline] _raw_spin_lock+0x2a/0x40 kernel/locking/spinlock.c:151 spin_lock include/linux/spinlock.h:354 [inline] sco_conn_del+0x113/0x2a0 net/bluetooth/sco.c:176 hci_disconn_cfm include/net/bluetooth/hci_core.h:1499 [inline] hci_conn_hash_flush+0x112/0x240 net/bluetooth/hci_conn.c:1608 hci_dev_do_close+0xa04/0xfe0 net/bluetooth/hci_core.c:1785 hci_rfkill_set_block+0x10f/0x180 net/bluetooth/hci_core.c:2225 rfkill_set_block+0x1f1/0x440 net/rfkill/core.c:344 rfkill_fop_write+0x594/0x750 net/rfkill/core.c:1268 vfs_write+0x289/0xc90 fs/read_write.c:603 ksys_write+0x171/0x2a0 fs/read_write.c:658 do_syscall_64+0x3f/0xb0 arch/x86/entry/common.c:47 entry_SYSCALL_64_after_hwframe+0x44/0xae RIP: 0033:0x4665d9 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 bc ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fa6c7805188 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 000000000056bf80 RCX: 00000000004665d9 RDX: 0000000000000008 RSI: 0000000020000040 RDI: 0000000000000003 RBP: 00000000004bfcb9 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000056bf80 R13: 00007ffe019c87cf R14: 00007fa6c7805300 R15: 0000000000022000