syzbot


KCSAN: data-race in shmem_getattr / shmem_getpage_gfp (6)

Status: auto-closed as invalid on 2022/03/29 04:30
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 285d, last: 279d
similar bugs (5):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in shmem_getattr / shmem_getpage_gfp 1 1080d 1080d 0/24 auto-closed as invalid on 2020/02/21 18:37
upstream KCSAN: data-race in shmem_getattr / shmem_getpage_gfp (5) 2 327d 337d 0/24 auto-closed as invalid on 2022/02/08 18:20
upstream KCSAN: data-race in shmem_getattr / shmem_getpage_gfp (2) 1 578d 578d 0/24 auto-closed as invalid on 2021/06/03 02:49
upstream KCSAN: data-race in shmem_getattr / shmem_getpage_gfp (4) 1 381d 381d 0/24 auto-closed as invalid on 2021/12/17 11:16
upstream KCSAN: data-race in shmem_getattr / shmem_getpage_gfp (3) 3 458d 495d 0/24 auto-closed as invalid on 2021/10/01 07:46

Sample crash report:
loop2: detected capacity change from 0 to 264192
==================================================================
BUG: KCSAN: data-race in shmem_getattr / shmem_getpage_gfp

write to 0xffff8881165da320 of 8 bytes by task 2700 on cpu 0:
 shmem_getpage_gfp+0xe80/0x12c0 mm/shmem.c:1910
 shmem_getpage mm/shmem.c:149 [inline]
 shmem_file_read_iter+0x1b2/0x5d0 mm/shmem.c:2526
 call_read_iter include/linux/fs.h:2068 [inline]
 do_iter_readv_writev+0x2fb/0x380 fs/read_write.c:723
 do_iter_read+0x192/0x5d0 fs/read_write.c:786
 vfs_iter_read+0x4c/0x70 fs/read_write.c:828
 lo_read_simple drivers/block/loop.c:285 [inline]
 do_req_filebacked drivers/block/loop.c:500 [inline]
 loop_handle_cmd drivers/block/loop.c:1852 [inline]
 loop_process_work+0x746/0x12d0 drivers/block/loop.c:1892
 loop_rootcg_workfn+0x1b/0x20 drivers/block/loop.c:1923
 process_one_work+0x3f6/0x960 kernel/workqueue.c:2307
 worker_thread+0x616/0xa70 kernel/workqueue.c:2454
 kthread+0x1bf/0x1e0 kernel/kthread.c:377
 ret_from_fork+0x1f/0x30

read to 0xffff8881165da320 of 8 bytes by task 10659 on cpu 1:
 shmem_getattr+0x40/0x240 mm/shmem.c:1054
 vfs_getattr_nosec fs/stat.c:123 [inline]
 vfs_getattr+0x16a/0x1a0 fs/stat.c:160
 loop_get_status+0x162/0x240 drivers/block/loop.c:1336
 loop_get_status64 drivers/block/loop.c:1428 [inline]
 lo_ioctl+0x1eb/0x1260 drivers/block/loop.c:1573
 blkdev_ioctl+0x20e/0x440 block/ioctl.c:588
 vfs_ioctl fs/ioctl.c:51 [inline]
 __do_sys_ioctl fs/ioctl.c:874 [inline]
 __se_sys_ioctl+0xcb/0x140 fs/ioctl.c:860
 __x64_sys_ioctl+0x3f/0x50 fs/ioctl.c:860
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x44/0xd0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae

value changed: 0x0000000000000007 -> 0x0000000000000008

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 10659 Comm: syz-executor.2 Not tainted 5.17.0-rc5-syzkaller-00004-g038101e6b2cd-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (2):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2022/02/22 04:28 upstream 038101e6b2cd 6e821dbf .config log report info KCSAN: data-race in shmem_getattr / shmem_getpage_gfp
ci2-upstream-kcsan-gce 2022/02/16 01:56 upstream 705d84a366cf 8b9ca619 .config log report info KCSAN: data-race in shmem_getattr / shmem_getpage_gfp
* Struck through repros no longer work on HEAD.