syzbot


KCSAN: data-race in xas_clear_mark / xas_find_marked (2)

Status: moderation: reported on 2019/12/10 21:55
Reported-by: syzbot+6b653cb0a28eee8c400a@syzkaller.appspotmail.com
First crash: 1071d, last: 13h30m
similar bugs (1):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in xas_clear_mark / xas_find_marked 3 1076d 1082d 0/24 closed as invalid on 2019/10/18 14:11

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

read-write to 0xffff88810a6cf478 of 8 bytes by task 4058 on cpu 0:
 instrument_read_write include/linux/instrumented.h:57 [inline]
 __instrument_read_write_bitop include/asm-generic/bitops/instrumented-non-atomic.h:84 [inline]
 ___test_and_clear_bit include/asm-generic/bitops/instrumented-non-atomic.h:114 [inline]
 node_clear_mark lib/xarray.c:100 [inline]
 xas_clear_mark+0x8f/0x170 lib/xarray.c:916
 __folio_start_writeback+0x3e1/0x5d0 mm/page-writeback.c:2998
 set_page_writeback+0x3d/0xe0 mm/folio-compat.c:56
 ext4_bio_write_page+0x119/0xb60 fs/ext4/page-io.c:451
 mpage_submit_page fs/ext4/inode.c:2114 [inline]
 mpage_map_and_submit_buffers fs/ext4/inode.c:2359 [inline]
 mpage_map_and_submit_extent fs/ext4/inode.c:2498 [inline]
 ext4_writepages+0x1020/0x1cf0 fs/ext4/inode.c:2827
 do_writepages+0x1db/0x350 mm/page-writeback.c:2468
 filemap_fdatawrite_wbc+0xd6/0xf0 mm/filemap.c:388
 __filemap_fdatawrite_range mm/filemap.c:421 [inline]
 file_write_and_wait_range+0xd6/0x170 mm/filemap.c:773
 ext4_sync_file+0x105/0x6d0 fs/ext4/fsync.c:151
 vfs_fsync_range+0x107/0x120 fs/sync.c:188
 generic_write_sync include/linux/fs.h:2869 [inline]
 ext4_buffered_write_iter+0x398/0x3e0 fs/ext4/file.c:277
 ext4_file_write_iter+0x2e3/0x1210
 call_write_iter include/linux/fs.h:2187 [inline]
 new_sync_write fs/read_write.c:491 [inline]
 vfs_write+0x468/0x760 fs/read_write.c:578
 ksys_write+0xe8/0x1a0 fs/read_write.c:631
 __do_sys_write fs/read_write.c:643 [inline]
 __se_sys_write fs/read_write.c:640 [inline]
 __x64_sys_write+0x3e/0x50 fs/read_write.c:640
 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+0x63/0xcd

read to 0xffff88810a6cf478 of 8 bytes by task 4070 on cpu 1:
 xas_find_chunk include/linux/xarray.h:1704 [inline]
 xas_find_marked+0x22f/0x6a0 lib/xarray.c:1356
 find_get_entry mm/filemap.c:2010 [inline]
 find_get_pages_range_tag+0x103/0x4f0 mm/filemap.c:2284
 pagevec_lookup_range_tag+0x37/0x50 mm/swap.c:1062
 mpage_prepare_extent_to_map+0x1a4/0xa50 fs/ext4/inode.c:2588
 ext4_writepages+0x6b2/0x1cf0 fs/ext4/inode.c:2781
 do_writepages+0x1db/0x350 mm/page-writeback.c:2468
 filemap_fdatawrite_wbc+0xd6/0xf0 mm/filemap.c:388
 __filemap_fdatawrite_range mm/filemap.c:421 [inline]
 filemap_write_and_wait_range+0xc2/0x1d0 mm/filemap.c:673
 filemap_write_and_wait include/linux/pagemap.h:60 [inline]
 ext4_ioctl_setflags fs/ext4/ioctl.c:635 [inline]
 ext4_fileattr_set+0x581/0xde0 fs/ext4/ioctl.c:1001
 vfs_fileattr_set+0x56b/0x5d0 fs/ioctl.c:696
 do_vfs_ioctl+0x1010/0x1390
 __do_sys_ioctl fs/ioctl.c:868 [inline]
 __se_sys_ioctl+0x83/0x140 fs/ioctl.c:856
 __x64_sys_ioctl+0x3f/0x50 fs/ioctl.c:856
 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+0x63/0xcd

