Re: [syzbot] [kernel?] WARNING in flush_tlb_func

From: syzbot
Date: Tue Dec 03 2024 - 08:09:02 EST


syzbot has found a reproducer for the following issue on:

HEAD commit: f486c8aa16b8 Add linux-next specific files for 20241128
git tree: linux-next
console output: https://syzkaller.appspot.com/x/log.txt?x=11f24330580000
kernel config: https://syzkaller.appspot.com/x/.config?x=e348a4873516af92
dashboard link: https://syzkaller.appspot.com/bug?extid=2f32bc207cbe5ca4b7a2
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=17c16fc0580000

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/beb58ebb63cf/disk-f486c8aa.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/b241b5609e64/vmlinux-f486c8aa.xz
kernel image: https://storage.googleapis.com/syzbot-assets/c9d817f665f2/bzImage-f486c8aa.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+2f32bc207cbe5ca4b7a2@xxxxxxxxxxxxxxxxxxxxxxxxx

------------[ cut here ]------------
WARNING: CPU: 0 PID: 6867 at arch/x86/mm/tlb.c:817 flush_tlb_func+0x631/0x700 arch/x86/mm/tlb.c:817
Modules linked in:
CPU: 0 UID: 0 PID: 6867 Comm: syz.0.220 Not tainted 6.12.0-next-20241128-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
RIP: 0010:flush_tlb_func+0x631/0x700 arch/x86/mm/tlb.c:817
Code: e9 16 fb ff ff 90 0f 0b 90 e9 76 fb ff ff 45 31 f6 49 bc 00 00 00 00 00 fc ff df e9 53 ff ff ff 90 0f 0b 90 e9 8f fc ff ff 90 <0f> 0b 90 e9 a8 fc ff ff 90 0f 0b 90 e9 d5 fb ff ff 90 0f 0b 90 e9
RSP: 0018:ffffc9000bba66c0 EFLAGS: 00010002
RAX: dffffc0000000000 RBX: ffff8880b863d7c0 RCX: dffffc0000000000
RDX: 0000000000000000 RSI: 0000000000000008 RDI: ffff88802887ae88
RBP: ffffc9000bba67b0 R08: ffff88802887ae8f R09: 1ffff1100510f5d1
R10: dffffc0000000000 R11: ffffed100510f5d2 R12: 1ffff110170c7afb
R13: 00000000000000f2 R14: 00000000000000f1 R15: ffff8880b863d7d8
FS: 00007f9f571dd6c0(0000) GS:ffff8880b8600000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000000 CR3: 000000003394a000 CR4: 00000000003526f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
csd_do_func kernel/smp.c:134 [inline]
smp_call_function_many_cond+0x1760/0x2c60 kernel/smp.c:875
on_each_cpu_cond_mask+0x3f/0x80 kernel/smp.c:1051
__flush_tlb_multi arch/x86/include/asm/paravirt.h:91 [inline]
flush_tlb_multi arch/x86/mm/tlb.c:939 [inline]
flush_tlb_mm_range+0x329/0x5c0 arch/x86/mm/tlb.c:1025
flush_tlb_page arch/x86/include/asm/tlbflush.h:254 [inline]
ptep_clear_flush+0x11a/0x170 mm/pgtable-generic.c:101
page_vma_mkclean_one+0x58a/0x9a0 mm/rmap.c:1051
page_mkclean_one+0x280/0x420 mm/rmap.c:1092
rmap_walk_file+0x52f/0x9f0 mm/rmap.c:2708
rmap_walk mm/rmap.c:2726 [inline]
folio_mkclean+0x262/0x440 mm/rmap.c:1124
folio_clear_dirty_for_io+0x22b/0xd00 mm/page-writeback.c:3033
mpage_submit_folio+0x88/0x230 fs/ext4/inode.c:1913
mpage_process_page_bufs+0x6c9/0x8d0 fs/ext4/inode.c:2045
mpage_prepare_extent_to_map+0xec7/0x1c80 fs/ext4/inode.c:2546
ext4_do_writepages+0xc4d/0x3d10 fs/ext4/inode.c:2688
ext4_writepages+0x213/0x3c0 fs/ext4/inode.c:2824
do_writepages+0x35f/0x880 mm/page-writeback.c:2702
filemap_fdatawrite_wbc mm/filemap.c:397 [inline]
__filemap_fdatawrite_range mm/filemap.c:430 [inline]
file_write_and_wait_range+0x2a3/0x3c0 mm/filemap.c:787
ext4_sync_file+0x25d/0xb90 fs/ext4/fsync.c:158
__do_sys_msync mm/msync.c:96 [inline]
__se_sys_msync+0x3d7/0x5a0 mm/msync.c:32
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f9f57f7ff19
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:00007f9f571dd058 EFLAGS: 00000246 ORIG_RAX: 000000000000001a
RAX: ffffffffffffffda RBX: 00007f9f58146160 RCX: 00007f9f57f7ff19
RDX: 0000000000000004 RSI: 087abbe8d1cc6ad9 RDI: 0000000020952000
RBP: 00007f9f57ff3986 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 00007f9f58146160 R15: 00007ffe71c92b58
</TASK>


---
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.