INFO: task hung in ni_readpage_cmpr

Status: upstream: reported C repro on 2024/02/13 07:32
Bug presence: origin:lts-only
[Documentation on labels]
Reported-by: syzbot+4cc251673c16be47e2b1@syzkaller.appspotmail.com
First crash: 918d, last: 92d
Fix commit to backport (bisect log) :
tree: upstream
commit bfbe5b31caa74ab97f1784fe9ade5f45e0d3de91
Author: Konstantin Komarov <almaz.alexandrovich@paragon-software.com>
Date: Fri Jun 30 12:22:53 2023 +0000

  fs/ntfs3: fix deadlock in mark_as_free_ex

  
Fix bisection: the issue occurs on the latest tested release (bisect log)
Crash: INFO: task hung in ntfs_readpage (log)
Repro: C syz .config
  
Bug presence (2)
Date Name Commit Repro Result
2024/02/22 linux-5.15.y (ToT) 6139f2a02fe0 C [report] INFO: task hung in ni_readpage_cmpr
2024/02/22 upstream (ToT) 39133352cbed C Didn't crash
Similar bugs (4)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream INFO: task hung in ni_readpage_cmpr (3) ntfs3 1 syz, C done 6 231d 245d 29/29 fixed on 2026/05/06 16:40
upstream INFO: task hung in ni_readpage_cmpr ntfs3 1 syz, C error 7 789d 1125d 0/29 auto-obsoleted due to no activity on 2024/09/29 08:21
upstream INFO: task hung in ni_readpage_cmpr (2) ntfs3 1 1 351d 351d 0/29 auto-obsoleted due to no activity on 2025/11/30 17:19
linux-6.1 INFO: task hung in ni_readpage_cmpr 1 1 649d 649d 0/3 auto-obsoleted due to no activity on 2025/02/15 17:38
Last patch testing requests (10)
Created Duration User Patch Repo Result
2026/07/30 10:47 21m retest repro linux-5.15.y no crash log
2026/05/19 06:02 20m retest repro linux-5.15.y report log
2026/03/01 11:51 13m retest repro linux-5.15.y report log
2025/12/21 03:32 13m retest repro linux-5.15.y report log
2025/10/12 01:35 14m retest repro linux-5.15.y report log
2025/08/01 21:45 13m retest repro linux-5.15.y report log
2025/05/20 23:07 13m retest repro linux-5.15.y report log
2025/03/04 04:03 16m retest repro linux-5.15.y report log
2024/12/24 00:29 13m retest repro linux-5.15.y report log
2024/10/13 16:55 19m retest repro linux-5.15.y report log
Fix bisection attempts (2)
Created Duration User Patch Repo Result
2024/03/24 13:46 7h02m fix candidate upstream OK (1) job log
2024/03/24 02:12 2h32m bisect fix linux-5.15.y OK (0) job log log

Sample crash report:
INFO: task syz.7.430:6937 blocked for more than 143 seconds.
      Not tainted 5.15.181-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz.7.430       state:D stack:26792 pid: 6937 ppid:  5810 flags:0x00004004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5030 [inline]
 __schedule+0x11b8/0x43b0 kernel/sched/core.c:6376
 schedule+0x11b/0x1e0 kernel/sched/core.c:6459
 io_schedule+0x7c/0xd0 kernel/sched/core.c:8484
 wait_on_page_bit_common+0x815/0xe00 mm/filemap.c:1356
 __lock_page mm/filemap.c:1648 [inline]
 lock_page include/linux/pagemap.h:625 [inline]
 pagecache_get_page+0x4d4/0xef0 mm/filemap.c:1910
 find_or_create_page include/linux/pagemap.h:420 [inline]
 ni_readpage_cmpr+0x2c6/0x890 fs/ntfs3/frecord.c:2089
 ntfs_readpage+0x189/0x200 fs/ntfs3/inode.c:726
 filemap_read_page+0x17b/0x4c0 mm/filemap.c:2386
 filemap_update_page mm/filemap.c:2464 [inline]
 filemap_get_pages mm/filemap.c:2574 [inline]
 filemap_read+0x13d5/0x2480 mm/filemap.c:2634
 call_read_iter include/linux/fs.h:2166 [inline]
 new_sync_read fs/read_write.c:404 [inline]
 vfs_read+0x725/0xcf0 fs/read_write.c:485
 ksys_read+0x14d/0x250 fs/read_write.c:623
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x66/0xd0
RIP: 0033:0x7fab8d8dd969
RSP: 002b:00007fab8b724038 EFLAGS: 00000246 ORIG_RAX: 0000000000000000
RAX: ffffffffffffffda RBX: 00007fab8db05080 RCX: 00007fab8d8dd969
RDX: 0000000000002020 RSI: 0000200000002840 RDI: 0000000000000004
RBP: 00007fab8d95fab1 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 00007fab8db05080 R15: 00007ffeb4d1b298
 </TASK>