value changed: 0xffffffffffffffff -> 0xfffffffffffffffc

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 4070 Comm: syz-executor.4 Not tainted 6.0.0-rc7-syzkaller-00029-g3800a713b607-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/26/2022
==================================================================

Crashes (2109):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2022/09/27 05:15 upstream 3800a713b607 10323ddf .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/26 08:17 upstream f76349cf4145 d59ba983 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/25 22:58 upstream 5e049663f678 0042f2b4 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/25 04:24 upstream 1a61b828566f 0042f2b4 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/24 11:47 upstream a63f2e7cb110 0042f2b4 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/23 14:45 upstream bf682942cd26 0042f2b4 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/22 15:40 upstream dc164f4fb00a 0042f2b4 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/22 11:53 upstream dc164f4fb00a 60af5050 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/21 22:16 upstream 06f7db949993 60af5050 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/21 17:13 upstream 06f7db949993 380f82fb .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/21 10:31 upstream 60891ec99e14 380f82fb .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/20 19:17 upstream 60891ec99e14 c4b8ccfd .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/20 07:35 upstream 521a547ced64 7c41a9ba .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/19 11:56 upstream 521a547ced64 dd9a85ff .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/19 07:36 upstream 521a547ced64 dd9a85ff .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/18 17:49 upstream 38eddeedbbea dd9a85ff .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/17 05:48 upstream a335366bad13 dd9a85ff .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/16 16:23 upstream 6879c2d3b960 dd9a85ff .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/15 07:19 upstream 3245cb65fd91 dd9a85ff .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/14 10:16 upstream 3245cb65fd91 b884348d .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/13 19:56 upstream d1221cea11fc b884348d .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/13 13:44 upstream d1221cea11fc a08652b0 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/13 08:35 upstream e839a756012b a08652b0 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/12 23:55 upstream e839a756012b f371ed7e .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/12 16:48 upstream 80e78fcce86d f371ed7e .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/12 10:00 upstream 80e78fcce86d 356d8217 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/11 20:28 upstream 4ed9c1e971b1 356d8217 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/10 19:16 upstream b96fbd602d35 356d8217 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/09 23:43 upstream ce888220d5c7 356d8217 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/09 12:42 upstream 9b4509495418 90058bdc .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/09 03:27 upstream 506357871c18 f3027468 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/08 13:32 upstream 26b1224903b3 f3027468 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/08 11:17 upstream 0066f1b0e275 f3027468 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/07 23:25 upstream 0066f1b0e275 435aeef7 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/07 12:05 upstream 0066f1b0e275 c5b7bc57 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/06 20:23 upstream d2ec799d1c1b 65aea2b9 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/06 11:08 upstream 53e99dcff61e 65aea2b9 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/05 23:16 upstream 53e99dcff61e 9dcd38fc .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/05 10:01 upstream 7e18e42e4b28 922294ab .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/04 20:47 upstream 7e18e42e4b28 28811d0a .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/04 07:29 upstream 7726d4c3e60b 28811d0a .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/03 18:29 upstream 42cf58c272ee 28811d0a .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/03 15:48 upstream d895ec7938c4 28811d0a .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/03 03:21 upstream d895ec7938c4 49e94a20 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/02 19:17 upstream 0b3acd1cc022 25194605 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/02 14:40 upstream 42e66b1cc3a0 25194605 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/02 03:49 upstream 42e66b1cc3a0 a805568e .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/01 17:32 upstream 2880e1a175b9 86c46e46 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/09/01 15:00 upstream c5e4d5e99162 86c46e46 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2022/08/31 18:19 upstream c5e4d5e99162 51e54e30 .config log report info KCSAN: data-race in xas_clear_mark / xas_find_marked
ci2-upstream-kcsan-gce 2021/01/17 10:22 upstream 0da0a8a0a0e1 813be542 .config log report info
ci2-upstream-kcsan-gce 2019/10/22 14:09 https://github.com/google/ktsan.git kcsan 05f2236801fe 4ee855e7 .config log report
* Struck through repros no longer work on HEAD.