syzbot


WARNING in handle_userfault

Status: upstream: reported C repro on 2023/07/05 06:32
Subsystems: mm
[Documentation on labels]
Reported-by: syzbot+339b02f826caafd5f7a8@syzkaller.appspotmail.com
Fix commit: mm: fix a lockdep issue in vma_assert_write_locked
Patched on: [ci-upstream-linux-next-kasan-gce-root], missing on: [ci-qemu-gce-upstream-auto ci-qemu-native-arm64-kvm ci-qemu-upstream ci-qemu-upstream-386 ci-qemu2-arm32 ci-qemu2-arm64 ci-qemu2-arm64-compat ci-qemu2-arm64-mte ci-qemu2-riscv64 ci-snapshot-upstream-root ci-upstream-bpf-kasan-gce ci-upstream-bpf-next-kasan-gce ci-upstream-gce-arm64 ci-upstream-gce-leak ci-upstream-kasan-badwrites-root ci-upstream-kasan-gce ci-upstream-kasan-gce-386 ci-upstream-kasan-gce-root ci-upstream-kasan-gce-selinux-root ci-upstream-kasan-gce-smack-root ci-upstream-kmsan-gce-386-root ci-upstream-kmsan-gce-root ci-upstream-net-kasan-gce ci-upstream-net-this-kasan-gce ci-upstream-rust-kasan-gce ci2-upstream-fs ci2-upstream-kcsan-gce ci2-upstream-usb]
First crash: 1056d, last: 1049d
Cause bisection: failed (error log, bisect log)
  
✨ AI Jobs (1)
ID Workflow Result Correct Bug Created Started Finished Revision Error
7f078a84-18d6-4378-9c3b-1a7826a205ce assessment-security 💥 WARNING in handle_userfault 2026/05/21 08:47 2026/05/21 08:47 2026/05/21 09:08 cf874a1cf36318c06202027159ddac14acf00db7 failed to run ["make" "KERNELVERSION=syzkaller" "KERNELRELEASE=syzkaller" "LOCALVERSION=-syzkaller" "-j" "32" "ARCH=x86_64" "CC=ccache clang" "LD=ld.lld" "O=/app/workdir/cache/build/b470468989f632692b04b8d0808e8e53e4e085c6" "-s" "bzImage" "compile_commands.json"]: exit status 2 Root cause: include/linux/thread_info.h:244:4: error: call to '__bad_copy_from' declared with 'error' attribute: copy source size is too small * * Restart config... * * * Mitigations for speculative execution vulnerabilities * Mitigations for speculative execution vulnerabilities (SPECULATION_MITIGATIONS) [Y/n/?] y Remove the kernel mapping in user mode (PAGE_TABLE_ISOLATION) [N/y/?] n Avoid speculative indirect branches in kernel (RETPOLINE) [N/y/?] n Enable IBPB on kernel entry (CPU_IBPB_ENTRY) [Y/n/?] y Enable IBRS on kernel entry (CPU_IBRS_ENTRY) [Y/n/?] y Mitigate Straight-Line-Speculation (SLS) [N/y/?] (NEW) Error in reading or end of file. * * General architecture-dependent options * Kprobes (KPROBES) [N/y/?] n Optimize very unlikely/likely branches (JUMP_LABEL) [Y/n/?] y Static key selftest (STATIC_KEYS_SELFTEST) [N/y/?] n Static call selftest (STATIC_CALL_SELFTEST) [N/y/?] n Enable seccomp to safely execute untrusted bytecode (SECCOMP) [Y/n/?] y Show seccomp filter cache status in /proc/pid/seccomp_cache (SECCOMP_CACHE_DEBUG) [N/y/?] n Link Time Optimization (LTO) > 1. None (LTO_NONE) choice[1]: 1 Use Clang's Control Flow Integrity (CFI) (CFI_CLANG) [N/y/?] (NEW) Error in reading or end of file. Number of bits to use for ASLR of mmap base address (ARCH_MMAP_RND_BITS) [28] 28 Number of bits to use for ASLR of mmap base address for compatible applications (ARCH_MMAP_RND_COMPAT_BITS) [8] 8 Provide system calls for 32-bit time_t (COMPAT_32BIT_TIME) [Y/n/?] y Use a virtually-mapped stack (VMAP_STACK) [Y/n/?] y Support for randomizing kernel stack offset on syscall entry (RANDOMIZE_KSTACK_OFFSET) [Y/n/?] y Default state of kernel stack offset randomization (RANDOMIZE_KSTACK_OFFSET_DEFAULT) [N/y/?] n Locking event counts collection (LOCK_EVENT_COUNTS) [N/y/?] n * * Memory initialization * Initialize kernel stack variables at function entry > 1. no automatic stack variable initialization (weakest) (INIT_STACK_NONE) 2. pattern-init everything (strongest) (INIT_STACK_ALL_PATTERN) (NEW) 3. zero-init everything (strongest and safest) (INIT_STACK_ALL_ZERO) (NEW) choice[1-3?]: Error in reading or end of file. Enable heap memory zeroing on allocation by default (INIT_ON_ALLOC_DEFAULT_ON) [Y/n/?] y Enable heap memory zeroing on free by default (INIT_ON_FREE_DEFAULT_ON) [N/y/?] n Enable register zeroing on function exit (ZERO_CALL_USED_REGS) [N/y/?] (NEW) Error in reading or end of file. * * Kernel hardening options * Randomize layout of sensitive kernel structures > 1. Disable structure layout randomization (RANDSTRUCT_NONE) 2. Fully randomize structure layout (RANDSTRUCT_FULL) (NEW) choice[1-2?]: Error in reading or end of file. * * Compile-time checks and compiler options * Debug information 1. Disable debug information (DEBUG_INFO_NONE) 2. Rely on the toolchain's implicit default DWARF version (DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT) > 3. Generate DWARF Version 4 debuginfo (DEBUG_INFO_DWARF4) 4. Generate DWARF Version 5 debuginfo (DEBUG_INFO_DWARF5) choice[1-4?]: 3 Reduce debugging information (DEBUG_INFO_REDUCED) [N/y/?] n Compressed Debug information > 1. Don't compress debug information (DEBUG_INFO_COMPRESSED_NONE) 2. Compress debugging information with zlib (DEBUG_INFO_COMPRESSED_ZLIB) 3. Compress debugging information with zstd (DEBUG_INFO_COMPRESSED_ZSTD) (NEW) choice[1-3?]: Error in reading or end of file. Produce split debuginfo in .dwo files (DEBUG_INFO_SPLIT) [N/y/?] n Generate BTF typeinfo (DEBUG_INFO_BTF) [N/y/?] n Provide GDB scripts for kernel debugging (GDB_SCRIPTS) [N/y/?] n Warn for stack frames larger than (FRAME_WARN) [2048] 2048 Strip assembler-generated symbols during link (STRIP_ASM_SYMS) [N/y/?] n Install uapi headers to usr/include (HEADERS_INSTALL) [N/y/?] n Make section mismatch errors no
Discussions (2)
Title Replies (including bot) Last reply
[PATCH 1/1] mm: fix a lockdep issue in vma_assert_write_locked 2 (2) 2023/07/12 20:00
[syzbot] [fs?] WARNING in handle_userfault 3 (5) 2023/07/12 19:59

