syzbot


KCSAN: data-race in __xa_set_mark / xas_find_marked

Status: moderation: reported on 2020/09/25 08:57
Subsystems: fs mm
[Documentation on labels]
Reported-by: syzbot+f512479ce46e8f0a9370@syzkaller.appspotmail.com
First crash: 1837d, last: 5d12h

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

read-write to 0xffff8881071c4228 of 8 bytes by task 3295 on cpu 0:
 instrument_read_write include/linux/instrumented.h:55 [inline]
 __instrument_read_write_bitop include/asm-generic/bitops/instrumented-non-atomic.h:84 [inline]
 ___test_and_set_bit include/asm-generic/bitops/instrumented-non-atomic.h:99 [inline]
 node_set_mark lib/xarray.c:95 [inline]
 xas_set_mark lib/xarray.c:893 [inline]
 __xa_set_mark+0xd2/0x1a0 lib/xarray.c:2079
 __folio_mark_dirty+0x3af/0x4d0 mm/page-writeback.c:2744
 mark_buffer_dirty+0x11e/0x210 fs/buffer.c:1212
 block_commit_write fs/buffer.c:2224 [inline]
 block_page_mkwrite+0x287/0x3d0 fs/buffer.c:2650
 ext4_page_mkwrite+0x76b/0xba0 fs/ext4/inode.c:6598
 do_page_mkwrite mm/memory.c:3378 [inline]
 wp_page_shared mm/memory.c:3779 [inline]
 do_wp_page+0xe5d/0x2400 mm/memory.c:3998
 handle_pte_fault mm/memory.c:6085 [inline]
 __handle_mm_fault mm/memory.c:6212 [inline]
 handle_mm_fault+0x77d/0x2be0 mm/memory.c:6381
 do_user_addr_fault+0x636/0x1090 arch/x86/mm/fault.c:1336
 handle_page_fault arch/x86/mm/fault.c:1476 [inline]
 exc_page_fault+0x62/0xa0 arch/x86/mm/fault.c:1532
 asm_exc_page_fault+0x26/0x30 arch/x86/include/asm/idtentry.h:623

read to 0xffff8881071c4228 of 8 bytes by task 7700 on cpu 1:
 xas_find_chunk include/linux/xarray.h:1752 [inline]
 xas_find_marked+0x218/0x620 lib/xarray.c:1510
 find_get_entry+0x5d/0x380 mm/filemap.c:2038
 filemap_get_folios_tag+0x92/0x210 mm/filemap.c:2306
 mpage_prepare_extent_to_map+0x320/0xaa0 fs/ext4/inode.c:2577
 ext4_do_writepages+0x6ea/0x21c0 fs/ext4/inode.c:2816
 ext4_writepages+0x176/0x300 fs/ext4/inode.c:2953
 do_writepages+0x1c6/0x310 mm/page-writeback.c:2636
 __writeback_single_inode+0x80/0x7c0 fs/fs-writeback.c:1680
 writeback_sb_inodes+0x480/0xa20 fs/fs-writeback.c:1976
 __writeback_inodes_wb+0x94/0x1a0 fs/fs-writeback.c:2047
 wb_writeback+0x266/0x5c0 fs/fs-writeback.c:2158
 wb_check_old_data_flush fs/fs-writeback.c:2262 [inline]
 wb_do_writeback fs/fs-writeback.c:2315 [inline]
 wb_workfn+0x601/0x910 fs/fs-writeback.c:2343
 process_one_work kernel/workqueue.c:3238 [inline]
 process_scheduled_works+0x4ce/0x9d0 kernel/workqueue.c:3321
 worker_thread+0x582/0x770 kernel/workqueue.c:3402
 kthread+0x486/0x510 kernel/kthread.c:464
 ret_from_fork+0xda/0x150 arch/x86/kernel/process.c:148
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245

value changed: 0x0060000000000000 -> 0x0060000010000200

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 UID: 0 PID: 7700 Comm: kworker/u8:33 Not tainted 6.16.0-rc3-syzkaller-00190-g67a993863163 #0 PREEMPT(voluntary) 
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025
Workqueue: writeback wb_workfn (flush-8:0)
==================================================================

