BUG: sleeping function called from invalid context at kernel/task_work.c:166 in_atomic(): 1, irqs_disabled(): 0, non_block: 0, pid: 5718, name: syz-executor.0 no locks held by syz-executor.0/5718. Preemption disabled at: [] is_module_text_address+0x16/0x140 kernel/module.c:4758 CPU: 0 PID: 5718 Comm: syz-executor.0 Not tainted 5.15.148-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/25/2024 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x1e3/0x2cb lib/dump_stack.c:106 ___might_sleep+0x547/0x6a0 kernel/sched/core.c:9626 task_work_run+0x13c/0x1a0 kernel/task_work.c:166 tracehook_notify_resume include/linux/tracehook.h:189 [inline] exit_to_user_mode_loop+0x106/0x130 kernel/entry/common.c:175 exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:208 __syscall_exit_to_user_mode_work kernel/entry/common.c:290 [inline] syscall_exit_to_user_mode+0x5d/0x250 kernel/entry/common.c:301 do_syscall_64+0x49/0xb0 arch/x86/entry/common.c:86 entry_SYSCALL_64_after_hwframe+0x61/0xcb RIP: 0033:0x7fc23cacdc9a Code: 48 3d 00 f0 ff ff 77 48 c3 0f 1f 80 00 00 00 00 48 83 ec 18 89 7c 24 0c e8 03 7f 02 00 8b 7c 24 0c 89 c2 b8 03 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 36 89 d7 89 44 24 0c e8 63 7f 02 00 8b 44 24 RSP: 002b:00007fff612453e0 EFLAGS: 00000293 ORIG_RAX: 0000000000000003 RAX: 0000000000000000 RBX: 0000000000000005 RCX: 00007fc23cacdc9a RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000004 RBP: 0000000000000226 R08: 0000001b2d360000 R09: 00007fc23cbfcf8c R10: 00007fff61245530 R11: 0000000000000293 R12: 00007fc23c652fb0 R13: ffffffffffffffff R14: 00007fc23c651000 R15: 0000000000018148 BUG: scheduling while atomic: syz-executor.0/5718/0x00000002 no locks held by syz-executor.0/5718. Modules linked in: Preemption disabled at: [] is_module_text_address+0x16/0x140 kernel/module.c:4758