------------[ cut here ]------------ do not call blocking ops when !TASK_RUNNING; state=2 set at [] prepare_to_wait_event+0x8d/0x720 kernel/sched/wait.c:317 WARNING: kernel/sched/core.c:9157 at __might_sleep+0x94/0xc0 kernel/sched/core.c:9157, CPU#0: syz.1.180/6346 Modules linked in: CPU: 0 UID: 0 PID: 6346 Comm: syz.1.180 Not tainted syzkaller #0 PREEMPT(full) Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 RIP: 0010:__might_sleep+0x97/0xc0 kernel/sched/core.c:9157 Code: 8b 94 24 80 18 00 00 48 85 d2 75 14 48 83 c4 08 89 ee 48 89 df 31 d2 5b 5d 41 5c e9 33 fc ff ff 48 8d 3d 0c 3c 70 0f 48 89 d1 <67> 48 0f b9 3a eb db e8 bd bf a7 00 eb 9f 89 74 24 04 e8 e2 bf a7 RSP: 0018:ffffc90007817b88 EFLAGS: 00010282 RAX: dffffc0000000000 RBX: ffffffff8befd0a0 RCX: ffffffff81e29fad RDX: ffffffff81e29fad RSI: 0000000000000002 RDI: ffffffff914651d0 RBP: 000000000000026f R08: ffffffff81fcdfa2 R09: 0000000000000000 R10: ffffc90007817d40 R11: 0000000000000000 R12: ffff88802ec78000 R13: 0000000000000000 R14: dffffc0000000000 R15: ffffffff8ea0e030 FS: 00007fa074f3d6c0(0000) GS:ffff8880d5ba2000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007fa074f3cff8 CR3: 000000005aebd000 CR4: 0000000000352ef0 Call Trace: __mutex_lock_common kernel/locking/mutex.c:623 [inline] __mutex_lock+0x10e/0x1bc0 kernel/locking/mutex.c:821 class_mutex_constructor include/linux/mutex.h:253 [inline] futex_pivot_pending kernel/futex/core.c:1791 [inline] futex_hash_allocate+0xd22/0x1120 kernel/futex/core.c:1874 futex_hash_prctl+0x1b8/0x390 kernel/futex/core.c:2029 __do_sys_prctl+0x16dd/0x2270 kernel/sys.c:2885 do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline] do_syscall_64+0x123/0x790 arch/x86/entry/syscall_64.c:84 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7fa073f9e0d9 Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 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 e8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fa074f3d028 EFLAGS: 00000246 ORIG_RAX: 000000000000009d RAX: ffffffffffffffda RBX: 00007fa074225fa0 RCX: 00007fa073f9e0d9 RDX: 0000000000000000 RSI: 0000000000000001 RDI: 000000000000004e RBP: 00007fa074035024 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007fa074226038 R14: 00007fa074225fa0 R15: 00007ffe33f5d078 ---------------- Code disassembly (best guess): 0: 8b 94 24 80 18 00 00 mov 0x1880(%rsp),%edx 7: 48 85 d2 test %rdx,%rdx a: 75 14 jne 0x20 c: 48 83 c4 08 add $0x8,%rsp 10: 89 ee mov %ebp,%esi 12: 48 89 df mov %rbx,%rdi 15: 31 d2 xor %edx,%edx 17: 5b pop %rbx 18: 5d pop %rbp 19: 41 5c pop %r12 1b: e9 33 fc ff ff jmp 0xfffffc53 20: 48 8d 3d 0c 3c 70 0f lea 0xf703c0c(%rip),%rdi # 0xf703c33 27: 48 89 d1 mov %rdx,%rcx * 2a: 67 48 0f b9 3a ud1 (%edx),%rdi <-- trapping instruction 2f: eb db jmp 0xc 31: e8 bd bf a7 00 call 0xa7bff3 36: eb 9f jmp 0xffffffd7 38: 89 74 24 04 mov %esi,0x4(%rsp) 3c: e8 .byte 0xe8 3d: e2 bf loop 0xfffffffe 3f: a7 cmpsl %es:(%rdi),%ds:(%rsi)