================================ WARNING: inconsistent lock state 4.19.103-syzkaller #0 Not tainted -------------------------------- inconsistent {SOFTIRQ-ON-W} -> {IN-SOFTIRQ-W} usage. syz-fuzzer/8087 [HC0[0]:SC1[1]:HE1:SE0] takes: 00000000e62d9ee6 (&(&local->client_conns_lock)->rlock){+.?.}, at: spin_lock include/linux/spinlock.h:329 [inline] 00000000e62d9ee6 (&(&local->client_conns_lock)->rlock){+.?.}, at: rxrpc_put_one_client_conn net/rxrpc/conn_client.c:949 [inline] 00000000e62d9ee6 (&(&local->client_conns_lock)->rlock){+.?.}, at: rxrpc_put_client_conn+0x683/0xc20 net/rxrpc/conn_client.c:1002 {SOFTIRQ-ON-W} state was registered at: lock_acquire+0x16f/0x3f0 kernel/locking/lockdep.c:3903 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline] _raw_spin_lock+0x2f/0x40 kernel/locking/spinlock.c:144 spin_lock include/linux/spinlock.h:329 [inline] rxrpc_get_client_conn net/rxrpc/conn_client.c:309 [inline] rxrpc_connect_call+0x351/0x4920 net/rxrpc/conn_client.c:702 rxrpc_new_client_call+0x8e7/0x1880 net/rxrpc/call_object.c:291 rxrpc_new_client_call_for_sendmsg net/rxrpc/sendmsg.c:596 [inline] rxrpc_do_sendmsg+0xfc3/0x1ca3 net/rxrpc/sendmsg.c:652 rxrpc_sendmsg+0x4a0/0x5b0 net/rxrpc/af_rxrpc.c:593 sock_sendmsg_nosec net/socket.c:622 [inline] sock_sendmsg+0xd7/0x130 net/socket.c:632 ___sys_sendmsg+0x3e2/0x920 net/socket.c:2115 __sys_sendmmsg+0x1bf/0x4e0 net/socket.c:2210 __do_sys_sendmmsg net/socket.c:2239 [inline] __se_sys_sendmmsg net/socket.c:2236 [inline] __x64_sys_sendmmsg+0x9d/0x100 net/socket.c:2236 do_syscall_64+0xfd/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe irq event stamp: 181734 hardirqs last enabled at (181734): [] __raw_spin_unlock_irqrestore include/linux/spinlock_api_smp.h:160 [inline] hardirqs last enabled at (181734): [] _raw_spin_unlock_irqrestore+0x6b/0xe0 kernel/locking/spinlock.c:184 hardirqs last disabled at (181733): [] __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:108 [inline] hardirqs last disabled at (181733): [] _raw_spin_lock_irqsave+0x6f/0xcd kernel/locking/spinlock.c:152 softirqs last enabled at (181364): [] __do_softirq+0x633/0x921 kernel/softirq.c:318 softirqs last disabled at (181575): [] invoke_softirq kernel/softirq.c:372 [inline] softirqs last disabled at (181575): [] irq_exit+0x180/0x1d0 kernel/softirq.c:412 other info that might help us debug this: Possible unsafe locking scenario: CPU0 ---- lock(&(&local->client_conns_lock)->rlock); lock(&(&local->client_conns_lock)->rlock); *** DEADLOCK *** 2 locks held by syz-fuzzer/8087: #0: 00000000ae937205 (&mm->mmap_sem){++++}, at: __do_page_fault+0x3c9/0xe90 arch/x86/mm/fault.c:1319 #1: 00000000dbcf7e29 (rcu_callback){....}, at: __rcu_reclaim kernel/rcu/rcu.h:226 [inline] #1: 00000000dbcf7e29 (rcu_callback){....}, at: rcu_do_batch kernel/rcu/tree.c:2584 [inline] #1: 00000000dbcf7e29 (rcu_callback){....}, at: invoke_rcu_callbacks kernel/rcu/tree.c:2897 [inline] #1: 00000000dbcf7e29 (rcu_callback){....}, at: __rcu_process_callbacks kernel/rcu/tree.c:2864 [inline] #1: 00000000dbcf7e29 (rcu_callback){....}, at: rcu_process_callbacks+0xc79/0x1a30 kernel/rcu/tree.c:2881 stack backtrace: CPU: 0 PID: 8087 Comm: syz-fuzzer Not tainted 4.19.103-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x197/0x210 lib/dump_stack.c:118 print_usage_bug.cold+0x330/0x42a kernel/locking/lockdep.c:2540 valid_state kernel/locking/lockdep.c:2553 [inline] mark_lock_irq kernel/locking/lockdep.c:2747 [inline] mark_lock+0xd1b/0x1370 kernel/locking/lockdep.c:3127 mark_irqflags kernel/locking/lockdep.c:3005 [inline] __lock_acquire+0xc62/0x49c0 kernel/locking/lockdep.c:3368 lock_acquire+0x16f/0x3f0 kernel/locking/lockdep.c:3903 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline] _raw_spin_lock+0x2f/0x40 kernel/locking/spinlock.c:144 spin_lock include/linux/spinlock.h:329 [inline] rxrpc_put_one_client_conn net/rxrpc/conn_client.c:949 [inline] rxrpc_put_client_conn+0x683/0xc20 net/rxrpc/conn_client.c:1002 rxrpc_put_connection net/rxrpc/ar-internal.h:951 [inline] rxrpc_rcu_destroy_call+0xbd/0x200 net/rxrpc/call_object.c:657 __rcu_reclaim kernel/rcu/rcu.h:236 [inline] rcu_do_batch kernel/rcu/tree.c:2584 [inline] invoke_rcu_callbacks kernel/rcu/tree.c:2897 [inline] __rcu_process_callbacks kernel/rcu/tree.c:2864 [inline] rcu_process_callbacks+0xba0/0x1a30 kernel/rcu/tree.c:2881 __do_softirq+0x25c/0x921 kernel/softirq.c:292 invoke_softirq kernel/softirq.c:372 [inline] irq_exit+0x180/0x1d0 kernel/softirq.c:412 exiting_irq arch/x86/include/asm/apic.h:544 [inline] smp_apic_timer_interrupt+0x13b/0x550 arch/x86/kernel/apic/apic.c:1094 apic_timer_interrupt+0xf/0x20 arch/x86/entry/entry_64.S:893 RIP: 0010:___might_sleep+0x1f4/0x2b0 kernel/sched/core.c:6157 Code: 84 d2 74 05 e8 dd 74 59 00 41 f6 46 24 02 0f 85 b3 fe ff ff e9 ea fe ff ff be ff ff ff ff 48 c7 c7 a0 34 f9 88 e8 ac 3b 08 00 <85> c0 0f 84 2f fe ff ff 48 c7 c2 60 35 aa 87 be 0d 18 00 00 48 c7 RSP: 0000:ffff88807bc4f8e8 EFLAGS: 00000296 ORIG_RAX: ffffffffffffff13 RAX: 0000000000000000 RBX: 0000000000000000 RCX: ffff888088bcac80 RDX: dffffc0000000000 RSI: ffffffff88f934a0 RDI: 0000000000000282 RBP: ffff88807bc4f910 R08: ffff888088bca400 R09: 0000000000000001 R10: ffff888088bcaca8 R11: ffffffff8a799420 R12: ffffffff87b17260 R13: 00000000000010f6 R14: 0000000000000000 R15: 0000000000000001 __might_sleep+0x95/0x190 kernel/sched/core.c:6145 prepare_alloc_pages mm/page_alloc.c:4342 [inline] __alloc_pages_nodemask+0x4ec/0x750 mm/page_alloc.c:4391 alloc_pages_vma+0xdd/0x590 mm/mempolicy.c:2161 alloc_zeroed_user_highpage_movable include/linux/highmem.h:184 [inline] wp_page_copy+0xc75/0x16a0 mm/memory.c:2508 do_wp_page+0x57d/0x10b0 mm/memory.c:2799 handle_pte_fault mm/memory.c:4057 [inline] __handle_mm_fault+0x2305/0x3f80 mm/memory.c:4165 handle_mm_fault+0x1b5/0x690 mm/memory.c:4202 __do_page_fault+0x62a/0xe90 arch/x86/mm/fault.c:1390 do_page_fault+0x71/0x57d arch/x86/mm/fault.c:1465 page_fault+0x1e/0x30 arch/x86/entry/entry_64.S:1204 RIP: 0033:0x40ad42 Code: 00 83 e1 0f bf 01 00 00 00 d3 e7 66 39 fa 73 8b 4d 85 d2 74 32 48 c1 e8 38 3c 04 73 03 83 c0 04 41 84 02 4d 89 c1 49 83 e0 07 <43> 88 04 02 4c 89 d0 4b 8d 4c 8a 08 8b 54 24 58 89 11 48 ff 03 49 RSP: 002b:000000c4288f5b78 EFLAGS: 00010246 RAX: 000000000000001b RBX: 000000c4299d5830 RCX: 000000000000000a RDX: 0000000000000000 RSI: 0000000000866760 RDI: 0000000000000400 RBP: 000000c4288f5bb0 R08: 0000000000000000 R09: 0000000000000000 R10: 000000c429a3e300 R11: 0000000000000004 R12: 0000000000000000 R13: 0000000000000018 R14: 0000000000000057 R15: 0000000000000100 loop3: p1 p2 p3 p4 loop3: p1 size 11290111 extends beyond EOD, truncated loop3: p2 size 1073741824 extends beyond EOD, truncated loop3: p3 size 1912633224 extends beyond EOD, truncated loop3: p4 size 3657465856 extends beyond EOD, truncated loop3: p1 p2 p3 p4 loop3: p1 size 11290111 extends beyond EOD, truncated loop3: p2 size 1073741824 extends beyond EOD, truncated loop3: p3 size 1912633224 extends beyond EOD, truncated loop3: p4 size 3657465856 extends beyond EOD, truncated loop3: p1 p2 p3 p4 loop3: p1 size 11290111 extends beyond EOD, truncated loop3: p2 size 1073741824 extends beyond EOD, truncated loop3: p3 size 1912633224 extends beyond EOD, truncated loop3: p4 size 3657465856 extends beyond EOD, truncated loop3: p1 p2 p3 p4 loop3: p1 size 11290111 extends beyond EOD, truncated loop3: p2 size 1073741824 extends beyond EOD, truncated loop3: p3 size 1912633224 extends beyond EOD, truncated loop3: p4 size 3657465856 extends beyond EOD, truncated audit: type=1804 audit(1581434511.459:88): pid=10018 uid=0 auid=4294967295 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 op=invalid_pcr cause=open_writers comm="syz-executor.5" name="/root/syzkaller-testdir298014258/syzkaller.h37ArO/72/file0" dev="sda1" ino=16717 res=1 hid-generic 0000:0000:0000.0001: ignoring exceeding usage max hid-generic 0000:0000:0000.0001: hidraw0: HID v0.00 Device [syz1] on sz1 audit: type=1804 audit(1581434511.609:89): pid=10018 uid=0 auid=4294967295 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 op=invalid_pcr cause=open_writers comm="syz-executor.5" name="/root/syzkaller-testdir298014258/syzkaller.h37ArO/72/file0" dev="sda1" ino=16717 res=1 hid-generic 0000:0000:0000.0002: ignoring exceeding usage max hid-generic 0000:0000:0000.0002: hidraw0: HID v0.00 Device [syz1] on sz1 hid-generic 0000:0000:0000.0003: ignoring exceeding usage max audit: type=1804 audit(1581434511.869:90): pid=10066 uid=0 auid=4294967295 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 op=invalid_pcr cause=open_writers comm="syz-executor.5" name="/root/syzkaller-testdir298014258/syzkaller.h37ArO/73/file0" dev="sda1" ino=16742 res=1 hid-generic 0000:0000:0000.0003: hidraw0: HID v0.00 Device [syz1] on sz1 hid-generic 0000:0000:0000.0004: ignoring exceeding usage max hid-generic 0000:0000:0000.0004: hidraw0: HID v0.00 Device [syz1] on sz1 hid-generic 0000:0000:0000.0005: ignoring exceeding usage max hid-generic 0000:0000:0000.0005: hidraw0: HID v0.00 Device [syz1] on sz1 audit: type=1804 audit(1581434514.919:91): pid=10118 uid=0 auid=4294967295 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 op=invalid_pcr cause=open_writers comm="syz-executor.5" name="/root/syzkaller-testdir298014258/syzkaller.h37ArO/74/file0" dev="sda1" ino=16752 res=1