syzbot


kernel BUG in free_unref_page_prepare

Status: auto-obsoleted due to no activity on 2023/10/07 05:30
Subsystems: mm
[Documentation on labels]
Reported-by: syzbot+7423f066b632d9ff23d5@syzkaller.appspotmail.com
First crash: 465d, last: 455d
Cause bisection: introduced by (bisect log) :
commit 3a77b282e256d880791a4c5aa10ede13d6417425
Author: Matthew Wilcox (Oracle) <willy@infradead.org>
Date: Wed Aug 16 15:11:58 2023 +0000

  mm: free up a word in the first tail page

Crash: kernel BUG in __free_pages_ok (log)
Repro: C syz .config
  
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [mm?] kernel BUG in free_unref_page_prepare 1 (3) 2023/09/01 14:16
Last patch testing requests (1)
Created Duration User Patch Repo Result
2023/09/12 12:43 23m retest repro linux-next OK log
Cause bisection attempts (2)
Created Duration User Patch Repo Result
2023/09/01 03:42 10h32m bisect linux-next OK (1) job log log
2023/08/22 01:11 5m bisect linux-next error job log
marked invalid by nogikh@google.com

Sample crash report:
 __do_sys_mmap arch/x86/kernel/sys_x86_64.c:93 [inline]
 __se_sys_mmap arch/x86/kernel/sys_x86_64.c:86 [inline]
 __x64_sys_mmap+0x125/0x190 arch/x86/kernel/sys_x86_64.c:86
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x38/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
page last free stack trace:
 reset_page_owner include/linux/page_owner.h:24 [inline]
 free_pages_prepare mm/page_alloc.c:1136 [inline]
 free_unref_page_prepare+0x476/0xa40 mm/page_alloc.c:2348
 free_unref_page+0x33/0x3b0 mm/page_alloc.c:2441
 free_contig_range+0xb6/0x190 mm/page_alloc.c:6391
 destroy_args+0x768/0x990 mm/debug_vm_pgtable.c:1028
 debug_vm_pgtable+0x1d7e/0x3e00 mm/debug_vm_pgtable.c:1408
 do_one_initcall+0x117/0x630 init/main.c:1232
 do_initcall_level init/main.c:1294 [inline]
 do_initcalls init/main.c:1310 [inline]
 do_basic_setup init/main.c:1329 [inline]
 kernel_init_freeable+0x5c2/0x900 init/main.c:1547
 kernel_init+0x1c/0x2a0 init/main.c:1437
 ret_from_fork+0x45/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:304
