================================ WARNING: inconsistent lock state 4.14.231-syzkaller #0 Not tainted -------------------------------- inconsistent {SOFTIRQ-ON-W} -> {IN-SOFTIRQ-W} usage. syz-executor.3/15625 [HC0[0]:SC1[1]:HE1:SE0] takes: (slock-AF_BLUETOOTH-BTPROTO_SCO){+.?.}, at: [] spin_lock include/linux/spinlock.h:317 [inline] (slock-AF_BLUETOOTH-BTPROTO_SCO){+.?.}, at: [] sco_sock_timeout+0x29/0x1c0 net/bluetooth/sco.c:82 EXT4-fs (loop5): Ignoring removed bh option {SOFTIRQ-ON-W} state was registered at: lock_acquire+0x170/0x3f0 kernel/locking/lockdep.c:3998 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline] _raw_spin_lock+0x2a/0x40 kernel/locking/spinlock.c:152 spin_lock include/linux/spinlock.h:317 [inline] sco_conn_del+0xbf/0x290 net/bluetooth/sco.c:175 sco_disconn_cfm+0x65/0xa0 net/bluetooth/sco.c:1134 hci_disconn_cfm include/net/bluetooth/hci_core.h:1226 [inline] hci_conn_hash_flush+0x127/0x260 net/bluetooth/hci_conn.c:1393 hci_dev_do_close+0x535/0xca0 net/bluetooth/hci_core.c:1622 hci_unregister_dev+0x17f/0x8c0 net/bluetooth/hci_core.c:3193 vhci_release+0x70/0xe0 drivers/bluetooth/hci_vhci.c:354 __fput+0x25f/0x7a0 fs/file_table.c:210 task_work_run+0x11f/0x190 kernel/task_work.c:113 exit_task_work include/linux/task_work.h:22 [inline] do_exit+0xa44/0x2850 kernel/exit.c:868 do_group_exit+0x100/0x2e0 kernel/exit.c:965 SYSC_exit_group kernel/exit.c:976 [inline] SyS_exit_group+0x19/0x20 kernel/exit.c:974 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292 EXT4-fs (loop5): mounted filesystem without journal. Opts: resgid=0x0000000000000000,minixdf,norecovery,nojournal_checksum,inode_readahead_blks=0x0000000000000000,jqfmt=vfsv0,bh,noquota,,errors=continue entry_SYSCALL_64_after_hwframe+0x46/0xbb irq event stamp: 24440 hardirqs last enabled at (24440): [] restore_regs_and_return_to_kernel+0x0/0x2a hardirqs last disabled at (24439): [] apic_timer_interrupt+0x8e/0xa0 arch/x86/entry/entry_64.S:793 softirqs last enabled at (23794): [] __do_softirq+0x68b/0x9ff kernel/softirq.c:314 softirqs last disabled at (24421): [] invoke_softirq kernel/softirq.c:368 [inline] softirqs last disabled at (24421): [] irq_exit+0x193/0x240 kernel/softirq.c:409 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 *** 1 lock held by syz-executor.3/15625: #0: (((&sk->sk_timer))#2){+.-.}, at: [] lockdep_copy_map include/linux/lockdep.h:174 [inline] #0: (((&sk->sk_timer))#2){+.-.}, at: [] call_timer_fn+0xb8/0x650 kernel/time/timer.c:1270 stack backtrace: CPU: 0 PID: 15625 Comm: syz-executor.3 Not tainted 4.14.231-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x1b2/0x281 lib/dump_stack.c:58 print_usage_bug.cold+0x42e/0x570 kernel/locking/lockdep.c:2589 valid_state kernel/locking/lockdep.c:2602 [inline] mark_lock_irq kernel/locking/lockdep.c:2796 [inline] mark_lock+0xb4d/0x1050 kernel/locking/lockdep.c:3194 mark_irqflags kernel/locking/lockdep.c:3072 [inline] __lock_acquire+0xc81/0x3f20 kernel/locking/lockdep.c:3448 lock_acquire+0x170/0x3f0 kernel/locking/lockdep.c:3998 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline] _raw_spin_lock+0x2a/0x40 kernel/locking/spinlock.c:152 spin_lock include/linux/spinlock.h:317 [inline] sco_sock_timeout+0x29/0x1c0 net/bluetooth/sco.c:82 call_timer_fn+0x14a/0x650 kernel/time/timer.c:1280 expire_timers+0x232/0x4d0 kernel/time/timer.c:1319 __run_timers kernel/time/timer.c:1637 [inline] run_timer_softirq+0x1d5/0x5a0 kernel/time/timer.c:1650 __do_softirq+0x24d/0x9ff kernel/softirq.c:288 invoke_softirq kernel/softirq.c:368 [inline] irq_exit+0x193/0x240 kernel/softirq.c:409 exiting_irq arch/x86/include/asm/apic.h:638 [inline] smp_apic_timer_interrupt+0x141/0x5e0 arch/x86/kernel/apic/apic.c:1106 apic_timer_interrupt+0x93/0xa0 arch/x86/entry/entry_64.S:793 RIP: 0010:_copy_from_user+0x0/0x100 lib/usercopy.c:8 RSP: 0018:ffff888049967a10 EFLAGS: 00000246 ORIG_RAX: ffffffffffffff10 RAX: 0000000000040000 RBX: ffff888049967dd0 RCX: ffffc900075ba000 RDX: 0000000000000038 RSI: 0000000020018bc0 RDI: ffff888049967a40 RBP: 1ffff1100932cf44 R08: 000000000000061e R09: ffff88823fff700f R10: ffff88823fff7017 R11: 000000531cb33df6 R12: ffff888049967b58 R13: 0000000020018bc0 R14: ffff888049967b38 R15: dffffc0000000000 copy_from_user include/linux/uaccess.h:147 [inline] copy_msghdr_from_user+0x7b/0x3b0 net/socket.c:1943 ___sys_recvmsg+0xe5/0x4d0 net/socket.c:2209 __sys_recvmmsg+0x1f3/0x5d0 net/socket.c:2329 SYSC_recvmmsg net/socket.c:2410 [inline] SyS_recvmmsg+0xaf/0x140 net/socket.c:2394 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x46/0xbb RIP: 0033:0x4665f9 RSP: 002b:00007f13aea78188 EFLAGS: 00000246 ORIG_RAX: 000000000000012b RAX: ffffffffffffffda RBX: 000000000056bf60 RCX: 00000000004665f9 RDX: 00000000000006f5 RSI: 0000000020000440 RDI: 0000000000000004 RBP: 00000000004bfbb9 R08: 0000000020000480 R09: 0000000000000000 R10: 0000002000000022 R11: 0000000000000246 R12: 000000000056bf60 R13: 00007ffcb1998b8f R14: 00007f13aea78300 R15: 0000000000022000 EXT4-fs (loop5): Ignoring removed bh option caif:caif_disconnect_client(): nothing to disconnect EXT4-fs (loop2): mounted filesystem without journal. Opts: ,errors=continue EXT4-fs (loop5): mounted filesystem without journal. Opts: resgid=0x0000000000000000,minixdf,norecovery,nojournal_checksum,inode_readahead_blks=0x0000000000000000,jqfmt=vfsv0,bh,noquota,,errors=continue caif:caif_disconnect_client(): nothing to disconnect EXT4-fs error (device loop2): ext4_mb_generate_buddy:754: group 0, block bitmap and bg descriptor inconsistent: 50 vs 25 free clusters EXT4-fs (loop5): Ignoring removed bh option audit: type=1804 audit(1619343276.248:38): pid=15712 uid=0 auid=4294967295 ses=4294967295 op="invalid_pcr" cause="open_writers" comm="syz-executor.2" name="/root/syzkaller-testdir024380335/syzkaller.uAQrsP/46/file0/bus" dev="ramfs" ino=44438 res=1 EXT4-fs (loop5): mounted filesystem without journal. Opts: resgid=0x0000000000000000,minixdf,norecovery,nojournal_checksum,inode_readahead_blks=0x0000000000000000,jqfmt=vfsv0,bh,noquota,,errors=continue xt_CONNSECMARK: invalid mode: 0 audit: type=1804 audit(1619343276.248:39): pid=15712 uid=0 auid=4294967295 ses=4294967295 op="invalid_pcr" cause="ToMToU" comm="syz-executor.2" name="/root/syzkaller-testdir024380335/syzkaller.uAQrsP/46/file0/bus" dev="ramfs" ino=44438 res=1 audit: type=1804 audit(1619343276.248:40): pid=15712 uid=0 auid=4294967295 ses=4294967295 op="invalid_pcr" cause="ToMToU" comm="syz-executor.2" name="/root/syzkaller-testdir024380335/syzkaller.uAQrsP/46/file0/bus" dev="ramfs" ino=44438 res=1 audit: type=1804 audit(1619343276.298:41): pid=15717 uid=0 auid=4294967295 ses=4294967295 op="invalid_pcr" cause="open_writers" comm="syz-executor.2" name="/root/syzkaller-testdir024380335/syzkaller.uAQrsP/46/file0/file0/bus" dev="ramfs" ino=44444 res=1 xt_CONNSECMARK: invalid mode: 0 audit: type=1804 audit(1619343276.298:42): pid=15717 uid=0 auid=4294967295 ses=4294967295 op="invalid_pcr" cause="ToMToU" comm="syz-executor.2" name="/root/syzkaller-testdir024380335/syzkaller.uAQrsP/46/file0/file0/bus" dev="ramfs" ino=44444 res=1 audit: type=1804 audit(1619343276.298:43): pid=15717 uid=0 auid=4294967295 ses=4294967295 op="invalid_pcr" cause="ToMToU" comm="syz-executor.2" name="/root/syzkaller-testdir024380335/syzkaller.uAQrsP/46/file0/file0/bus" dev="ramfs" ino=44444 res=1 EXT4-fs (loop5): Ignoring removed bh option audit: type=1804 audit(1619343276.598:44): pid=15731 uid=0 auid=4294967295 ses=4294967295 op="invalid_pcr" cause="open_writers" comm="syz-executor.2" name="/root/syzkaller-testdir024380335/syzkaller.uAQrsP/47/file0/bus" dev="ramfs" ino=45622 res=1 audit: type=1804 audit(1619343276.608:45): pid=15731 uid=0 auid=4294967295 ses=4294967295 op="invalid_pcr" cause="ToMToU" comm="syz-executor.2" name="/root/syzkaller-testdir024380335/syzkaller.uAQrsP/47/file0/bus" dev="ramfs" ino=45622 res=1 EXT4-fs (loop5): mounted filesystem without journal. Opts: resgid=0x0000000000000000,minixdf,norecovery,nojournal_checksum,inode_readahead_blks=0x0000000000000000,jqfmt=vfsv0,bh,noquota,,errors=continue audit: type=1804 audit(1619343276.608:46): pid=15731 uid=0 auid=4294967295 ses=4294967295 op="invalid_pcr" cause="ToMToU" comm="syz-executor.2" name="/root/syzkaller-testdir024380335/syzkaller.uAQrsP/47/file0/bus" dev="ramfs" ino=45622 res=1 xt_CONNSECMARK: invalid mode: 0 audit: type=1804 audit(1619343276.958:47): pid=15754 uid=0 auid=4294967295 ses=4294967295 op="invalid_pcr" cause="open_writers" comm="syz-executor.2" name="/root/syzkaller-testdir024380335/syzkaller.uAQrsP/48/file0/bus" dev="ramfs" ino=44481 res=1 xt_CONNSECMARK: invalid mode: 0 serio: Serial port pts0 xt_connlimit: cannot load conntrack support for address family 10 xt_connlimit: cannot load conntrack support for address family 10 mkiss: ax0: crc mode is auto. serio: Serial port pts2 mkiss: ax0: crc mode is auto. serio: Serial port pts2 mkiss: ax0: crc mode is auto. serio: Serial port pts2 mkiss: ax0: crc mode is auto. mkiss: ax0: crc mode is auto. overlayfs: upperdir is in-use by another mount, mount with '-o index=off' to override exclusive upperdir protection. device syzkaller1 entered promiscuous mode hid-generic 0000:0000:0000.0001: item fetching failed at offset 0/1 hid-generic: probe of 0000:0000:0000.0001 failed with error -22 device syzkaller1 entered promiscuous mode hid-generic 0000:0000:0000.0002: item fetching failed at offset 0/1 hid-generic: probe of 0000:0000:0000.0002 failed with error -22 encrypted_key: master key parameter '' is invalid encrypted_key: master key parameter '' is invalid encrypted_key: master key parameter '' is invalid device syzkaller1 entered promiscuous mode encrypted_key: master key parameter '' is invalid encrypted_key: master key parameter '' is invalid device syzkaller1 entered promiscuous mode