================================ WARNING: inconsistent lock state 5.5.0-syzkaller #0 Not tainted -------------------------------- inconsistent {SOFTIRQ-ON-W} -> {IN-SOFTIRQ-W} usage. syz-executor.3/11610 [HC0[0]:SC1[1]:HE1:SE0] takes: ffff88809fd679c8 (&(&local->client_conns_lock)->rlock){+.?.}, at: spin_lock include/linux/spinlock.h:338 [inline] ffff88809fd679c8 (&(&local->client_conns_lock)->rlock){+.?.}, at: rxrpc_put_one_client_conn net/rxrpc/conn_client.c:948 [inline] ffff88809fd679c8 (&(&local->client_conns_lock)->rlock){+.?.}, at: rxrpc_put_client_conn+0x6ed/0xc90 net/rxrpc/conn_client.c:1001 {SOFTIRQ-ON-W} state was registered at: lock_acquire+0x190/0x410 kernel/locking/lockdep.c:4484 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline] _raw_spin_lock+0x2f/0x40 kernel/locking/spinlock.c:151 spin_lock include/linux/spinlock.h:338 [inline] rxrpc_get_client_conn net/rxrpc/conn_client.c:304 [inline] rxrpc_connect_call+0x358/0x4e30 net/rxrpc/conn_client.c:701 rxrpc_new_client_call+0x9c0/0x1ad0 net/rxrpc/call_object.c:290 rxrpc_new_client_call_for_sendmsg net/rxrpc/sendmsg.c:595 [inline] rxrpc_do_sendmsg+0xffa/0x1d5f net/rxrpc/sendmsg.c:652 rxrpc_sendmsg+0x4d6/0x5f0 net/rxrpc/af_rxrpc.c:586 sock_sendmsg_nosec net/socket.c:652 [inline] sock_sendmsg+0xd7/0x130 net/socket.c:672 ____sys_sendmsg+0x358/0x880 net/socket.c:2343 ___sys_sendmsg+0x100/0x170 net/socket.c:2397 __sys_sendmmsg+0x1bf/0x4d0 net/socket.c:2487 __do_sys_sendmmsg net/socket.c:2516 [inline] __se_sys_sendmmsg net/socket.c:2513 [inline] __x64_sys_sendmmsg+0x9d/0x100 net/socket.c:2513 do_syscall_64+0xfa/0x790 arch/x86/entry/common.c:294 entry_SYSCALL_64_after_hwframe+0x49/0xbe irq event stamp: 14722 hardirqs last enabled at (14722): [] __raw_spin_unlock_irqrestore include/linux/spinlock_api_smp.h:160 [inline] hardirqs last enabled at (14722): [] _raw_spin_unlock_irqrestore+0x66/0xe0 kernel/locking/spinlock.c:191 hardirqs last disabled at (14721): [] __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:108 [inline] hardirqs last disabled at (14721): [] _raw_spin_lock_irqsave+0x6f/0xcd kernel/locking/spinlock.c:159 softirqs last enabled at (14212): [] __do_softirq+0x6cd/0x98c kernel/softirq.c:319 softirqs last disabled at (14551): [] invoke_softirq kernel/softirq.c:373 [inline] softirqs last disabled at (14551): [] irq_exit+0x19b/0x1e0 kernel/softirq.c:413 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 *** 4 locks held by syz-executor.3/11610: #0: ffff8880a3570120 (&f->f_pos_lock){+.+.}, at: __fdget_pos+0xee/0x110 fs/file.c:821 #1: ffff8880993a2428 (sb_writers#3){.+.+}, at: file_start_write include/linux/fs.h:2897 [inline] #1: ffff8880993a2428 (sb_writers#3){.+.+}, at: vfs_write+0x485/0x5d0 fs/read_write.c:557 #2: ffff8880a1b9f488 (&sb->s_type->i_mutex_key#11){++++}, at: inode_lock include/linux/fs.h:791 [inline] #2: ffff8880a1b9f488 (&sb->s_type->i_mutex_key#11){++++}, at: ext4_buffered_write_iter+0xba/0x460 fs/ext4/file.c:264 #3: ffffffff89babac0 (rcu_callback){....}, at: rcu_do_batch kernel/rcu/tree.c:2176 [inline] #3: ffffffff89babac0 (rcu_callback){....}, at: rcu_core+0x562/0x1390 kernel/rcu/tree.c:2410 stack backtrace: CPU: 0 PID: 11610 Comm: syz-executor.3 Not tainted 5.5.0-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+0x327/0x378 kernel/locking/lockdep.c:3100 valid_state kernel/locking/lockdep.c:3111 [inline] mark_lock_irq kernel/locking/lockdep.c:3308 [inline] mark_lock+0xbb4/0x1220 kernel/locking/lockdep.c:3665 mark_usage kernel/locking/lockdep.c:3565 [inline] __lock_acquire+0x1e8e/0x4a00 kernel/locking/lockdep.c:3908 lock_acquire+0x190/0x410 kernel/locking/lockdep.c:4484 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline] _raw_spin_lock+0x2f/0x40 kernel/locking/spinlock.c:151 spin_lock include/linux/spinlock.h:338 [inline] rxrpc_put_one_client_conn net/rxrpc/conn_client.c:948 [inline] rxrpc_put_client_conn+0x6ed/0xc90 net/rxrpc/conn_client.c:1001 rxrpc_put_connection net/rxrpc/ar-internal.h:965 [inline] rxrpc_rcu_destroy_call+0xbd/0x200 net/rxrpc/call_object.c:572 rcu_do_batch kernel/rcu/tree.c:2186 [inline] rcu_core+0x5e1/0x1390 kernel/rcu/tree.c:2410 rcu_core_si+0x9/0x10 kernel/rcu/tree.c:2419 __do_softirq+0x262/0x98c kernel/softirq.c:292 invoke_softirq kernel/softirq.c:373 [inline] irq_exit+0x19b/0x1e0 kernel/softirq.c:413 exiting_irq arch/x86/include/asm/apic.h:536 [inline] smp_apic_timer_interrupt+0x1a3/0x610 arch/x86/kernel/apic/apic.c:1137 apic_timer_interrupt+0xf/0x20 arch/x86/entry/entry_64.S:829 RIP: 0010:copy_user_enhanced_fast_string+0xe/0x30 arch/x86/lib/copy_user_64.S:205 Code: 89 d1 c1 e9 03 83 e2 07 f3 48 a5 89 d1 f3 a4 31 c0 0f 1f 00 c3 0f 1f 80 00 00 00 00 0f 1f 00 83 fa 40 0f 82 70 ff ff ff 89 d1 a4 31 c0 0f 1f 00 c3 66 2e 0f 1f 84 00 00 00 00 00 89 d1 f3 a4 RSP: 0018:ffffc90001cf7900 EFLAGS: 00010206 ORIG_RAX: ffffffffffffff13 RAX: 0000000000000001 RBX: 0000000000001000 RCX: 0000000000000340 RDX: 0000000000001000 RSI: 00000000201a4d40 RDI: ffff888054704cc0 RBP: ffffc90001cf7938 R08: ffffed100a8e0a00 R09: 0000000000000000 R10: ffffed100a8e09ff R11: ffff888054704fff R12: 00000000201a4080 R13: ffff888054704000 R14: 00000000201a5080 R15: 00007ffffffff000 iov_iter_copy_from_user_atomic+0x41b/0xc10 lib/iov_iter.c:999 generic_perform_write+0x2ac/0x540 mm/filemap.c:3295 ext4_buffered_write_iter+0x1fe/0x460 fs/ext4/file.c:270 ext4_file_write_iter+0x1fe/0x14e0 fs/ext4/file.c:642 call_write_iter include/linux/fs.h:1902 [inline] new_sync_write+0x4d3/0x770 fs/read_write.c:483 __vfs_write+0xe1/0x110 fs/read_write.c:496 vfs_write+0x268/0x5d0 fs/read_write.c:558 ksys_write+0x14f/0x290 fs/read_write.c:611 __do_sys_write fs/read_write.c:623 [inline] __se_sys_write fs/read_write.c:620 [inline] __x64_sys_write+0x73/0xb0 fs/read_write.c:620 do_syscall_64+0xfa/0x790 arch/x86/entry/common.c:294 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x45b399 Code: ad b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 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 0f 83 7b b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007fc838788c78 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 00007fc8387896d4 RCX: 000000000045b399 RDX: 00000000015d4b87 RSI: 0000000020000080 RDI: 000000000000000a RBP: 000000000075bf20 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00000000ffffffff R13: 0000000000000cac R14: 00000000004cd8a7 R15: 000000000075bf2c