syzbot


KCSAN: data-race in xas_create / xas_find_marked (3)

Status: auto-closed as invalid on 2022/06/19 06:15
Subsystems: fs mm
[Documentation on labels]
First crash: 745d, last: 745d
Similar bugs (5)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in xas_create / xas_find_marked (4) fs mm 2 570d 574d 0/26 auto-obsoleted due to no activity on 2022/12/10 21:02
upstream KCSAN: data-race in xas_create / xas_find_marked (6) mm fs 3 115d 151d 0/26 auto-obsoleted due to no activity on 2024/03/09 19:07
upstream KCSAN: data-race in xas_create / xas_find_marked (2) fs mm 1 946d 946d 0/26 auto-closed as invalid on 2021/11/29 22:24
upstream KCSAN: data-race in xas_create / xas_find_marked (5) fs mm 3 227d 263d 0/26 auto-obsoleted due to no activity on 2023/11/18 23:30
upstream KCSAN: data-race in xas_create / xas_find_marked fs mm 1 1034d 1034d 0/26 auto-closed as invalid on 2021/09/03 00:06

Sample crash report:
loop0: detected capacity change from 0 to 4096
EXT4-fs (loop0): unsupported descriptor size 0
==================================================================
BUG: KCSAN: data-race in xas_create / xas_find_marked

write to 0xffff888136eba6c1 of 1 bytes by task 2444 on cpu 0:
 xas_expand lib/xarray.c:613 [inline]
 xas_create+0x68a/0xb20 lib/xarray.c:654
 xas_store+0x71/0xc90 lib/xarray.c:788
 __filemap_add_folio+0x271/0x7f0 mm/filemap.c:900
 filemap_add_folio+0x6b/0x150 mm/filemap.c:959
 page_cache_ra_unbounded+0x19e/0x2e0 mm/readahead.c:243
 do_page_cache_ra mm/readahead.c:291 [inline]
 force_page_cache_ra+0x1c6/0x200 mm/readahead.c:322
 page_cache_sync_ra+0x190/0x1b0 mm/readahead.c:691
 page_cache_sync_readahead include/linux/pagemap.h:1185 [inline]
 filemap_get_pages mm/filemap.c:2592 [inline]
 filemap_read+0x3e5/0x1400 mm/filemap.c:2679
 blkdev_read_iter+0x2c6/0x370 block/fops.c:611
 call_read_iter include/linux/fs.h:2044 [inline]
 new_sync_read fs/read_write.c:401 [inline]
 vfs_read+0x5a5/0x6a0 fs/read_write.c:482
 ksys_read+0xe8/0x1a0 fs/read_write.c:620
 __do_sys_read fs/read_write.c:630 [inline]
 __se_sys_read fs/read_write.c:628 [inline]
 __x64_sys_read+0x3e/0x50 fs/read_write.c:628
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x2b/0x70 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae

read to 0xffff888136eba6c1 of 1 bytes by task 15355 on cpu 1:
 xas_find_marked+0x3af/0x5e0 lib/xarray.c:1339
 find_get_entry mm/filemap.c:2032 [inline]
 find_get_pages_range_tag+0x103/0x480 mm/filemap.c:2314
 pagevec_lookup_range_tag+0x37/0x50 mm/swap.c:1122
 __filemap_fdatawait_range+0xba/0x260 mm/filemap.c:516
 filemap_fdatawait_range mm/filemap.c:551 [inline]
 filemap_write_and_wait_range+0x14d/0x2e0 mm/filemap.c:682
 filemap_write_and_wait include/linux/pagemap.h:60 [inline]
 sync_blockdev+0x3e/0x50 block/bdev.c:199
 kill_block_super+0x52/0x90 fs/super.c:1395
 deactivate_locked_super+0x6a/0xb0 fs/super.c:332
 get_tree_bdev+0x2d0/0x3b0 fs/super.c:1294
 vfs_get_tree+0x49/0x190 fs/super.c:1497
 do_new_mount+0x200/0x650 fs/namespace.c:3040
 path_mount+0x4b1/0xb60 fs/namespace.c:3370
 do_mount fs/namespace.c:3383 [inline]
 __do_sys_mount fs/namespace.c:3591 [inline]
 __se_sys_mount+0x281/0x2d0 fs/namespace.c:3568
 __x64_sys_mount+0x63/0x70 fs/namespace.c:3568
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x2b/0x70 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae

value changed: 0x23 -> 0x00

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 15355 Comm: syz-executor.0 Not tainted 5.18.0-rc6-syzkaller-00153-g2fe1020d73ca-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/05/15 06:09 upstream 2fe1020d73ca 744a39e2 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in xas_create / xas_find_marked
* Struck through repros no longer work on HEAD.