[moderation] [fs?] KCSAN: data-race in file_update_time / inode_update_timestamps

2 views
Skip to first unread message

syzbot

unread,
Feb 2, 2024, 1:13:31 PMFeb 2
to syzkaller-upst...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 021533194476 Kconfig: Disable -Wstringop-overflow for GCC ..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=16d3d5d3e80000
kernel config: https://syzkaller.appspot.com/x/.config?x=b75adb52627a8379
dashboard link: https://syzkaller.appspot.com/bug?extid=350a06399dc605f610f0
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
CC: [bra...@kernel.org ja...@suse.cz linux-...@vger.kernel.org linux-...@vger.kernel.org vi...@zeniv.linux.org.uk]

Unfortunately, I don't have any reproducer for this issue yet.

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/b2f6a21a62ff/disk-02153319.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/90e0e75c7922/vmlinux-02153319.xz
kernel image: https://storage.googleapis.com/syzbot-assets/4dfed5f7a347/bzImage-02153319.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+350a06...@syzkaller.appspotmail.com

==================================================================
BUG: KCSAN: data-race in file_update_time / inode_update_timestamps

write to 0xffff88815b2892a0 of 8 bytes by task 9696 on cpu 0:
inode_set_ctime_to_ts include/linux/fs.h:1601 [inline]
inode_set_ctime include/linux/fs.h:1619 [inline]
inode_set_ctime_current fs/inode.c:2512 [inline]
inode_update_timestamps+0xb5/0x280 fs/inode.c:1859
generic_update_time fs/inode.c:1898 [inline]
inode_update_time fs/inode.c:1918 [inline]
__file_update_time fs/inode.c:2106 [inline]
file_update_time+0x229/0x2b0 fs/inode.c:2136
fault_dirty_shared_page+0xde/0x2d0 mm/memory.c:3008
do_shared_fault mm/memory.c:4826 [inline]
do_fault mm/memory.c:4872 [inline]
do_pte_missing mm/memory.c:3745 [inline]
handle_pte_fault mm/memory.c:5144 [inline]
__handle_mm_fault mm/memory.c:5285 [inline]
handle_mm_fault+0x13a6/0x27c0 mm/memory.c:5450
do_user_addr_fault arch/x86/mm/fault.c:1364 [inline]
handle_page_fault arch/x86/mm/fault.c:1507 [inline]
exc_page_fault+0x401/0x6d0 arch/x86/mm/fault.c:1563
asm_exc_page_fault+0x26/0x30 arch/x86/include/asm/idtentry.h:570

read to 0xffff88815b2892a0 of 8 bytes by task 9700 on cpu 1:
inode_get_ctime include/linux/fs.h:1595 [inline]
inode_needs_update_time fs/inode.c:2089 [inline]
file_update_time+0x107/0x2b0 fs/inode.c:2132
fault_dirty_shared_page+0xde/0x2d0 mm/memory.c:3008
do_shared_fault mm/memory.c:4826 [inline]
do_fault mm/memory.c:4872 [inline]
do_pte_missing mm/memory.c:3745 [inline]
handle_pte_fault mm/memory.c:5144 [inline]
__handle_mm_fault mm/memory.c:5285 [inline]
handle_mm_fault+0x13a6/0x27c0 mm/memory.c:5450
faultin_page mm/gup.c:958 [inline]
__get_user_pages+0x402/0xe40 mm/gup.c:1241
faultin_vma_page_range+0x7e/0xa0 mm/gup.c:1737
madvise_populate mm/madvise.c:929 [inline]
madvise_vma_behavior mm/madvise.c:1038 [inline]
madvise_walk_vmas mm/madvise.c:1260 [inline]
do_madvise+0x90b/0x25e0 mm/madvise.c:1440
__do_sys_madvise mm/madvise.c:1453 [inline]
__se_sys_madvise mm/madvise.c:1451 [inline]
__x64_sys_madvise+0x60/0x70 mm/madvise.c:1451
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0xcd/0x1d0 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x63/0x6b

value changed: 0x000000002fd5dc8f -> 0x00000000306e730f

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 9700 Comm: syz-executor.1 Not tainted 6.8.0-rc2-syzkaller-00199-g021533194476 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/25/2024
==================================================================


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup
Reply all
Reply to author
Forward
0 new messages