INFO: task syz.7.430:6958 blocked for more than 143 seconds.
      Not tainted 5.15.181-syzkaller #0
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
task:syz.7.430       state:D stack:27976 pid: 6958 ppid:  5810 flags:0x00004004
Call Trace:
 <TASK>
 context_switch kernel/sched/core.c:5030 [inline]
 __schedule+0x11b8/0x43b0 kernel/sched/core.c:6376
 schedule+0x11b/0x1e0 kernel/sched/core.c:6459
 schedule_preempt_disabled+0xf/0x20 kernel/sched/core.c:6518
 __mutex_lock_common+0xc71/0x2390 kernel/locking/mutex.c:669
 __mutex_lock kernel/locking/mutex.c:729 [inline]
 mutex_lock_nested+0x17/0x20 kernel/locking/mutex.c:743
 ni_lock fs/ntfs3/ntfs_fs.h:1100 [inline]
 ntfs_readpage+0x17c/0x200 fs/ntfs3/inode.c:725
 filemap_read_page+0x17b/0x4c0 mm/filemap.c:2386
 filemap_update_page mm/filemap.c:2464 [inline]
 filemap_get_pages mm/filemap.c:2574 [inline]
 filemap_read+0x13d5/0x2480 mm/filemap.c:2634
 call_read_iter include/linux/fs.h:2166 [inline]
 generic_file_splice_read+0x3a2/0x590 fs/splice.c:311
 do_splice_to fs/splice.c:796 [inline]
 splice_file_to_pipe+0x1c6/0x330 fs/splice.c:1018
 do_sendfile+0x56b/0xec0 fs/read_write.c:1256
 __do_sys_sendfile64 fs/read_write.c:1317 [inline]
 __se_sys_sendfile64+0x13b/0x190 fs/read_write.c:1303
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x66/0xd0
RIP: 0033:0x7fab8d8dd969
RSP: 002b:00007fab8b2e0038 EFLAGS: 00000246 ORIG_RAX: 0000000000000028
RAX: ffffffffffffffda RBX: 00007fab8db05240 RCX: 00007fab8d8dd969
RDX: 0000000000000000 RSI: 0000000000000004 RDI: 0000000000000000
RBP: 00007fab8d95fab1 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000003 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000001 R14: 00007fab8db05240 R15: 00007ffeb4d1b298
 </TASK>

Showing all locks held in the system:
1 lock held by khungtaskd/27:
 #0: ffffffff8c11be60 (rcu_read_lock){....}-{1:2}, at: rcu_lock_acquire+0x0/0x30
2 locks held by getty/3929:
 #0: ffff88802c427098 (&tty->ldisc_sem){++++}-{0:0}, at: tty_ldisc_ref_wait+0x21/0x70 drivers/tty/tty_ldisc.c:252
 #1: ffffc900026362e8 (&ldata->atomic_read_lock){+.+.}-{3:3}, at: n_tty_read+0x5ba/0x1a30 drivers/tty/n_tty.c:2158
1 lock held by syz-executor/4156:
 #0: ffff88807b28c068 (&pipe->mutex/1){+.+.}-{3:3}, at: __pipe_lock fs/pipe.c:102 [inline]
 #0: ffff88807b28c068 (&pipe->mutex/1){+.+.}-{3:3}, at: pipe_release+0x4d/0x330 fs/pipe.c:723
4 locks held by kworker/1:6/4246:
 #0: ffff8880b913a318 (&rq->__lock){-.-.}-{2:2}, at: raw_spin_rq_lock_nested+0x26/0x140 kernel/sched/core.c:475
 #1: ffff8880b9127848 (&per_cpu_ptr(group->pcpu, cpu)->seq){-.-.}-{0:0}, at: psi_task_switch+0x495/0x810 kernel/sched/psi.c:882
 #2: ffff888077289400 (&nsim_dev->port_list_lock#2){+.+.}-{3:3}, at: nsim_dev_trap_report_work+0x56/0xb40 drivers/net/netdevsim/dev.c:757
 #3: ffffffff9631da30 (&obj_hash[i].lock){-.-.}-{2:2}, at: debug_object_activate+0x65/0x480 lib/debugobjects.c:694
