syzbot


KCSAN: data-race in do_sync_mmap_readahead / read_pages (2)

Status: auto-obsoleted due to no activity on 2023/12/26 00:01
Subsystems: mm
[Documentation on labels]
Reported-by: syzbot+d0025f336f56c1feee91@syzkaller.appspotmail.com
First crash: 491d, last: 491d
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in do_sync_mmap_readahead / read_pages mm fs 12 553d 628d 0/28 auto-obsoleted due to no activity on 2023/10/23 18:22
upstream KCSAN: data-race in do_sync_mmap_readahead / read_pages (3) mm 1 88d 88d 0/28 auto-obsoleted due to no activity on 2025/02/20 20:58

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

write to 0xffff88818bb2e880 of 4 bytes by task 21926 on cpu 0:
 do_sync_mmap_readahead+0x3de/0x450 mm/filemap.c:3138
 filemap_fault+0x426/0xc30 mm/filemap.c:3233
 __do_fault mm/memory.c:4265 [inline]
 do_read_fault mm/memory.c:4628 [inline]
 do_fault mm/memory.c:4762 [inline]
 do_pte_missing mm/memory.c:3730 [inline]
 handle_pte_fault mm/memory.c:5038 [inline]
 __handle_mm_fault mm/memory.c:5179 [inline]
 handle_mm_fault+0x13bd/0x2dd0 mm/memory.c:5344
 faultin_page mm/gup.c:956 [inline]
 __get_user_pages+0x402/0xe40 mm/gup.c:1239
 populate_vma_page_range mm/gup.c:1677 [inline]
 __mm_populate+0x216/0x330 mm/gup.c:1786
 mm_populate include/linux/mm.h:3379 [inline]
 vm_mmap_pgoff+0x1a7/0x240 mm/util.c:561
 ksys_mmap_pgoff+0x2b8/0x330 mm/mmap.c:1425
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x44/0x110 arch/x86/entry/common.c:82
 entry_SYSCALL_64_after_hwframe+0x63/0x6b

read-write to 0xffff88818bb2e880 of 4 bytes by task 21938 on cpu 1:
 read_pages+0x23c/0x530 mm/readahead.c:170
 page_cache_ra_unbounded+0x2aa/0x2e0 mm/readahead.c:269
 do_page_cache_ra mm/readahead.c:299 [inline]
 page_cache_ra_order mm/readahead.c:546 [inline]
 ondemand_readahead+0x524/0x690 mm/readahead.c:668
 page_cache_async_ra+0x94/0xa0 mm/readahead.c:717
 do_async_mmap_readahead mm/filemap.c:3169 [inline]
 filemap_fault+0x3da/0xc30 mm/filemap.c:3223
 __do_fault mm/memory.c:4265 [inline]
 do_read_fault mm/memory.c:4628 [inline]
 do_fault mm/memory.c:4762 [inline]
 do_pte_missing mm/memory.c:3730 [inline]
 handle_pte_fault mm/memory.c:5038 [inline]
 __handle_mm_fault mm/memory.c:5179 [inline]
 handle_mm_fault+0x13bd/0x2dd0 mm/memory.c:5344
 faultin_page mm/gup.c:956 [inline]
 __get_user_pages+0x402/0xe40 mm/gup.c:1239
 populate_vma_page_range mm/gup.c:1677 [inline]
 __mm_populate+0x216/0x330 mm/gup.c:1786
 mm_populate include/linux/mm.h:3379 [inline]
 vm_mmap_pgoff+0x1a7/0x240 mm/util.c:561
 ksys_mmap_pgoff+0x2b8/0x330 mm/mmap.c:1425
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x44/0x110 arch/x86/entry/common.c:82
 entry_SYSCALL_64_after_hwframe+0x63/0x6b

value changed: 0x0000000b -> 0x0000001f

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 21938 Comm: syz-executor.3 Not tainted 6.7.0-rc1-syzkaller-00344-g037266a5f723 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/10/2023
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/11/19 11:29 upstream 037266a5f723 cb976f63 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in do_sync_mmap_readahead / read_pages
* Struck through repros no longer work on HEAD.