bisecting fixing commit since 42226c989789d8da4af1de0c31070c96726d990c building syzkaller on 744a39e220cece33e207035facce6c5ae161b775 testing commit 42226c989789d8da4af1de0c31070c96726d990c compiler: gcc (GCC) 10.2.1 20210217, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: e5f785b9c97563ea15deef3114f0cdc3496d546a8434902819b54673a2497264 all runs: crashed: INFO: task hung in __xfs_buf_submit testing current HEAD 30306f6194cadcc29c77f6ddcd416a75bf5c0232 testing commit 30306f6194cadcc29c77f6ddcd416a75bf5c0232 compiler: gcc (GCC) 10.2.1 20210217, GNU ld (GNU Binutils for Debian) 2.35.2 kernel signature: 7261acc8e178956ed25bfd1c147bcb0b1fbddba63c5085984158e810b8149abf all runs: crashed: INFO: task hung in __xfs_buf_submit revisions tested: 2, total time: 25m48.203726898s (build: 13m16.051137296s, test: 11m58.967601568s) the crash still happens on HEAD commit msg: Merge tag 'hardening-v5.19-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux crash: INFO: task hung in __xfs_buf_submit INFO: task syz-executor.0:4099 blocked for more than 143 seconds. Not tainted 5.19.0-rc2-syzkaller #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. task:syz-executor.0 state:D stack:27400 pid: 4099 ppid: 4079 flags:0x00004004 Call Trace: context_switch kernel/sched/core.c:5116 [inline] __schedule+0x9cd/0x4af0 kernel/sched/core.c:6428 schedule+0xd2/0x1f0 kernel/sched/core.c:6500 schedule_timeout+0x19d/0x250 kernel/time/timer.c:1911 do_wait_for_common kernel/sched/completion.c:85 [inline] __wait_for_common+0x378/0x530 kernel/sched/completion.c:106 xfs_buf_iowait+0x8e/0x420 fs/xfs/xfs_buf.c:1577 __xfs_buf_submit+0x389/0x660 fs/xfs/xfs_buf.c:1657 xfs_buf_submit fs/xfs/xfs_buf.c:59 [inline] xfs_buf_read_uncached+0x1bd/0x320 fs/xfs/xfs_buf.c:891 xfs_readsb+0x2a9/0x560 fs/xfs/xfs_mount.c:179 xfs_fs_fill_super+0x65b/0x1940 fs/xfs/xfs_super.c:1503 get_tree_bdev+0x398/0x680 fs/super.c:1292 vfs_get_tree+0x7f/0x2c0 fs/super.c:1497 do_new_mount fs/namespace.c:3040 [inline] path_mount+0x7e8/0x1a40 fs/namespace.c:3370 do_mount fs/namespace.c:3383 [inline] __do_sys_mount fs/namespace.c:3591 [inline] __se_sys_mount fs/namespace.c:3568 [inline] __x64_sys_mount+0x1f5/0x260 fs/namespace.c:3568 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x46/0xb0 RIP: 0033:0x7ff6006890e9 RSP: 002b:00007ff60179a168 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 00007ff60079bf60 RCX: 00007ff6006890e9 RDX: 0000000020000140 RSI: 0000000020000000 RDI: 00000000200000c0 RBP: 00007ff6006e308d R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000008002 R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffcf36409df R14: 00007ff60179a300 R15: 0000000000022000 Showing all locks held in the system: 1 lock held by khungtaskd/29: #0: ffffffff8b17a3a0 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x53/0x260 kernel/locking/lockdep.c:6491 2 locks held by getty/3286: #0: ffff88802518f098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x1f/0x70 drivers/tty/tty_ldisc.c:244 #1: ffffc90001c282e8 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0xb14/0x1040 drivers/tty/n_tty.c:2124 1 lock held by syz-executor.0/4099: #0: ffff88801c6200e0 (&type->s_umount_key#67/1){+.+.}-{3:3}, at: alloc_super+0x192/0x9e0 fs/super.c:228 ============================================= NMI backtrace for cpu 0 CPU: 0 PID: 29 Comm: khungtaskd Not tainted 5.19.0-rc2-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x57/0x7d lib/dump_stack.c:106 nmi_cpu_backtrace.cold+0x30/0xc0 lib/nmi_backtrace.c:111 nmi_trigger_cpumask_backtrace+0x140/0x170 lib/nmi_backtrace.c:62 trigger_all_cpu_backtrace include/linux/nmi.h:146 [inline] check_hung_uninterruptible_tasks kernel/hung_task.c:220 [inline] watchdog+0x891/0xc20 kernel/hung_task.c:378 kthread+0x299/0x340 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:302 Sending NMI from CPU 0 to CPUs 1: NMI backtrace for cpu 1 CPU: 1 PID: 2430 Comm: kworker/u4:6 Not tainted 5.19.0-rc2-syzkaller #0 CPU: 1 PID: 2430 Comm: kworker/u4:6 Not tainted 5.19.0-rc2-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: events_unbound toggle_allocation_gate RIP: 0010:check_region_inline mm/kasan/generic.c:169 [inline] RIP: 0010:kasan_check_range+0x9/0x180 mm/kasan/generic.c:189 Code: b6 f5 bf 00 08 00 00 89 43 0c e8 b2 e4 ff ff 89 43 08 5b 5d c3 66 66 2e 0f 1f 84 00 00 00 00 00 90 48 85 f6 0f 84 3c 01 00 00 <49> 89 f9 41 54 44 0f b6 c2 49 01 f1 55 53 0f 82 18 01 00 00 48 b8 RSP: 0018:ffffc9000c377780 EFLAGS: 00000002 RAX: 0000000000000000 RBX: 0000000000000008 RCX: ffffffff8154b5e6 RDX: 0000000000000000 RSI: 0000000000000008 RDI: ffffffff8f39b900 RBP: ffff88802535ab8a R08: 0000000000000000 R09: 0000000000000005 R10: fffffbfff1e73722 R11: 0000000000000001 R12: ffff88802535ab68 R13: ffff88802535a040 R14: 0000000000000000 R15: b85289586e3e3734 FS: 0000000000000000(0000) GS:ffff8880b9f00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f4696903990 CR3: 000000000ae8e000 CR4: 00000000003506e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: instrument_atomic_read include/linux/instrumented.h:71 [inline] test_bit include/asm-generic/bitops/instrumented-non-atomic.h:134 [inline] hlock_class kernel/locking/lockdep.c:227 [inline] __lock_acquire+0x1416/0x55d0 kernel/locking/lockdep.c:5049 lock_acquire kernel/locking/lockdep.c:5665 [inline] lock_acquire+0x1ab/0x570 kernel/locking/lockdep.c:5630 __raw_spin_lock include/linux/spinlock_api_smp.h:133 [inline] _raw_spin_lock+0x2a/0x40 kernel/locking/spinlock.c:154 spin_lock include/linux/spinlock.h:349 [inline] __get_locked_pte+0x105/0x210 mm/memory.c:1830 get_locked_pte include/linux/mm.h:2132 [inline] __text_poke+0x1b3/0x8e0 arch/x86/kernel/alternative.c:1052 text_poke arch/x86/kernel/alternative.c:1137 [inline] text_poke_bp_batch+0x44c/0x6d0 arch/x86/kernel/alternative.c:1483 text_poke_flush arch/x86/kernel/alternative.c:1589 [inline] text_poke_flush arch/x86/kernel/alternative.c:1586 [inline] text_poke_finish+0x16/0x30 arch/x86/kernel/alternative.c:1596 arch_jump_label_transform_apply+0x13/0x20 arch/x86/kernel/jump_label.c:146 static_key_enable_cpuslocked+0x15f/0x220 kernel/jump_label.c:177 static_key_enable+0x11/0x20 kernel/jump_label.c:190 toggle_allocation_gate mm/kfence/core.c:808 [inline] toggle_allocation_gate+0xe3/0x310 mm/kfence/core.c:800 process_one_work+0x865/0x13d0 kernel/workqueue.c:2289 worker_thread+0x598/0xec0 kernel/workqueue.c:2436 kthread+0x299/0x340 kernel/kthread.c:376 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:302 ---------------- Code disassembly (best guess): 0: b6 f5 mov $0xf5,%dh 2: bf 00 08 00 00 mov $0x800,%edi 7: 89 43 0c mov %eax,0xc(%rbx) a: e8 b2 e4 ff ff callq 0xffffe4c1 f: 89 43 08 mov %eax,0x8(%rbx) 12: 5b pop %rbx 13: 5d pop %rbp 14: c3 retq 15: 66 66 2e 0f 1f 84 00 data16 nopw %cs:0x0(%rax,%rax,1) 1c: 00 00 00 00 20: 90 nop 21: 48 85 f6 test %rsi,%rsi 24: 0f 84 3c 01 00 00 je 0x166 * 2a: 49 89 f9 mov %rdi,%r9 <-- trapping instruction 2d: 41 54 push %r12 2f: 44 0f b6 c2 movzbl %dl,%r8d 33: 49 01 f1 add %rsi,%r9 36: 55 push %rbp 37: 53 push %rbx 38: 0f 82 18 01 00 00 jb 0x156 3e: 48 rex.W 3f: b8 .byte 0xb8