------------[ cut here ]------------
kernel BUG at mm/page_alloc.c:1107!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
CPU: 0 PID: 5045 Comm: syz-executor350 Not tainted 6.5.0-rc6-next-20230818-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
RIP: 0010:free_pages_prepare mm/page_alloc.c:1107 [inline]
RIP: 0010:free_unref_page_prepare+0x885/0xa40 mm/page_alloc.c:2348
Code: 48 89 d7 e8 5d 2e f4 ff 0f 0b c7 44 24 08 00 00 00 00 4d 8d 77 40 e9 79 fd ff ff 48 c7 c6 80 b9 99 8a 4c 89 ff e8 3b 2e f4 ff <0f> 0b 48 89 ef e8 81 db 0b 00 e9 aa f7 ff ff 4c 89 f7 e8 74 db 0b
RSP: 0018:ffffc9000397f6c0 EFLAGS: 00010293
RAX: 0000000000000000 RBX: 0000000000000009 RCX: 0000000000000000
RDX: ffff88807af30000 RSI: ffffffff81d178f5 RDI: 0000000000000000
RBP: ffffea0001b10008 R08: 0000000000000000 R09: fffffbfff1d9bbf2
R10: ffffffff8ecddf97 R11: 1ffffffff1976ca9 R12: 000000000006c400
R13: 0000000000000009 R14: ffffea0001b10040 R15: ffffea0001b10000
FS:  0000000000000000(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f154f89164c CR3: 0000000029448000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 free_unref_page+0x33/0x3b0 mm/page_alloc.c:2441
 __update_and_free_hugetlb_folio+0x3c1/0x4a0 mm/hugetlb.c:1765
 update_and_free_hugetlb_folio+0x82/0x120 mm/hugetlb.c:1821
 free_huge_folio+0x6e0/0xbb0 mm/hugetlb.c:1917
 release_pages+0x51b/0x14e0 mm/swap.c:1008
 __folio_batch_release+0x77/0xe0 mm/swap.c:1062
 folio_batch_release include/linux/pagevec.h:83 [inline]
 remove_inode_hugepages+0xb7b/0xe20 fs/hugetlbfs/inode.c:691
 hugetlbfs_evict_inode+0x22/0x70 fs/hugetlbfs/inode.c:703
 evict+0x2ed/0x6b0 fs/inode.c:664
 iput_final fs/inode.c:1775 [inline]
 iput.part.0+0x55e/0x7a0 fs/inode.c:1801
 iput+0x5c/0x80 fs/inode.c:1791
 dentry_unlink_inode+0x292/0x430 fs/dcache.c:401
 __dentry_kill+0x3b8/0x640 fs/dcache.c:607
 dentry_kill fs/dcache.c:733 [inline]
 dput+0x8dd/0xfd0 fs/dcache.c:913
 __fput+0x536/0xa70 fs/file_table.c:392
 task_work_run+0x14d/0x240 kernel/task_work.c:179
 exit_task_work include/linux/task_work.h:38 [inline]
 do_exit+0xa99/0x2a20 kernel/exit.c:874
 do_group_exit+0xd4/0x2a0 kernel/exit.c:1024
 __do_sys_exit_group kernel/exit.c:1035 [inline]
 __se_sys_exit_group kernel/exit.c:1033 [inline]
 __x64_sys_exit_group+0x3e/0x50 kernel/exit.c:1033
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x38/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f154f8c0b09
Code: Unable to access opcode bytes at 0x7f154f8c0adf.
RSP: 002b:00007fffeb55e118 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f154f8c0b09
RDX: 000000000000003c RSI: 00000000000000e7 RDI: 0000000000000000
RBP: 00007f154f93b290 R08: ffffffffffffffb8 R09: 0000000000000000
R10: 0000000000048031 R11: 0000000000000246 R12: 00007f154f93b290
R13: 0000000000000000 R14: 00007f154f93bce0 R15: 00007f154f891d60
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:free_pages_prepare mm/page_alloc.c:1107 [inline]
RIP: 0010:free_unref_page_prepare+0x885/0xa40 mm/page_alloc.c:2348
Code: 48 89 d7 e8 5d 2e f4 ff 0f 0b c7 44 24 08 00 00 00 00 4d 8d 77 40 e9 79 fd ff ff 48 c7 c6 80 b9 99 8a 4c 89 ff e8 3b 2e f4 ff <0f> 0b 48 89 ef e8 81 db 0b 00 e9 aa f7 ff ff 4c 89 f7 e8 74 db 0b
RSP: 0018:ffffc9000397f6c0 EFLAGS: 00010293
RAX: 0000000000000000 RBX: 0000000000000009 RCX: 0000000000000000
RDX: ffff88807af30000 RSI: ffffffff81d178f5 RDI: 0000000000000000
RBP: ffffea0001b10008 R08: 0000000000000000 R09: fffffbfff1d9bbf2
R10: ffffffff8ecddf97 R11: 1ffffffff1976ca9 R12: 000000000006c400
R13: 0000000000000009 R14: ffffea0001b10040 R15: ffffea0001b10000
FS:  0000000000000000(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000055d22c54e0b8 CR3: 0000000029448000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400

Crashes (1489):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/08/19 04:10 linux-next 7271b2a53042 d216d8a0 .config strace log report syz C [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/28 05:29 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/28 03:43 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/28 02:34 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/28 01:33 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/28 01:22 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/28 00:22 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 23:32 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 22:29 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 21:30 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 20:50 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 19:36 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 18:52 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 17:43 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 16:49 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 16:23 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 15:09 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 14:27 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 14:27 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 12:54 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 11:55 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 11:05 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 10:01 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 09:40 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 08:12 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 06:47 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 05:42 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 02:56 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 01:50 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/27 00:07 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 23:23 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 22:21 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 21:54 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 21:30 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 19:01 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 17:22 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 16:20 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 15:39 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 14:01 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 12:08 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 11:25 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 09:39 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 09:01 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 08:07 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 06:24 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
2023/08/26 06:17 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root kernel BUG in free_unref_page_prepare
* Struck through repros no longer work on HEAD.