3 locks held by syz.7.430/6937:
 #0: ffff888051cf8d70 (&f->f_pos_lock){+.+.}-{3:3}, at: __fdget_pos+0x2bf/0x370 fs/file.c:1058
 #1: ffff88805f666520 (mapping.invalidate_lock#8){.+.+}-{3:3}, at: filemap_invalidate_lock_shared include/linux/fs.h:842 [inline]
 #1: ffff88805f666520 (mapping.invalidate_lock#8){.+.+}-{3:3}, at: filemap_update_page mm/filemap.c:2435 [inline]
 #1: ffff88805f666520 (mapping.invalidate_lock#8){.+.+}-{3:3}, at: filemap_get_pages mm/filemap.c:2574 [inline]
 #1: ffff88805f666520 (mapping.invalidate_lock#8){.+.+}-{3:3}, at: filemap_read+0x8b6/0x2480 mm/filemap.c:2634
 #2: ffff88805f6660e0 (&ni->ni_lock/5){+.+.}-{3:3}, at: ni_lock fs/ntfs3/ntfs_fs.h:1100 [inline]
 #2: ffff88805f6660e0 (&ni->ni_lock/5){+.+.}-{3:3}, at: ntfs_readpage+0x17c/0x200 fs/ntfs3/inode.c:725
3 locks held by syz.7.430/6958:
 #0: ffff88807b28c068 (&pipe->mutex/1){+.+.}-{3:3}, at: splice_file_to_pipe+0x2a/0x330 fs/splice.c:1015
 #1: ffff88805f666520 (mapping.invalidate_lock#8){.+.+}-{3:3}, at: filemap_invalidate_lock_shared include/linux/fs.h:842 [inline]
 #1: ffff88805f666520 (mapping.invalidate_lock#8){.+.+}-{3:3}, at: filemap_update_page mm/filemap.c:2435 [inline]
 #1: ffff88805f666520 (mapping.invalidate_lock#8){.+.+}-{3:3}, at: filemap_get_pages mm/filemap.c:2574 [inline]
 #1: ffff88805f666520 (mapping.invalidate_lock#8){.+.+}-{3:3}, at: filemap_read+0x8b6/0x2480 mm/filemap.c:2634
 #2: ffff88805f6660e0 (&ni->ni_lock/5){+.+.}-{3:3}, at: ni_lock fs/ntfs3/ntfs_fs.h:1100 [inline]
 #2: ffff88805f6660e0 (&ni->ni_lock/5){+.+.}-{3:3}, at: ntfs_readpage+0x17c/0x200 fs/ntfs3/inode.c:725

=============================================

NMI backtrace for cpu 1
CPU: 1 PID: 27 Comm: khungtaskd Not tainted 5.15.181-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/19/2025
Call Trace:
 <TASK>
 dump_stack_lvl+0x168/0x230 lib/dump_stack.c:106
 nmi_cpu_backtrace+0x397/0x3d0 lib/nmi_backtrace.c:111
 nmi_trigger_cpumask_backtrace+0x163/0x280 lib/nmi_backtrace.c:62
 trigger_all_cpu_backtrace include/linux/nmi.h:148 [inline]
 check_hung_uninterruptible_tasks kernel/hung_task.c:212 [inline]
 watchdog+0xe0f/0xe50 kernel/hung_task.c:369
 kthread+0x436/0x520 kernel/kthread.c:334
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:287
 </TASK>
Sending NMI from CPU 1 to CPUs 0:
NMI backtrace for cpu 0 skipped: idling at native_safe_halt arch/x86/include/asm/irqflags.h:51 [inline]
NMI backtrace for cpu 0 skipped: idling at arch_safe_halt arch/x86/include/asm/irqflags.h:89 [inline]
NMI backtrace for cpu 0 skipped: idling at default_idle+0xb/0x10 arch/x86/kernel/process.c:722

Crashes (4):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/05/05 16:35 linux-5.15.y 16fdf2c7111b 6ca47dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan INFO: task hung in ni_readpage_cmpr
2024/05/08 02:40 linux-5.15.y 284087d4f7d5 4cf3f9b3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan INFO: task hung in ni_readpage_cmpr
2024/02/22 16:23 linux-5.15.y 6139f2a02fe0 345111b5 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan INFO: task hung in ni_readpage_cmpr
2024/02/13 07:31 linux-5.15.y 6139f2a02fe0 77b23aa1 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan INFO: task hung in ni_readpage_cmpr
* Struck through repros no longer work on HEAD.