shmem_truncate_range mm/shmem.c:1062 [inline] shmem_evict_inode+0x248/0xa40 mm/shmem.c:1171 evict+0x485/0x870 fs/inode.c:705 __dentry_kill+0x431/0x650 fs/dcache.c:611 dentry_kill+0xb8/0x290 fs/dcache.c:-1 dput+0xfa/0x1d0 fs/dcache.c:918 __fput+0x5e0/0x920 fs/file_table.c:328 task_work_run+0x1ca/0x250 kernel/task_work.c:203 exit_task_work include/linux/task_work.h:39 [inline] do_exit+0x93e/0x2400 kernel/exit.c:880 __do_sys_exit kernel/exit.c:989 [inline] __se_sys_exit kernel/exit.c:987 [inline] __x64_sys_exit+0x3c/0x40 kernel/exit.c:987 do_syscall_x64 arch/x86/entry/common.c:51 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:81 entry_SYSCALL_64_after_hwframe+0x68/0xd2 ------------[ cut here ]------------ kernel BUG at mm/filemap.c:153! invalid opcode: 0000 [#1] PREEMPT SMP KASAN CPU: 1 PID: 7510 Comm: syz.0.915 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/02/2025 RIP: 0010:filemap_unaccount_folio+0x5cf/0xa80 mm/filemap.c:153 Code: 07 38 c1 0f 8c 19 fe ff ff 4c 89 e7 e8 9a 7f 27 00 e9 0c fe ff ff e8 c0 50 d7 ff 48 89 df 48 c7 c6 40 ec 94 8a e8 e1 e0 11 00 <0f> 0b e8 aa 50 d7 ff 48 89 df 48 c7 c6 a0 f1 94 8a e8 cb e0 11 00 RSP: 0018:ffffc9000d857618 EFLAGS: 00010046 RAX: 15bae3b608a23f00 RBX: ffffea0001396e80 RCX: 15bae3b608a23f00 RDX: 0000000000000002 RSI: ffffffff8a8c1700 RDI: ffffffff8adef760 RBP: ffffc9000d857778 R08: dffffc0000000000 R09: fffffbfff1c3ed56 R10: fffffbfff1c3ed56 R11: 1ffffffff1c3ed55 R12: dffffc0000000000 R13: dffffc0000000000 R14: ffff8880770dc8d8 R15: ffff8880770dc8e0 FS: 0000555556e9a500(0000) GS:ffff8880b8f00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 000000110c336dca CR3: 000000002fc60000 CR4: 00000000003506e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: __filemap_remove_folio+0xbb/0x860 mm/filemap.c:222 filemap_remove_folio+0xed/0x2c0 mm/filemap.c:255 truncate_inode_folio+0x59/0x70 mm/truncate.c:195 shmem_undo_range+0x4d2/0x2050 mm/shmem.c:942 shmem_truncate_range mm/shmem.c:1062 [inline] shmem_evict_inode+0x248/0xa40 mm/shmem.c:1171 evict+0x485/0x870 fs/inode.c:705 __dentry_kill+0x431/0x650 fs/dcache.c:611 dentry_kill+0xb8/0x290 fs/dcache.c:-1 dput+0xfa/0x1d0 fs/dcache.c:918 __fput+0x5e0/0x920 fs/file_table.c:328 task_work_run+0x1ca/0x250 kernel/task_work.c:203 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] exit_to_user_mode_loop+0xe6/0x110 kernel/entry/common.c:177 exit_to_user_mode_prepare+0xee/0x180 kernel/entry/common.c:210 __syscall_exit_to_user_mode_work kernel/entry/common.c:292 [inline] syscall_exit_to_user_mode+0x16/0x40 kernel/entry/common.c:303 do_syscall_64+0x58/0xa0 arch/x86/entry/common.c:87 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7fca7378f6c9 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 a8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007ffe279d9ef8 EFLAGS: 00000246 ORIG_RAX: 00000000000001b4 RAX: 0000000000000000 RBX: 000000000005f9bd RCX: 00007fca7378f6c9 RDX: 0000000000000000 RSI: 000000000000001e RDI: 0000000000000003 RBP: 00007fca739e7da0 R08: 0000000000000001 R09: 0000000a279da1ef R10: 0000001b2e420000 R11: 0000000000000246 R12: 00007fca739e5fac R13: 00007fca739e5fa0 R14: ffffffffffffffff R15: 00007ffe279da010 Modules linked in: ---[ end trace 0000000000000000 ]--- RIP: 0010:filemap_unaccount_folio+0x5cf/0xa80 mm/filemap.c:153 Code: 07 38 c1 0f 8c 19 fe ff ff 4c 89 e7 e8 9a 7f 27 00 e9 0c fe ff ff e8 c0 50 d7 ff 48 89 df 48 c7 c6 40 ec 94 8a e8 e1 e0 11 00 <0f> 0b e8 aa 50 d7 ff 48 89 df 48 c7 c6 a0 f1 94 8a e8 cb e0 11 00 RSP: 0018:ffffc9000d857618 EFLAGS: 00010046 RAX: 15bae3b608a23f00 RBX: ffffea0001396e80 RCX: 15bae3b608a23f00 RDX: 0000000000000002 RSI: ffffffff8a8c1700 RDI: ffffffff8adef760 RBP: ffffc9000d857778 R08: dffffc0000000000 R09: fffffbfff1c3ed56 R10: fffffbfff1c3ed56 R11: 1ffffffff1c3ed55 R12: dffffc0000000000 R13: dffffc0000000000 R14: ffff8880770dc8d8 R15: ffff8880770dc8e0 FS: 0000555556e9a500(0000) GS:ffff8880b8f00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 000000110c336dca CR3: 000000002fc60000 CR4: 00000000003506e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400