* Re: [syzbot] [f2fs?] INFO: task hung in do_truncate (3) [not found] <675101f3.050a0220.17bd51.0081.GAE@google.com> @ 2025-04-23 7:49 ` syzbot 2025-04-23 21:05 ` Kane York 0 siblings, 1 reply; 2+ messages in thread From: syzbot @ 2025-04-23 7:49 UTC (permalink / raw) To: brauner, chao, jack, jaegeuk, kent.overstreet, linux-bcachefs, linux-f2fs-devel, linux-fsdevel, linux-kernel, syzkaller-bugs, viro syzbot has found a reproducer for the following issue on: HEAD commit: bc3372351d0c Merge tag 'for-6.15-rc3-tag' of git://git.ker.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=138cdccc580000 kernel config: https://syzkaller.appspot.com/x/.config?x=3bbffc3b5b4301e1 dashboard link: https://syzkaller.appspot.com/bug?extid=effe7da6578cd423f98f compiler: Debian clang version 15.0.6, Debian LLD 15.0.6 syz repro: https://syzkaller.appspot.com/x/repro.syz?x=17c8ac70580000 Downloadable assets: disk image: https://storage.googleapis.com/syzbot-assets/6c893a6bd7cc/disk-bc337235.raw.xz vmlinux: https://storage.googleapis.com/syzbot-assets/6c31d81cbcae/vmlinux-bc337235.xz kernel image: https://storage.googleapis.com/syzbot-assets/acf5d144656b/bzImage-bc337235.xz mounted in repro #1: https://storage.googleapis.com/syzbot-assets/53b1b110f131/mount_0.gz fsck result: failed (log: https://syzkaller.appspot.com/x/fsck.log?x=16d4f204580000) mounted in repro #2: https://storage.googleapis.com/syzbot-assets/3185ba5a394f/mount_4.gz fsck result: OK (log: https://syzkaller.appspot.com/x/fsck.log?x=14ebe7ac580000) IMPORTANT: if you fix the issue, please add the following tag to the commit: Reported-by: syzbot+effe7da6578cd423f98f@syzkaller.appspotmail.com INFO: task syz.9.68:6713 blocked for more than 143 seconds. Not tainted 6.15.0-rc3-syzkaller-00019-gbc3372351d0c #0 "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message. task:syz.9.68 state:D stack:27592 pid:6713 tgid:6701 ppid:6519 task_flags:0x400140 flags:0x00004006 Call Trace: <TASK> context_switch kernel/sched/core.c:5382 [inline] __schedule+0x1b33/0x51f0 kernel/sched/core.c:6767 __schedule_loop kernel/sched/core.c:6845 [inline] schedule+0x163/0x360 kernel/sched/core.c:6860 schedule_preempt_disabled+0x13/0x30 kernel/sched/core.c:6917 rwsem_down_write_slowpath+0xedd/0x1420 kernel/locking/rwsem.c:1176 __down_write_common kernel/locking/rwsem.c:1304 [inline] __down_write kernel/locking/rwsem.c:1313 [inline] down_write+0x1da/0x220 kernel/locking/rwsem.c:1578 inode_lock include/linux/fs.h:867 [inline] do_truncate+0x20e/0x310 fs/open.c:63 vfs_truncate+0x4a6/0x540 fs/open.c:115 do_sys_truncate+0xd8/0x190 fs/open.c:138 __do_sys_truncate fs/open.c:150 [inline] __se_sys_truncate fs/open.c:148 [inline] __x64_sys_truncate+0x5b/0x70 fs/open.c:148 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xf3/0x210 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f6c9918e169 RSP: 002b:00007f6c983dd038 EFLAGS: 00000246 ORIG_RAX: 000000000000004c RAX: ffffffffffffffda RBX: 00007f6c993b6080 RCX: 00007f6c9918e169 RDX: 0000000000000000 RSI: 0000000000008001 RDI: 00002000000000c0 RBP: 00007f6c99210a68 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000001 R14: 00007f6c993b6080 R15: 00007ffc2675ba78 --- If you want syzbot to run the reproducer, reply with: #syz test: git://repo/address.git branch-or-commit-hash If you attach or paste a git patch, syzbot will apply it before testing. ^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [syzbot] [f2fs?] INFO: task hung in do_truncate (3) 2025-04-23 7:49 ` [syzbot] [f2fs?] INFO: task hung in do_truncate (3) syzbot @ 2025-04-23 21:05 ` Kane York 0 siblings, 0 replies; 2+ messages in thread From: Kane York @ 2025-04-23 21:05 UTC (permalink / raw) To: syzbot+effe7da6578cd423f98f Cc: brauner, chao, jack, jaegeuk, kent.overstreet, linux-bcachefs, linux-f2fs-devel, linux-fsdevel, linux-kernel, syzkaller-bugs, viro This crash appears to entirely ignore the provided filesystem images and just does tricky fallocate calls followed by a truncate, so it should be easier than normal to diagnose. The cwd is opened with O_DIRECT. (or this is EFAULT because path is nullptr?) The victim file is created with O_NONBLOCK and O_SYNC; that fd is discarded. The victim file is opened again with O_SYNC and FALLOC_FL_ZERO_RANGE is called with a gargantuan size. The victim file is opened again with O_APPEND (!) and FALLOC_FL_INSERT_RANGE is called with a modest size. Truncate is called midway through the just-inserted range. Annotated calls below. # https://syzkaller.appspot.com/bug?id=7d29d6d7a773d4f608a33cf6a7593faadb1b5803 # See https://goo.gl/kgGztJ for information about syzkaller reproducers. #{"threaded":true,"repeat":true,"procs":5,"slowdown":1,"sandbox":"none","sandbox_arg":0,"tun":true,"netdev":true,"resetnet":true,"cgroups":true,"binfmt_misc":true,"close_fds":true,"usb":true,"vhci":true,"wifi":true,"ieee802154":true,"sysctl":true,"swap":true,"tmpdir":true,"segv":true} # mount file2 syz_mount_image$f2fs(&(0x7f0000000040), &(0x7f00000000c0)='./file2\x00', 0x0, &(0x7f0000000300)={[{@noinline_xattr}, {@noinline_dentry}, {@prjjquota={'prjjquota', 0x3d, 'active_logs=4'}}, {@jqfmt_vfsv1}, {@noinline_data}, {@noheap}, {@checkpoint_diasble}, {@fastboot}, {@fsync_mode_strict}, {@discard_unit_section}]}, 0x21, 0x552d, &(0x7f000000abc0)="$[removed]") # EBADF pread64(0xffffffffffffffff, 0x0, 0x0, 0xfff) # EBADF openat$cgroup_freezer_state(0xffffffffffffffff, &(0x7f0000000080), 0x2, 0x0) # openat(AT_FDCWD, nullptr, O_DIRECT, 0) # EFAULT? openat$nullb(0xffffffffffffff9c, 0x0, 0x4000, 0x0) # mount 'bus' syz_mount_image$ext4(&(0x7f0000000080)='ext4\x00', &(0x7f00000000c0)='./bus\x00', 0x20081e, &(0x7f0000000040)={[{@nodelalloc}, {@orlov}, {@auto_da_alloc}]}, 0x1, 0x4ef, &(0x7f00000003c0)="$[removed]") # open file1 # O_RDWR | O_CREAT | O_NOCTTY | O_NONBLOCK | FASYNC | O_LARGEFILE | O_SYNC # perm 0500 open(&(0x7f0000000080)='./file1\x00', 0x10b942, 0x140) # open file1 # O_RDWR | O_CREAT | O_LARGEFILE | O_SYNC # perm 0210 r0 = open(&(0x7f0000000100)='./file1\x00', 0x109042, 0x88) # fallocate FALLOC_FL_ZERO_RANGE, offset 0, size 0x7000000 fallocate(r0, 0x10, 0x0, 0x7000000) # openat(AT_FDCWD) file1 # O_WRONLY | O_CREAT | O_APPEND # perm 0512 r1 = openat(0xffffffffffffff9c, &(0x7f0000000080)='./file1\x00', 0x441, 0x14a) # fallocate file1 FALLOC_FL_INSERT_RANGE, offset x4000, size x8000 # EPERM? fallocate(r1, 0x20, 0x4000, 0x8000) # truncate file1 size x8001 truncate(&(0x7f00000000c0)='./file1\x00', 0x8001) ^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-04-23 21:05 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <675101f3.050a0220.17bd51.0081.GAE@google.com>
2025-04-23 7:49 ` [syzbot] [f2fs?] INFO: task hung in do_truncate (3) syzbot
2025-04-23 21:05 ` Kane York
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox