syzbot


KCSAN: data-race in getrusage / vms_clear_ptes

Status: moderation: reported on 2024/09/23 03:32
Subsystems: mm
[Documentation on labels]
Reported-by: syzbot+31cd52ba68feee156393@syzkaller.appspotmail.com
First crash: 22d, last: 22h30m

Sample crash report:
==================================================================
BUG: KCSAN: data-race in getrusage / vms_clear_ptes

write to 0xffff88810458b568 of 8 bytes by task 18347 on cpu 1:
 update_hiwater_rss include/linux/mm.h:2655 [inline]
 vms_clear_ptes+0x1a7/0x300 mm/vma.c:1088
 vms_complete_munmap_vmas+0x170/0x480 mm/vma.c:1140
 do_vmi_align_munmap+0x349/0x390 mm/vma.c:1349
 do_vmi_munmap+0x1eb/0x230 mm/vma.c:1397
 __vm_munmap+0xfd/0x220 mm/mmap.c:1600
 __do_sys_munmap mm/mmap.c:1617 [inline]
 __se_sys_munmap mm/mmap.c:1614 [inline]
 __x64_sys_munmap+0x36/0x40 mm/mmap.c:1614
 x64_sys_call+0xd32/0x2d60 arch/x86/include/generated/asm/syscalls_64.h:12
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xc9/0x1c0 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

read to 0xffff88810458b568 of 8 bytes by task 18348 on cpu 0:
 get_mm_hiwater_rss include/linux/mm.h:2642 [inline]
 setmax_mm_hiwater_rss include/linux/mm.h:2672 [inline]
 getrusage+0xa35/0xb90 kernel/sys.c:1870
 io_sq_thread+0x539/0x1000 io_uring/sqpoll.c:313
 ret_from_fork+0x4b/0x60 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244

value changed: 0x0000000000000fc1 -> 0x00000000000010a1

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 UID: 0 PID: 18348 Comm: iou-sqp-18347 Tainted: G        W          6.12.0-rc3-syzkaller-00007-g6485cf5ea253 #0
Tainted: [W]=WARN
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
==================================================================

Crashes (5):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/10/14 14:18 upstream 6485cf5ea253 084d8178 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in getrusage / vms_clear_ptes
2024/10/14 14:17 upstream 6485cf5ea253 084d8178 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in getrusage / vms_clear_ptes
2024/10/09 22:17 upstream 75b607fab38d 56fb2cb7 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in getrusage / vms_clear_ptes
2024/09/28 04:18 upstream 3630400697a3 440b26ec .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in getrusage / vms_clear_ptes
2024/09/23 03:31 upstream af9c191ac2a0 6f888b75 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in getrusage / vms_clear_ptes
* Struck through repros no longer work on HEAD.