BUG: sleeping function called from invalid context at kernel/workqueue.c:3010 in_atomic(): 1, irqs_disabled(): 0, non_block: 0, pid: 16019, name: syz-executor.0 preempt_count: 201, expected: 0 RCU nest depth: 0, expected: 0 3 locks held by syz-executor.0/16019: #0: ffff88808082be10 (&sb->s_type->i_mutex_key#10){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:761 [inline] #0: ffff88808082be10 (&sb->s_type->i_mutex_key#10){+.+.}-{3:3}, at: __sock_release+0x86/0x280 net/socket.c:649 #1: ffff88802a3ee130 (sk_lock-AF_INET){+.+.}-{0:0}, at: lock_sock include/net/sock.h:1664 [inline] #1: ffff88802a3ee130 (sk_lock-AF_INET){+.+.}-{0:0}, at: tcp_close+0x1e/0xc0 net/ipv4/tcp.c:2974 #2: ffff88802a3ee0b0 (slock-AF_INET){+.-.}-{2:2}, at: spin_lock include/linux/spinlock.h:360 [inline] #2: ffff88802a3ee0b0 (slock-AF_INET){+.-.}-{2:2}, at: __tcp_close+0x4d3/0xf50 net/ipv4/tcp.c:2897 Preemption disabled at: [] local_bh_disable include/linux/bottom_half.h:20 [inline] [] __tcp_close+0x4cb/0xf50 net/ipv4/tcp.c:2896 CPU: 0 PID: 16019 Comm: syz-executor.0 Not tainted 5.19.0-rc4-next-20220628-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/29/2022 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:106 __might_resched.cold+0x222/0x26b kernel/sched/core.c:9859 start_flush_work kernel/workqueue.c:3010 [inline] __flush_work+0x109/0xb10 kernel/workqueue.c:3074 __cancel_work_timer+0x3f9/0x570 kernel/workqueue.c:3162 sk_psock_stop+0x4cb/0x630 net/core/skmsg.c:810 sock_map_destroy+0x333/0x760 net/core/sock_map.c:1581 inet_csk_destroy_sock+0x196/0x440 net/ipv4/inet_connection_sock.c:1011 __tcp_close+0xb92/0xf50 net/ipv4/tcp.c:2963 tcp_close+0x29/0xc0 net/ipv4/tcp.c:2975 sock_map_close+0x3b9/0x780 net/core/sock_map.c:1607 inet_release+0x12e/0x270 net/ipv4/af_inet.c:428 __sock_release+0xcd/0x280 net/socket.c:650 sock_close+0x18/0x20 net/socket.c:1365 __fput+0x277/0x9d0 fs/file_table.c:317 task_work_run+0xdd/0x1a0 kernel/task_work.c:177 get_signal+0x1c5/0x2600 kernel/signal.c:2634 arch_do_signal_or_restart+0x82/0x2300 arch/x86/kernel/signal.c:869 exit_to_user_mode_loop kernel/entry/common.c:166 [inline] exit_to_user_mode_prepare+0x15f/0x250 kernel/entry/common.c:201 __syscall_exit_to_user_mode_work kernel/entry/common.c:283 [inline] syscall_exit_to_user_mode+0x19/0x50 kernel/entry/common.c:294 do_syscall_64+0x42/0xb0 arch/x86/entry/common.c:86 entry_SYSCALL_64_after_hwframe+0x46/0xb0 RIP: 0033:0x7f33b6a89199 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 b8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f33b7c16168 EFLAGS: 00000246 ORIG_RAX: 000000000000002c RAX: 0000000000278000 RBX: 00007f33b6b9bf60 RCX: 00007f33b6a89199 RDX: ffffffffffffff60 RSI: 00000000200000c0 RDI: 0000000000000003 RBP: 00007f33b6ae313b R08: 0000000000000000 R09: 0000000000000f00 R10: 000000000000f40c R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffeb6b8d3cf R14: 00007f33b7c16300 R15: 0000000000022000