syzbot


kernel BUG in folio_unlock (2)

Status: upstream: reported C repro on 2024/05/02 16:24
Subsystems: btrfs
[Documentation on labels]
Reported-by: syzbot+9e39ac154d8781441e60@syzkaller.appspotmail.com
First crash: 17d, last: 2d17h
Cause bisection: failed (error log, bisect log)
  
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [btrfs?] kernel BUG in folio_unlock (2) 2 (4) 2024/05/15 16:45
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream kernel BUG in folio_unlock mm 1 392d 388d 0/26 auto-obsoleted due to no activity on 2023/06/22 15:13
upstream kernel BUG in __filemap_get_folio kernel C done 814 590d 760d 22/26 fixed on 2023/02/24 13:50
Last patch testing requests (2)
Created Duration User Patch Repo Result
2024/05/17 05:20 16m retest repro linux-next report log
2024/05/02 23:23 24m hdanton@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git 9c6ecb3cb6e2 OK log

Sample crash report:
 reset_page_owner include/linux/page_owner.h:25 [inline]
 free_pages_prepare mm/page_alloc.c:1088 [inline]
 free_unref_page+0xd22/0xea0 mm/page_alloc.c:2601
 free_contig_range+0x9e/0x160 mm/page_alloc.c:6655
 destroy_args+0x8a/0x890 mm/debug_vm_pgtable.c:1037
 debug_vm_pgtable+0x4be/0x550 mm/debug_vm_pgtable.c:1417
 do_one_initcall+0x248/0x880 init/main.c:1265
 do_initcall_level+0x157/0x210 init/main.c:1327
 do_initcalls+0x3f/0x80 init/main.c:1343
 kernel_init_freeable+0x435/0x5d0 init/main.c:1576
 kernel_init+0x1d/0x2b0 init/main.c:1465
 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
------------[ cut here ]------------
kernel BUG at mm/filemap.c:1507!
Oops: invalid opcode: 0000 [#1] PREEMPT SMP KASAN PTI
CPU: 1 PID: 5109 Comm: syz-executor359 Not tainted 6.9.0-rc6-next-20240502-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/27/2024
RIP: 0010:folio_unlock+0x18b/0x2f0 mm/filemap.c:1507
Code: 4c 89 f0 48 25 ff 0f 00 00 74 62 e8 bf df c9 ff e9 eb fe ff ff e8 b5 df c9 ff 4c 89 f7 48 c7 c6 a0 85 d3 8b e8 96 95 13 00 90 <0f> 0b e8 9e df c9 ff 4c 89 f7 48 c7 c6 a0 8e d3 8b e8 7f 95 13 00
RSP: 0018:ffffc900036b6b48 EFLAGS: 00010246
RAX: 85f60d17a1306500 RBX: 1ffffd40003a3d50 RCX: 0000000000000001
RDX: dffffc0000000000 RSI: ffffffff8bcab340 RDI: 0000000000000001
RBP: 00fff4000000402c R08: ffffffff92faa657 R09: 1ffffffff25f54ca
R10: dffffc0000000000 R11: fffffbfff25f54cb R12: ffffea0001d1ea88
R13: 1ffffd40003a3d51 R14: ffffea0001d1ea80 R15: dffffc0000000000
FS:  00007f5d709cb6c0(0000) GS:ffff8880b9500000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f5d70a710d0 CR3: 000000002e66e000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 __extent_writepage fs/btrfs/extent_io.c:1519 [inline]
 extent_write_cache_pages fs/btrfs/extent_io.c:2173 [inline]
 btrfs_writepages+0x1fab/0x26f0 fs/btrfs/extent_io.c:2294
 do_writepages+0x359/0x870 mm/page-writeback.c:2633
 filemap_fdatawrite_wbc+0x125/0x180 mm/filemap.c:397
 __filemap_fdatawrite_range mm/filemap.c:430 [inline]
 filemap_fdatawrite_range+0x120/0x180 mm/filemap.c:448
 btrfs_fdatawrite_range fs/btrfs/file.c:4050 [inline]
 start_ordered_ops fs/btrfs/file.c:1753 [inline]
 btrfs_sync_file+0x2b4/0xf80 fs/btrfs/file.c:1828
 generic_write_sync include/linux/fs.h:2793 [inline]
 btrfs_do_write_iter+0xb84/0x10a0 fs/btrfs/file.c:1705
 iter_file_splice_write+0xbd7/0x14e0 fs/splice.c:743
 do_splice_from fs/splice.c:941 [inline]
 direct_splice_actor+0x11e/0x220 fs/splice.c:1164
 splice_direct_to_actor+0x58e/0xc90 fs/splice.c:1108
 do_splice_direct_actor fs/splice.c:1207 [inline]
 do_splice_direct+0x28c/0x3e0 fs/splice.c:1233
 vfs_copy_file_range+0xd37/0x1510 fs/read_write.c:1558
 __do_sys_copy_file_range fs/read_write.c:1612 [inline]
 __se_sys_copy_file_range+0x3f2/0x5d0 fs/read_write.c:1575
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xf5/0x240 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f5d70a356c9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 81 18 00 00 90 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 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f5d709cb208 EFLAGS: 00000246 ORIG_RAX: 0000000000000146
RAX: ffffffffffffffda RBX: 00007f5d70ac1618 RCX: 00007f5d70a356c9
RDX: 0000000000000004 RSI: 0000000000000000 RDI: 0000000000000005
RBP: 00007f5d70ac1610 R08: ffffffffa003e45b R09: 0700000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00007f5d70a8e1b0
R13: 007570637265705f R14: 6f6f6c2f7665642f R15: 0700000000000000
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:folio_unlock+0x18b/0x2f0 mm/filemap.c:1507
Code: 4c 89 f0 48 25 ff 0f 00 00 74 62 e8 bf df c9 ff e9 eb fe ff ff e8 b5 df c9 ff 4c 89 f7 48 c7 c6 a0 85 d3 8b e8 96 95 13 00 90 <0f> 0b e8 9e df c9 ff 4c 89 f7 48 c7 c6 a0 8e d3 8b e8 7f 95 13 00
RSP: 0018:ffffc900036b6b48 EFLAGS: 00010246
RAX: 85f60d17a1306500 RBX: 1ffffd40003a3d50 RCX: 0000000000000001
RDX: dffffc0000000000 RSI: ffffffff8bcab340 RDI: 0000000000000001
RBP: 00fff4000000402c R08: ffffffff92faa657 R09: 1ffffffff25f54ca
R10: dffffc0000000000 R11: fffffbfff25f54cb R12: ffffea0001d1ea88
R13: 1ffffd40003a3d51 R14: ffffea0001d1ea80 R15: dffffc0000000000
FS:  00007f5d709cb6c0(0000) GS:ffff8880b9500000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f5d70a710d0 CR3: 000000002e66e000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400

Crashes (4):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/05/02 16:11 linux-next 9c6ecb3cb6e2 3ba885bc .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-linux-next-kasan-gce-root kernel BUG in folio_unlock
2024/05/17 13:06 upstream ea5f6ad9ad96 c2e07261 .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream kernel BUG in folio_unlock
2024/05/17 09:01 upstream ea5f6ad9ad96 c2e07261 .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream kernel BUG in folio_unlock
2024/05/02 14:57 linux-next 9c6ecb3cb6e2 3ba885bc .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in folio_unlock
* Struck through repros no longer work on HEAD.