INFO: task syz-executor.0:1853 blocked for more than 143 seconds. Not tainted 5.15.149-syzkaller #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. task:syz-executor.0 state:D stack:12512 pid: 1853 ppid: 1452 flags:0x00004006 Call Trace: context_switch kernel/sched/core.c:5030 [inline] __schedule+0x2bd/0x800 kernel/sched/core.c:6376 schedule+0x53/0x90 kernel/sched/core.c:6459 wait_on_state fs/btrfs/extent_io.c:868 [inline] wait_extent_bit.constprop.0+0x15e/0x1b0 fs/btrfs/extent_io.c:906 lock_extent_bits+0x32/0x90 fs/btrfs/extent_io.c:1469 btrfs_page_mkwrite+0x1cb/0x620 fs/btrfs/inode.c:8953 do_page_mkwrite+0x46/0x100 mm/memory.c:2892 wp_page_shared mm/memory.c:3229 [inline] do_wp_page+0x26e/0x490 mm/memory.c:3330 handle_pte_fault mm/memory.c:4639 [inline] __handle_mm_fault+0xa50/0x14a0 mm/memory.c:4756 handle_mm_fault+0xfa/0x290 mm/memory.c:4854 do_user_addr_fault arch/x86/mm/fault.c:1397 [inline] handle_page_fault arch/x86/mm/fault.c:1485 [inline] exc_page_fault+0x1c4/0x760 arch/x86/mm/fault.c:1541 asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:568 RIP: 0010:copy_user_generic_unrolled+0x89/0xc0 arch/x86/lib/copy_user_64.S:92 Code: 38 4c 89 47 20 4c 89 4f 28 4c 89 57 30 4c 89 5f 38 48 8d 76 40 48 8d 7f 40 ff c9 75 b6 89 d1 83 e2 07 c1 e9 03 74 12 4c 8b 06 <4c> 89 07 48 8d 76 08 48 8d 7f 08 ff c9 75 ee 21 d2 74 10 89 d1 8a RSP: 0018:ffffc9000041bcf8 EFLAGS: 00050202 RAX: 00007ffffffff000 RBX: 00000000200000e0 RCX: 0000000000000007 RDX: 0000000000000000 RSI: ffffc9000041bd20 RDI: 00000000200000e0 RBP: ffffc9000041bd20 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000038 R13: 0000000000000001 R14: 0000000000001000 R15: 0000000000000000 copy_user_generic arch/x86/include/asm/uaccess_64.h:37 [inline] raw_copy_to_user arch/x86/include/asm/uaccess_64.h:58 [inline] _copy_to_user lib/usercopy.c:40 [inline] _copy_to_user+0x43/0x50 lib/usercopy.c:33 copy_to_user include/linux/uaccess.h:200 [inline] fiemap_fill_next_extent+0x9e/0xf0 fs/ioctl.c:144 emit_fiemap_extent fs/btrfs/extent_io.c:5461 [inline] extent_fiemap+0x528/0x6a0 fs/btrfs/extent_io.c:5687 btrfs_fiemap+0x3a/0x50 fs/btrfs/inode.c:8576 ioctl_fiemap fs/ioctl.c:219 [inline] do_vfs_ioctl+0x1ce/0x850 fs/ioctl.c:814 __do_sys_ioctl fs/ioctl.c:872 [inline] __se_sys_ioctl fs/ioctl.c:860 [inline] __x64_sys_ioctl+0x5d/0xb0 fs/ioctl.c:860 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+0x61/0xcb RIP: 0033:0x7f828ae0f959 RSP: 002b:00007f828a1910c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 00007f828af2ef80 RCX: 00007f828ae0f959 RDX: 00000000200000c0 RSI: 00000000c020660b RDI: 0000000000000004 RBP: 00007f828ae6bc88 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000006 R14: 00007f828af2ef80 R15: 00007ffc97cfb488 Showing all locks held in the system: 1 lock held by khungtaskd/26: #0: ffffffff8357ea00 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x15/0xf2 kernel/locking/lockdep.c:6453 2 locks held by getty/887: #0: ffff88810a1a0098 (&tty->ldisc_sem){....}-{0:0}, at: tty_ldisc_ref_wait+0x1f/0x50 drivers/tty/tty_ldisc.c:252 #1: ffffc9000155f2e8 (&ldata->atomic_read_lock){....}-{3:3}, at: n_tty_read+0x4eb/0x610 drivers/tty/n_tty.c:2158 3 locks held by syz-executor.0/1853: #0: ffff8881075c62a8 (&mm->mmap_lock){....}-{3:3}, at: mmap_read_trylock include/linux/mmap_lock.h:136 [inline] #0: ffff8881075c62a8 (&mm->mmap_lock){....}-{3:3}, at: do_user_addr_fault arch/x86/mm/fault.c:1338 [inline] #0: ffff8881075c62a8 (&mm->mmap_lock){....}-{3:3}, at: handle_page_fault arch/x86/mm/fault.c:1485 [inline] #0: ffff8881075c62a8 (&mm->mmap_lock){....}-{3:3}, at: exc_page_fault+0x138/0x760 arch/x86/mm/fault.c:1541 #1: ffff888176c2b530 (sb_pagefaults){....}-{0:0}, at: do_page_mkwrite+0x46/0x100 mm/memory.c:2892 #2: ffff88817d240dd8 (&ei->i_mmap_lock){....}-{3:3}, at: btrfs_page_mkwrite+0x255/0x620 fs/btrfs/inode.c:8942 2 locks held by syz-executor.0/7384: ============================================= NMI backtrace for cpu 0 CPU: 0 PID: 26 Comm: khungtaskd Not tainted 5.15.149-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+0x41/0x5e lib/dump_stack.c:106 nmi_cpu_backtrace.cold+0x32/0x80 lib/nmi_backtrace.c:111 nmi_trigger_cpumask_backtrace+0x81/0x90 lib/nmi_backtrace.c:62 trigger_all_cpu_backtrace include/linux/nmi.h:148 [inline] check_hung_uninterruptible_tasks kernel/hung_task.c:210 [inline] watchdog+0x47f/0x4b0 kernel/hung_task.c:295 kthread+0x10b/0x130 kernel/kthread.c:319 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:298 Sending NMI from CPU 0 to CPUs 1: NMI backtrace for cpu 1 CPU: 1 PID: 7388 Comm: syz-executor.0 Not tainted 5.15.149-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/25/2024 RIP: 0010:variable_test_bit arch/x86/include/asm/bitops.h:214 [inline] RIP: 0010:test_bit include/asm-generic/bitops/instrumented-non-atomic.h:135 [inline] RIP: 0010:zref_in_nodemask mm/mmzone.c:49 [inline] RIP: 0010:__next_zones_zonelist+0x11/0x40 mm/mmzone.c:69 Code: 48 8b 04 cd 20 42 82 83 c3 31 c0 c3 66 66 2e 0f 1f 84 00 00 00 00 00 66 90 48 85 d2 48 89 f8 48 89 d1 75 10 eb 1c 48 63 52 50 <48> 0f a3 11 72 11 48 83 c0 10 39 70 08 77 f7 48 8b 10 48 85 d2 75 RSP: 0018:ffffc900016e7ab8 EFLAGS: 00000282 RAX: ffff88823fffb1c0 RBX: 0000000000000000 RCX: ffff888176c11260 RDX: 0000000000000000 RSI: 0000000000000003 RDI: ffff88823fffb1c0 RBP: ffffc900016e7b00 R08: 000000000000009e R09: 0000000000000000 R10: 0000000000000000 R11: ffffc900016e7b80 R12: ffffc900016e7af8 R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 FS: 00007fe59b6296c0(0000) GS:ffff888237d00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007fe594200000 CR3: 000000017bd73000 CR4: 00000000003506e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: next_zones_zonelist include/linux/mmzone.h:1168 [inline] first_zones_zonelist include/linux/mmzone.h:1192 [inline] prepare_alloc_pages mm/page_alloc.c:5211 [inline] prepare_alloc_pages+0x144/0x160 mm/page_alloc.c:5171 __alloc_pages+0x98/0x220 mm/page_alloc.c:5410 alloc_pages_vma+0x7c/0x2e0 mm/mempolicy.c:2146 shmem_alloc_page+0x95/0xe0 mm/shmem.c:1586 shmem_alloc_and_acct_page+0x81/0x280 mm/shmem.c:1611 shmem_getpage_gfp.constprop.0+0x1bc/0x9c0 mm/shmem.c:1906 generic_perform_write+0xbf/0x1f0 mm/filemap.c:3785 __generic_file_write_iter+0x147/0x1d0 mm/filemap.c:3912 generic_file_write_iter+0x58/0xa0 mm/filemap.c:3944 call_write_iter include/linux/fs.h:2146 [inline] new_sync_write+0x114/0x1a0 fs/read_write.c:507 vfs_write+0x208/0x2a0 fs/read_write.c:594 ksys_write+0x63/0xe0 fs/read_write.c:647 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+0x61/0xcb RIP: 0033:0x7fe59c2a67af Code: 89 54 24 18 48 89 74 24 10 89 7c 24 08 e8 a9 7f 02 00 48 8b 54 24 18 48 8b 74 24 10 41 89 c0 8b 7c 24 08 b8 01 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 31 44 89 c7 48 89 44 24 08 e8 fc 7f 02 00 48 RSP: 002b:00007fe59b628e70 EFLAGS: 00000293 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 0000000001000000 RCX: 00007fe59c2a67af RDX: 0000000001000000 RSI: 00007fe593209000 RDI: 0000000000000003 RBP: 0000000000000000 R08: 0000000000000000 R09: 00000000000050e7 R10: 0000000000000002 R11: 0000000000000293 R12: 0000000000000003 R13: 00007fe59b628f3c R14: 00007fe59b628f40 R15: 00007fe593209000