Sample crash report:
kvm_intel: L1TF CPU bug present and SMT on, data leak possible. See CVE-2018-3646 and https://www.kernel.org/doc/html/latest/admin-guide/hw-vuln/l1tf.html for details.
------------[ cut here ]------------
WARNING: CPU: 0 PID: 5028 at include/linux/mmap_lock.h:71 mmap_assert_write_locked include/linux/mmap_lock.h:71 [inline]
WARNING: CPU: 0 PID: 5028 at include/linux/mmap_lock.h:71 __is_vma_write_locked include/linux/mm.h:712 [inline]
WARNING: CPU: 0 PID: 5028 at include/linux/mmap_lock.h:71 vma_assert_locked include/linux/mm.h:753 [inline]
WARNING: CPU: 0 PID: 5028 at include/linux/mmap_lock.h:71 assert_fault_locked include/linux/mm.h:786 [inline]
WARNING: CPU: 0 PID: 5028 at include/linux/mmap_lock.h:71 handle_userfault+0x149b/0x27a0 fs/userfaultfd.c:440
Modules linked in:
CPU: 0 PID: 5028 Comm: syz-executor359 Not tainted 6.4.0-next-20230705-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/27/2023
RIP: 0010:mmap_assert_write_locked include/linux/mmap_lock.h:71 [inline]
RIP: 0010:__is_vma_write_locked include/linux/mm.h:712 [inline]
RIP: 0010:vma_assert_locked include/linux/mm.h:753 [inline]
RIP: 0010:assert_fault_locked include/linux/mm.h:786 [inline]
RIP: 0010:handle_userfault+0x149b/0x27a0 fs/userfaultfd.c:440
Code: ff 49 8d bc 24 a0 01 00 00 31 f6 e8 2f b9 23 08 31 ff 41 89 c5 89 c6 e8 c3 a2 87 ff 45 85 ed 0f 85 83 ed ff ff e8 95 a6 87 ff <0f> 0b e9 77 ed ff ff e8 89 a6 87 ff 49 8d bc 24 a0 01 00 00 be ff
RSP: 0000:ffffc90003a4fb68 EFLAGS: 00010293
RAX: 0000000000000000 RBX: ffffc90003a4fd88 RCX: 0000000000000000
RDX: ffff8880133bbb80 RSI: ffffffff81fd6ddb RDI: 0000000000000005
RBP: 0000000000000200 R08: 0000000000000005 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000001 R12: ffff88807d8e4280
R13: 0000000000000000 R14: ffff888021cb9110 R15: ffff888021cb9100
FS:  000055555738f300(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000020b7d800 CR3: 0000000029d0e000 CR4: 00000000003526f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 do_anonymous_page mm/memory.c:4151 [inline]
 do_pte_missing mm/memory.c:3671 [inline]
 handle_pte_fault mm/memory.c:4949 [inline]
 __handle_mm_fault+0x35ff/0x3cc0 mm/memory.c:5089
 handle_mm_fault+0x3c2/0xa20 mm/memory.c:5254
 do_user_addr_fault+0x2ed/0x13a0 arch/x86/mm/fault.c:1365
 handle_page_fault arch/x86/mm/fault.c:1509 [inline]
 exc_page_fault+0x98/0x170 arch/x86/mm/fault.c:1565
 asm_exc_page_fault+0x26/0x30 arch/x86/include/asm/idtentry.h:570
RIP: 0033:0x7faa694e34d5
Code: 52 89 c2 01 f6 29 f2 83 fa 05 0f 87 0a 02 00 00 48 63 14 97 48 01 fa ff e2 0f 1f 40 00 4c 89 d2 66 c1 e9 03 83 c0 01 0f b7 c9 <48> 89 14 cd 00 d8 b7 20 83 f8 20 75 b6 48 8b 84 24 f0 00 00 00 f3
RSP: 002b:00007ffefcb0d8e0 EFLAGS: 00010202
RAX: 0000000000000001 RBX: 0000000000000000 RCX: 0000000000000000
RDX: 0000860000109120 RSI: 0000000000000000 RDI: 00007faa69564020
RBP: 0000000000000006 R08: 0000830000789120 R09: 00000000aaaaaaab
R10: 0000870000109120 R11: 00008f0000309120 R12: 00008b0000889120
R13: 0000000000000000 R14: 00008e0000309120 R15: 00007ffefcb0de40
 </TASK>

Crashes (71):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/07/05 13:15 linux-next e1f6a8eaf1c2 80298b6f .config strace log report syz C [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/12 16:05 linux-next 40b055fe7f27 979d5fe2 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/12 09:09 linux-next 40b055fe7f27 2f19aa4f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/12 05:25 linux-next 40b055fe7f27 2f19aa4f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/12 01:52 linux-next 8e4b7f2f3d60 2f19aa4f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/12 00:44 linux-next 8e4b7f2f3d60 2f19aa4f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/11 15:24 linux-next 8e4b7f2f3d60 f8780940 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/11 15:05 linux-next 8e4b7f2f3d60 f8780940 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/11 13:51 linux-next 8e4b7f2f3d60 f8780940 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/11 11:54 linux-next 8e4b7f2f3d60 f8780940 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 17:33 linux-next fe57d0d86f03 52ae002a .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 12:08 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 07:14 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 06:11 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 06:11 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 06:01 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 05:43 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 05:35 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 04:48 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 04:40 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 04:39 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 04:34 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 04:22 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 04:19 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 03:59 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 03:20 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/10 03:10 linux-next fe57d0d86f03 668cb1fa .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/06 01:39 linux-next e1f6a8eaf1c2 ba5dba36 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 11:08 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 11:01 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 10:47 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 10:40 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 10:35 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 10:15 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 10:12 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 09:49 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 09:47 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 09:39 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 09:37 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 09:12 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 08:48 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 08:36 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 08:30 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 08:17 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 07:37 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 07:36 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 07:35 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 07:26 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 06:50 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 06:48 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 05:59 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 05:50 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
2023/07/05 05:43 linux-next e1f6a8eaf1c2 80298b6f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root WARNING in handle_userfault
* Struck through repros no longer work on HEAD.