syzbot


KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark

Status: moderation: reported on 2022/05/10 00:10
Reported-by: syzbot+b97e9f65a69e70c39b6f@syzkaller.appspotmail.com
First crash: 301d, last: 1d06h

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

write to 0xffff88810aa6589c of 4 bytes by task 6316 on cpu 1:
 xa_mark_set lib/xarray.c:69 [inline]
 xas_set_mark+0x11e/0x130 lib/xarray.c:894
 tag_pages_for_writeback+0x9d/0x290 mm/page-writeback.c:2350
 write_cache_pages+0x18c/0xa30 mm/page-writeback.c:2420
 mpage_writepages+0x6e/0xe0 fs/mpage.c:664
 fat_writepages+0x20/0x30 fs/fat/inode.c:200
 do_writepages+0x1db/0x350 mm/page-writeback.c:2581
 filemap_fdatawrite_wbc+0xd6/0xf0 mm/filemap.c:388
 __filemap_fdatawrite_range mm/filemap.c:421 [inline]
 file_write_and_wait_range+0xf2/0x190 mm/filemap.c:777
 __generic_file_fsync+0x48/0x140 fs/libfs.c:1132
 fat_file_fsync+0x48/0x100 fs/fat/file.c:191
 vfs_fsync_range+0x107/0x120 fs/sync.c:188
 generic_write_sync include/linux/fs.h:2885 [inline]
 generic_file_write_iter+0x18d/0x1c0 mm/filemap.c:3936
 do_iter_write+0x494/0x750 fs/read_write.c:861
 vfs_iter_write+0x4c/0x70 fs/read_write.c:902
 iter_file_splice_write+0x44a/0x7c0 fs/splice.c:686
 do_splice_from fs/splice.c:764 [inline]
 direct_splice_actor+0x80/0xa0 fs/splice.c:931
 splice_direct_to_actor+0x305/0x620 fs/splice.c:886
 do_splice_direct+0xfb/0x180 fs/splice.c:974
 do_sendfile+0x3bf/0x910 fs/read_write.c:1255
 __do_sys_sendfile64 fs/read_write.c:1323 [inline]
 __se_sys_sendfile64 fs/read_write.c:1309 [inline]
 __x64_sys_sendfile64+0x10c/0x150 fs/read_write.c:1309
 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 0xffff88810aa6589c of 4 bytes by task 6336 on cpu 0:
 xa_marked include/linux/xarray.h:420 [inline]
 mapping_tagged include/linux/fs.h:461 [inline]
 filemap_fdatawrite_wbc+0x57/0xf0 mm/filemap.c:384
 __filemap_fdatawrite_range mm/filemap.c:421 [inline]
 file_write_and_wait_range+0xf2/0x190 mm/filemap.c:777
 __generic_file_fsync+0x48/0x140 fs/libfs.c:1132
 fat_file_fsync+0x48/0x100 fs/fat/file.c:191
 vfs_fsync_range+0x107/0x120 fs/sync.c:188
 generic_write_sync include/linux/fs.h:2885 [inline]
 generic_file_write_iter+0x18d/0x1c0 mm/filemap.c:3936
 do_iter_write+0x494/0x750 fs/read_write.c:861
 vfs_iter_write+0x4c/0x70 fs/read_write.c:902
 iter_file_splice_write+0x44a/0x7c0 fs/splice.c:686
 do_splice_from fs/splice.c:764 [inline]
 direct_splice_actor+0x80/0xa0 fs/splice.c:931
 splice_direct_to_actor+0x305/0x620 fs/splice.c:886
 do_splice_direct+0xfb/0x180 fs/splice.c:974
 do_sendfile+0x3bf/0x910 fs/read_write.c:1255
 __do_sys_sendfile64 fs/read_write.c:1323 [inline]
 __se_sys_sendfile64 fs/read_write.c:1309 [inline]
 __x64_sys_sendfile64+0x10c/0x150 fs/read_write.c:1309
 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: 0x08000021 -> 0x10000021

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 6336 Comm: syz-executor.4 Not tainted 6.2.0-rc6-syzkaller-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/12/2023
==================================================================

Crashes (311):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets Title
ci2-upstream-kcsan-gce 2023/01/31 10:43 upstream 6d796c50f84c b68fb8d6 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/29 20:47 upstream ab072681eabe 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/29 08:02 upstream c96618275234 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/28 12:49 upstream 5af6ce704936 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/27 21:44 upstream 83abd4d4c4be 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/26 10:00 upstream 7c46948a6e9c 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/25 09:57 upstream fb6e71db53f3 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/23 16:56 upstream 2475bf0250de 9dfcf09c .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/23 10:15 upstream 2475bf0250de 44388686 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/22 23:17 upstream 2475bf0250de cc0f9968 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/22 09:56 upstream 2241ab53cbb5 cc0f9968 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/21 17:35 upstream f883675bf652 cc0f9968 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/21 03:42 upstream edc00350d205 cc0f9968 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/19 12:36 upstream 7287904c8771 66fca3ae .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/18 21:38 upstream c1649ec55708 4620c2d9 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/17 00:09 upstream d532dd102151 a63719e7 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/14 13:05 upstream 97ec4d559d93 a63719e7 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/14 10:01 upstream 97ec4d559d93 529798b0 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/13 17:26 upstream d9fc1511728c 529798b0 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/12 10:15 upstream e8f60cd7db24 96166539 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/11 22:12 upstream 7dd4b804e080 96166539 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/10 08:09 upstream 5a41237ad1d4 48bc529a .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/09 19:05 upstream 1fe4fd6f5cad 1dac8c7a .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/06 21:56 upstream 1f5abbd77e2c 1dac8c7a .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/06 00:40 upstream 41c03ba9beea 1dac8c7a .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/05 06:15 upstream 512dee0c00ad 1dac8c7a .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/03 14:42 upstream 69b41ac87e4a f0036e18 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/03 01:53 upstream 69b41ac87e4a ab32d508 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2023/01/01 12:14 upstream e4cf7c25bae5 ab32d508 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/31 17:57 upstream c8451c141e07 ab32d508 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/31 07:11 upstream bff687b3dad6 ab32d508 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/30 06:28 upstream 2258c2dc850b 44712fbc .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/27 16:52 upstream 1b929c02afd3 44712fbc .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/26 13:36 upstream 1b929c02afd3 9da18ae8 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/24 21:32 upstream 72a85e2b0a1e 9da18ae8 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/23 22:11 upstream 51094a24b85e 9da18ae8 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/22 15:13 upstream 0a924817d2ed 9da18ae8 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/21 14:26 upstream b6bb9676f216 4067838e .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/20 18:54 upstream 6feb57c2fd7c d3e76707 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/20 10:00 upstream aeba12b26c79 c52b2efb .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/18 06:44 upstream f9ff5644bcc0 05494336 .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/12/15 14:29 upstream 041fae9c105a 6f9c033e .config console log report info [disk image] [vmlinux] [kernel image] KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/05/09 16:32 upstream 9be9ed2612b5 8b277b8e .config console log report info KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/05/08 12:25 upstream 30c8e80f7932 e60b1103 .config console log report info KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
ci2-upstream-kcsan-gce 2022/04/06 11:04 upstream 3e732ebf7316 86b4b7f8 .config console log report info KCSAN: data-race in filemap_fdatawrite_wbc / xas_set_mark
* Struck through repros no longer work on HEAD.