syzbot


KCSAN: data-race in read_pages / read_pages (4)

Status: upstream: reported on 2024/12/26 21:44
Subsystems: fs mm
[Documentation on labels]
Reported-by: syzbot+e1d2475cbd1f0c63692f@syzkaller.appspotmail.com
First crash: 17h15m, last: 17h15m
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [fs?] [mm?] KCSAN: data-race in read_pages / read_pages (4) 0 (1) 2024/12/26 21:44
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in read_pages / read_pages (2) fs mm 134 290d 385d 0/28 auto-obsoleted due to no activity on 2024/04/14 15:35
upstream KCSAN: data-race in read_pages / read_pages (3) fs mm 1 108d 108d 0/28 auto-obsoleted due to no activity on 2024/10/15 11:15
upstream KCSAN: data-race in read_pages / read_pages fs mm 1 915d 915d 0/28 auto-closed as invalid on 2022/07/30 19:54

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

read-write to 0xffff8881034df5e0 of 4 bytes by task 9479 on cpu 1:
 read_pages+0x23f/0x540 mm/readahead.c:170
 page_cache_ra_unbounded+0x2b8/0x310 mm/readahead.c:295
 do_page_cache_ra mm/readahead.c:325 [inline]
 page_cache_ra_order mm/readahead.c:524 [inline]
 page_cache_async_ra+0x40c/0x420 mm/readahead.c:674
 do_async_mmap_readahead mm/filemap.c:3231 [inline]
 filemap_fault+0x2d1/0xb30 mm/filemap.c:3330
 __do_fault+0xb6/0x200 mm/memory.c:4907
 do_read_fault mm/memory.c:5322 [inline]
 do_fault mm/memory.c:5456 [inline]
 do_pte_missing mm/memory.c:3979 [inline]
 handle_pte_fault mm/memory.c:5801 [inline]
 __handle_mm_fault mm/memory.c:5944 [inline]
 handle_mm_fault+0xe98/0x2ac0 mm/memory.c:6112
 faultin_page mm/gup.c:1196 [inline]
 __get_user_pages+0xf2c/0x2670 mm/gup.c:1494
 populate_vma_page_range mm/gup.c:1932 [inline]
 __mm_populate+0x25b/0x3b0 mm/gup.c:2035
 do_mlock+0x415/0x510 mm/mlock.c:653
 __do_sys_mlock mm/mlock.c:661 [inline]
 __se_sys_mlock mm/mlock.c:659 [inline]
 __x64_sys_mlock+0x36/0x40 mm/mlock.c:659
 x64_sys_call+0x26b2/0x2dc0 arch/x86/include/generated/asm/syscalls_64.h:150
 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-write to 0xffff8881034df5e0 of 4 bytes by task 9477 on cpu 0:
 read_pages+0x23f/0x540 mm/readahead.c:170
 page_cache_ra_unbounded+0x266/0x310
 do_page_cache_ra mm/readahead.c:325 [inline]
 page_cache_ra_order+0xf7/0x110 mm/readahead.c:524
 do_sync_mmap_readahead+0x267/0x2a0 mm/filemap.c:3203
 filemap_fault+0x32f/0xb30 mm/filemap.c:3344
 __do_fault+0xb6/0x200 mm/memory.c:4907
 do_read_fault mm/memory.c:5322 [inline]
 do_fault mm/memory.c:5456 [inline]
 do_pte_missing mm/memory.c:3979 [inline]
 handle_pte_fault mm/memory.c:5801 [inline]
 __handle_mm_fault mm/memory.c:5944 [inline]
 handle_mm_fault+0xe98/0x2ac0 mm/memory.c:6112
 faultin_page mm/gup.c:1196 [inline]
 __get_user_pages+0xf2c/0x2670 mm/gup.c:1494
 populate_vma_page_range mm/gup.c:1932 [inline]
 __mm_populate+0x25b/0x3b0 mm/gup.c:2035
 mm_populate include/linux/mm.h:3396 [inline]
 vm_mmap_pgoff+0x1d6/0x290 mm/util.c:585
 ksys_mmap_pgoff+0x286/0x330 mm/mmap.c:542
 x64_sys_call+0x1940/0x2dc0 arch/x86/include/generated/asm/syscalls_64.h:10
 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

value changed: 0x0000001f -> 0x0000001c

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 UID: 0 PID: 9477 Comm: syz.5.1573 Tainted: G        W          6.13.0-rc4-syzkaller-00012-g9b2ffa6148b1 #0
Tainted: [W]=WARN
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/12/26 20:56 upstream 9b2ffa6148b1 d3ccff63 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in read_pages / read_pages
* Struck through repros no longer work on HEAD.