Crashes (1526):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/06/27 22:32 upstream 67a993863163 fc9d8ee5 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/06/26 23:12 upstream ee88bddf7f2f 803ce19b .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/06/20 08:00 upstream 75f5f23f8787 ed3e87f7 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/06/09 09:18 upstream 19272b37aa4f 4826c28e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/05/28 17:16 upstream 3d413f0cfd7e 3d2f584d .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/05/16 19:48 upstream 3c21441eeffc cfde8269 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/05/13 17:43 upstream e9565e23cd89 7344edeb .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/05/11 07:28 upstream 3ce9925823c7 77908e5f .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/05/07 15:34 upstream 707df3375124 350f4ffc .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/05/05 13:27 upstream 92a09c47464d 6ca47dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/04/28 20:36 upstream f15d97df5afa aeb6ec69 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/04/28 17:44 upstream f15d97df5afa c6b4fb39 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/04/24 07:22 upstream a79be02bba5c 9882047a .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/04/23 18:01 upstream bc3372351d0c 73a168d0 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/04/22 03:51 upstream a33b5a08cbbd 2a20f901 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/04/19 16:21 upstream 8560697b23dc 2a20f901 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/04/12 17:12 upstream 3bde70a2c827 0bd6db41 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/04/07 16:50 upstream 0af2f6be1b42 a2ada0e7 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/04/06 10:15 upstream f4d2ef48250a 1c65791e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/04/05 19:08 upstream a8662bcd2ff1 c53ea9c9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/04/02 05:04 upstream acc4d5ff0b61 b8645499 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/28 22:41 upstream 15cb9a2b66fc 9a1a9e31 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/26 04:30 upstream 2df0c02dab82 89d30d73 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/25 18:45 upstream 2df0c02dab82 875573af .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/22 10:55 upstream 88d324e69ea9 c6512ef7 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/19 04:16 upstream 81e4f8d68c66 8d0a2921 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/14 04:14 upstream 4003c9e78778 e2826670 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/11 21:37 upstream 0b46b049d6ec 16256247 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/10 23:41 upstream 4d872d51bc9d 16256247 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/08 03:45 upstream 21e4543a2e2f 7e3bd60d .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/07 01:44 upstream 0f52fd4f67c6 831e3629 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/05 18:33 upstream bb2281fb05e5 60f5d8d9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/03/04 23:16 upstream 48a5eed9ad58 c3901742 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/02/28 02:25 upstream 1e15510b71c9 6a8fcbc4 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/02/22 02:58 upstream 8a61cb6e150e d34966d1 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/02/17 09:48 upstream 0ad2507d5d93 4121cf9d .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/02/15 21:39 upstream 496659003dac 40a34ec9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/02/15 13:32 upstream 78a632a2086c 40a34ec9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/02/11 15:26 upstream febbc555cf0f f2baddf5 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/02/08 12:40 upstream 8f6629c004b1 ef44b750 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/02/05 18:06 upstream 5c8c229261f1 4dc70884 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/02/05 10:56 upstream 5c8c229261f1 5896748e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/02/04 19:56 upstream d009de7d5428 8f267cef .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/02/03 11:54 upstream 2014c95afece a21a8419 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/01/31 05:42 upstream 69e858e0b8b2 4c6ac32f .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/01/29 02:38 upstream 05dbaf8dd8bf 865ef71e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2025/01/28 12:56 upstream 6d61a53dd6f5 f5427d7c .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __xa_set_mark / xas_find_marked
2021/01/17 11:08 upstream 0da0a8a0a0e1 813be542 .config console log report info ci2-upstream-kcsan-gce
2020/09/24 17:40 upstream 171d4ff79f96 54289b08 .config console log report info ci2-upstream-kcsan-gce
2020/06/21 17:45 upstream 64677779e896 4f2acff9 .config console log report ci2-upstream-kcsan-gce
* Struck through repros no longer work on HEAD.