syzbot


KCSAN: data-race in ext4_setattr / next_uptodate_page

Status: auto-closed as invalid on 2021/06/20 22:51
Subsystems: ext4
[Documentation on labels]
First crash: 1645d, last: 1614d
Similar bugs (2)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in ext4_setattr / next_uptodate_page (3) ext4 6 1 1406d 1406d 0/29 auto-closed as invalid on 2022/01/14 12:58
upstream KCSAN: data-race in ext4_setattr / next_uptodate_page (2) ext4 6 1 1574d 1574d 0/29 auto-closed as invalid on 2021/09/03 10:03

Sample crash report:
==================================================================
BUG: KCSAN: data-race in ext4_setattr / next_uptodate_page

write to 0xffff888148f1a680 of 8 bytes by task 18205 on cpu 0:
 i_size_write include/linux/fs.h:871 [inline]
 ext4_setattr+0xd54/0xec0 fs/ext4/inode.c:5481
 notify_change+0x8a3/0xa80 fs/attr.c:398
 do_truncate+0xe8/0x130 fs/open.c:64
 handle_truncate fs/namei.c:3017 [inline]
 do_open fs/namei.c:3365 [inline]
 path_openat+0x1a79/0x20b0 fs/namei.c:3494
 do_filp_open+0xd9/0x1f0 fs/namei.c:3521
 do_sys_openat2+0xa3/0x250 fs/open.c:1187
 do_sys_open fs/open.c:1203 [inline]
 __do_sys_creat fs/open.c:1277 [inline]
 __se_sys_creat fs/open.c:1271 [inline]
 __x64_sys_creat+0x62/0x80 fs/open.c:1271
 do_syscall_64+0x4a/0x90 arch/x86/entry/common.c:47
 entry_SYSCALL_64_after_hwframe+0x44/0xae

read to 0xffff888148f1a680 of 8 bytes by task 18196 on cpu 1:
 i_size_read include/linux/fs.h:849 [inline]
 next_uptodate_page+0x323/0x670 mm/filemap.c:3146
 next_map_page mm/filemap.c:3171 [inline]
 filemap_map_pages+0x761/0x870 mm/filemap.c:3227
 do_fault_around mm/memory.c:3961 [inline]
 do_read_fault mm/memory.c:3975 [inline]
 do_fault mm/memory.c:4108 [inline]
 handle_pte_fault mm/memory.c:4367 [inline]
 __handle_mm_fault mm/memory.c:4502 [inline]
 handle_mm_fault+0xda3/0x1a70 mm/memory.c:4600
 faultin_page mm/gup.c:908 [inline]
 __get_user_pages+0x947/0xee0 mm/gup.c:1127
 populate_vma_page_range mm/gup.c:1460 [inline]
 __mm_populate+0x24d/0x380 mm/gup.c:1508
 mm_populate include/linux/mm.h:2621 [inline]
 vm_mmap_pgoff+0x145/0x1d0 mm/util.c:524
 ksys_mmap_pgoff+0x2a8/0x380 mm/mmap.c:1638
 do_syscall_64+0x4a/0x90 arch/x86/entry/common.c:47
 entry_SYSCALL_64_after_hwframe+0x44/0xae

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 18196 Comm: syz-executor.3 Tainted: G        W         5.13.0-rc1-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (5):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2021/05/16 22:43 upstream 63d1cb53e26a f54a5c09 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in ext4_setattr / next_uptodate_page
2021/05/16 11:41 upstream c12a29ed9094 f54a5c09 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in ext4_setattr / next_uptodate_page
2021/05/12 19:18 upstream dbb5afad100a ed7d41c5 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in ext4_setattr / next_uptodate_page
2021/05/08 18:49 upstream dd860052c99b bc5434be .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in ext4_setattr / next_uptodate_page
2021/04/15 15:10 upstream 7f75285ca572 fcdb12ba .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in ext4_setattr / next_uptodate_page
* Struck through repros no longer work on HEAD.