bisecting fixing commit since 3207316b3beec7e38e5dbe2f463df0cec71e0b97 building syzkaller on 79264ae39c1ef4b4875ab67d6f0c8c3e75aa6a34 testing commit 3207316b3beec7e38e5dbe2f463df0cec71e0b97 with gcc (GCC) 8.4.1 20210217 kernel signature: 6784c37ad21680fd6ae3940042a2875dc740d772b6b8eb4f4faf2f80e024124d all runs: crashed: INFO: task hung in vfs_setxattr testing current HEAD 125222814e7b8f84df767d6ab622aff2a6d2f234 testing commit 125222814e7b8f84df767d6ab622aff2a6d2f234 with gcc (GCC) 8.4.1 20210217 kernel signature: 69dfaac0a703866ba4deeefc5fa0c919457f7a0bbb5d29b0ede6dfa9ecf3cd57 all runs: crashed: INFO: task hung in vfs_setxattr revisions tested: 2, total time: 27m6.668276158s (build: 15m10.791191818s, test: 11m34.29360362s) the crash still happens on HEAD commit msg: Linux 4.19.182 crash: INFO: task hung in vfs_setxattr Bluetooth: hci1: command 0x0406 tx timeout Bluetooth: hci2: command 0x0406 tx timeout Bluetooth: hci3: command 0x0406 tx timeout Bluetooth: hci4: command 0x0406 tx timeout Bluetooth: hci5: command 0x0406 tx timeout INFO: task syz-executor.5:9904 blocked for more than 140 seconds. Not tainted 4.19.182-syzkaller #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. syz-executor.5 D29192 9904 8460 0x00000004 Call Trace: context_switch kernel/sched/core.c:2828 [inline] __schedule+0x80c/0x1f70 kernel/sched/core.c:3517 schedule+0x7f/0x1b0 kernel/sched/core.c:3561 __rwsem_down_write_failed_common kernel/locking/rwsem-xadd.c:589 [inline] rwsem_down_write_failed+0x3bb/0x780 kernel/locking/rwsem-xadd.c:618 call_rwsem_down_write_failed+0x17/0x30 arch/x86/lib/rwsem.S:117 __down_write arch/x86/include/asm/rwsem.h:142 [inline] down_write+0x53/0x90 kernel/locking/rwsem.c:72 inode_lock include/linux/fs.h:748 [inline] vfs_setxattr+0xd6/0x280 fs/xattr.c:254 setxattr+0x1af/0x280 fs/xattr.c:520 __do_sys_fsetxattr fs/xattr.c:575 [inline] __se_sys_fsetxattr+0xff/0x160 fs/xattr.c:564 __x64_sys_fsetxattr+0xb9/0x140 fs/xattr.c:564 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x465b09 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 bc ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f886e68e188 EFLAGS: 00000246 ORIG_RAX: 00000000000000be RAX: ffffffffffffffda RBX: 000000000056c008 RCX: 0000000000465b09 RDX: 0000000000000000 RSI: 0000000020000180 RDI: 0000000000000005 RBP: 00000000004b069f R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000056c008 R13: 00007ffee33482cf R14: 00007f886e68e300 R15: 0000000000022000 INFO: task syz-executor.2:9911 blocked for more than 140 seconds. Not tainted 4.19.182-syzkaller #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. syz-executor.2 D29752 9911 8451 0x00000004 Call Trace: context_switch kernel/sched/core.c:2828 [inline] __schedule+0x80c/0x1f70 kernel/sched/core.c:3517 schedule+0x7f/0x1b0 kernel/sched/core.c:3561 __rwsem_down_write_failed_common kernel/locking/rwsem-xadd.c:589 [inline] rwsem_down_write_failed+0x3bb/0x780 kernel/locking/rwsem-xadd.c:618 call_rwsem_down_write_failed+0x17/0x30 arch/x86/lib/rwsem.S:117 __down_write arch/x86/include/asm/rwsem.h:142 [inline] down_write+0x53/0x90 kernel/locking/rwsem.c:72 inode_lock include/linux/fs.h:748 [inline] vfs_setxattr+0xd6/0x280 fs/xattr.c:254 setxattr+0x1af/0x280 fs/xattr.c:520 __do_sys_fsetxattr fs/xattr.c:575 [inline] __se_sys_fsetxattr+0xff/0x160 fs/xattr.c:564 __x64_sys_fsetxattr+0xb9/0x140 fs/xattr.c:564 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x465b09 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 bc ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f9409f25188 EFLAGS: 00000246 ORIG_RAX: 00000000000000be RAX: ffffffffffffffda RBX: 000000000056c008 RCX: 0000000000465b09 RDX: 0000000000000000 RSI: 0000000020000180 RDI: 0000000000000005 RBP: 00000000004b069f R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000056c008 R13: 00007ffcca983daf R14: 00007f9409f25300 R15: 0000000000022000 INFO: task syz-executor.1:9944 blocked for more than 140 seconds. Not tainted 4.19.182-syzkaller #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. syz-executor.1 D29752 9944 8461 0x00000004 Call Trace: context_switch kernel/sched/core.c:2828 [inline] __schedule+0x80c/0x1f70 kernel/sched/core.c:3517 schedule+0x7f/0x1b0 kernel/sched/core.c:3561 __rwsem_down_write_failed_common kernel/locking/rwsem-xadd.c:589 [inline] rwsem_down_write_failed+0x3bb/0x780 kernel/locking/rwsem-xadd.c:618 call_rwsem_down_write_failed+0x17/0x30 arch/x86/lib/rwsem.S:117 __down_write arch/x86/include/asm/rwsem.h:142 [inline] down_write+0x53/0x90 kernel/locking/rwsem.c:72 inode_lock include/linux/fs.h:748 [inline] vfs_setxattr+0xd6/0x280 fs/xattr.c:254 setxattr+0x1af/0x280 fs/xattr.c:520 __do_sys_fsetxattr fs/xattr.c:575 [inline] __se_sys_fsetxattr+0xff/0x160 fs/xattr.c:564 __x64_sys_fsetxattr+0xb9/0x140 fs/xattr.c:564 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x465b09 Code: Bad RIP value. RSP: 002b:00007f9a18baf188 EFLAGS: 00000246 ORIG_RAX: 00000000000000be RAX: ffffffffffffffda RBX: 000000000056c008 RCX: 0000000000465b09 RDX: 0000000000000000 RSI: 0000000020000180 RDI: 0000000000000005 RBP: 00000000004b069f R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000056c008 R13: 00007fff5def172f R14: 00007f9a18baf300 R15: 0000000000022000 INFO: task syz-executor.0:9965 blocked for more than 140 seconds. Not tainted 4.19.182-syzkaller #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. syz-executor.0 D29752 9965 8455 0x00000004 Call Trace: context_switch kernel/sched/core.c:2828 [inline] __schedule+0x80c/0x1f70 kernel/sched/core.c:3517 schedule+0x7f/0x1b0 kernel/sched/core.c:3561 __rwsem_down_write_failed_common kernel/locking/rwsem-xadd.c:589 [inline] rwsem_down_write_failed+0x3bb/0x780 kernel/locking/rwsem-xadd.c:618 call_rwsem_down_write_failed+0x17/0x30 arch/x86/lib/rwsem.S:117 __down_write arch/x86/include/asm/rwsem.h:142 [inline] down_write+0x53/0x90 kernel/locking/rwsem.c:72 inode_lock include/linux/fs.h:748 [inline] vfs_setxattr+0xd6/0x280 fs/xattr.c:254 setxattr+0x1af/0x280 fs/xattr.c:520 __do_sys_fsetxattr fs/xattr.c:575 [inline] __se_sys_fsetxattr+0xff/0x160 fs/xattr.c:564 __x64_sys_fsetxattr+0xb9/0x140 fs/xattr.c:564 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x465b09 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 bc ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f34f516f188 EFLAGS: 00000246 ORIG_RAX: 00000000000000be RAX: ffffffffffffffda RBX: 000000000056c008 RCX: 0000000000465b09 RDX: 0000000000000000 RSI: 0000000020000180 RDI: 0000000000000005 RBP: 00000000004b069f R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000056c008 R13: 00007ffd56c6e85f R14: 00007f34f516f300 R15: 0000000000022000 INFO: task syz-executor.3:9960 blocked for more than 140 seconds. Not tainted 4.19.182-syzkaller #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. syz-executor.3 D29752 9960 8457 0x00000004 Call Trace: context_switch kernel/sched/core.c:2828 [inline] __schedule+0x80c/0x1f70 kernel/sched/core.c:3517 schedule+0x7f/0x1b0 kernel/sched/core.c:3561 __rwsem_down_write_failed_common kernel/locking/rwsem-xadd.c:589 [inline] rwsem_down_write_failed+0x3bb/0x780 kernel/locking/rwsem-xadd.c:618 call_rwsem_down_write_failed+0x17/0x30 arch/x86/lib/rwsem.S:117 __down_write arch/x86/include/asm/rwsem.h:142 [inline] down_write+0x53/0x90 kernel/locking/rwsem.c:72 inode_lock include/linux/fs.h:748 [inline] vfs_setxattr+0xd6/0x280 fs/xattr.c:254 setxattr+0x1af/0x280 fs/xattr.c:520 __do_sys_fsetxattr fs/xattr.c:575 [inline] __se_sys_fsetxattr+0xff/0x160 fs/xattr.c:564 __x64_sys_fsetxattr+0xb9/0x140 fs/xattr.c:564 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x465b09 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 bc ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f1357fb2188 EFLAGS: 00000246 ORIG_RAX: 00000000000000be RAX: ffffffffffffffda RBX: 000000000056c008 RCX: 0000000000465b09 RDX: 0000000000000000 RSI: 0000000020000180 RDI: 0000000000000005 RBP: 00000000004b069f R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000056c008 R13: 00007ffecb40f15f R14: 00007f1357fb2300 R15: 0000000000022000 INFO: task syz-executor.4:9963 blocked for more than 140 seconds. Not tainted 4.19.182-syzkaller #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. syz-executor.4 D29752 9963 8453 0x00000004 Call Trace: context_switch kernel/sched/core.c:2828 [inline] __schedule+0x80c/0x1f70 kernel/sched/core.c:3517 schedule+0x7f/0x1b0 kernel/sched/core.c:3561 __rwsem_down_write_failed_common kernel/locking/rwsem-xadd.c:589 [inline] rwsem_down_write_failed+0x3bb/0x780 kernel/locking/rwsem-xadd.c:618 call_rwsem_down_write_failed+0x17/0x30 arch/x86/lib/rwsem.S:117 __down_write arch/x86/include/asm/rwsem.h:142 [inline] down_write+0x53/0x90 kernel/locking/rwsem.c:72 inode_lock include/linux/fs.h:748 [inline] vfs_setxattr+0xd6/0x280 fs/xattr.c:254 setxattr+0x1af/0x280 fs/xattr.c:520 __do_sys_fsetxattr fs/xattr.c:575 [inline] __se_sys_fsetxattr+0xff/0x160 fs/xattr.c:564 __x64_sys_fsetxattr+0xb9/0x140 fs/xattr.c:564 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x465b09 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 bc ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f16c29bc188 EFLAGS: 00000246 ORIG_RAX: 00000000000000be RAX: ffffffffffffffda RBX: 000000000056c008 RCX: 0000000000465b09 RDX: 0000000000000000 RSI: 0000000020000180 RDI: 0000000000000005 RBP: 00000000004b069f R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000056c008 R13: 00007ffc31ee3d8f R14: 00007f16c29bc300 R15: 0000000000022000 Showing all locks held in the system: 1 lock held by khungtaskd/1562: #0: 00000000d10a4d65 (rcu_read_lock){....}, at: debug_show_all_locks+0x5b/0x27a kernel/locking/lockdep.c:4442 1 lock held by khugepaged/1577: 1 lock held by kswapd0/1968: 1 lock held by kswapd1/1969: 1 lock held by in:imklog/7790: #0: 0000000027c27130 (&f->f_pos_lock){+.+.}, at: __fdget_pos+0xa7/0xd0 fs/file.c:767 4 locks held by syz-executor.5/9878: 2 locks held by syz-executor.5/9904: #0: 00000000bf13b830 (sb_writers#14){.+.+}, at: sb_start_write include/linux/fs.h:1579 [inline] #0: 00000000bf13b830 (sb_writers#14){.+.+}, at: mnt_want_write_file+0x67/0x110 fs/namespace.c:418 #1: 0000000014182bc8 (&type->i_mutex_dir_key#9){+.+.}, at: inode_lock include/linux/fs.h:748 [inline] #1: 0000000014182bc8 (&type->i_mutex_dir_key#9){+.+.}, at: vfs_setxattr+0xd6/0x280 fs/xattr.c:254 3 locks held by syz-executor.2/9895: 2 locks held by syz-executor.2/9911: #0: 0000000073383005 (sb_writers#14){.+.+}, at: sb_start_write include/linux/fs.h:1579 [inline] #0: 0000000073383005 (sb_writers#14){.+.+}, at: mnt_want_write_file+0x67/0x110 fs/namespace.c:418 #1: 000000003c0e907e (&type->i_mutex_dir_key#9){+.+.}, at: inode_lock include/linux/fs.h:748 [inline] #1: 000000003c0e907e (&type->i_mutex_dir_key#9){+.+.}, at: vfs_setxattr+0xd6/0x280 fs/xattr.c:254 3 locks held by syz-executor.1/9939: 2 locks held by syz-executor.1/9944: #0: 0000000054c9bd3b (sb_writers#14){.+.+}, at: sb_start_write include/linux/fs.h:1579 [inline] #0: 0000000054c9bd3b (sb_writers#14){.+.+}, at: mnt_want_write_file+0x67/0x110 fs/namespace.c:418 #1: 00000000095e236d (&type->i_mutex_dir_key#9){+.+.}, at: inode_lock include/linux/fs.h:748 [inline] #1: 00000000095e236d (&type->i_mutex_dir_key#9){+.+.}, at: vfs_setxattr+0xd6/0x280 fs/xattr.c:254 3 locks held by syz-executor.0/9950: 2 locks held by syz-executor.0/9965: #0: 00000000ef88452f (sb_writers#14){.+.+}, at: sb_start_write include/linux/fs.h:1579 [inline] #0: 00000000ef88452f (sb_writers#14){.+.+}, at: mnt_want_write_file+0x67/0x110 fs/namespace.c:418 #1: 0000000077bea9af (&type->i_mutex_dir_key#9){+.+.}, at: inode_lock include/linux/fs.h:748 [inline] #1: 0000000077bea9af (&type->i_mutex_dir_key#9){+.+.}, at: vfs_setxattr+0xd6/0x280 fs/xattr.c:254 3 locks held by syz-executor.3/9951: 2 locks held by syz-executor.3/9960: #0: 00000000c540f248 (sb_writers#14){.+.+}, at: sb_start_write include/linux/fs.h:1579 [inline] #0: 00000000c540f248 (sb_writers#14){.+.+}, at: mnt_want_write_file+0x67/0x110 fs/namespace.c:418 #1: 00000000ba4951aa (&type->i_mutex_dir_key#9){+.+.}, at: inode_lock include/linux/fs.h:748 [inline] #1: 00000000ba4951aa (&type->i_mutex_dir_key#9){+.+.}, at: vfs_setxattr+0xd6/0x280 fs/xattr.c:254 3 locks held by syz-executor.4/9955: 2 locks held by syz-executor.4/9963: #0: 000000004227ba03 (sb_writers#14){.+.+}, at: sb_start_write include/linux/fs.h:1579 [inline] #0: 000000004227ba03 (sb_writers#14){.+.+}, at: mnt_want_write_file+0x67/0x110 fs/namespace.c:418 #1: 00000000b25ae0dc (&type->i_mutex_dir_key#9){+.+.}, at: inode_lock include/linux/fs.h:748 [inline] #1: 00000000b25ae0dc (&type->i_mutex_dir_key#9){+.+.}, at: vfs_setxattr+0xd6/0x280 fs/xattr.c:254 ============================================= NMI backtrace for cpu 0 CPU: 0 PID: 1562 Comm: khungtaskd Not tainted 4.19.182-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+0x17c/0x226 lib/dump_stack.c:118 nmi_cpu_backtrace.cold.0+0x3c/0x78 lib/nmi_backtrace.c:101