[syzbot] [exfat?] KCSAN: data-race in fat16_ent_get / fat16_ent_put

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

syzbot found the following issue on:

HEAD commit:    e32cde8d2bd7 Merge tag 'sched_ext-for-6.12-rc1-fixes-1' of..
git tree:       upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=15c64307980000
kernel config:  https://syzkaller.appspot.com/x/.config?x=13af6e9c27c7bbbf
dashboard link: https://syzkaller.appspot.com/bug?extid=3999cae1c2d59c2cc8b9
compiler:       Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40

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

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/e728901b4154/disk-e32cde8d.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/e662806fa232/vmlinux-e32cde8d.xz
kernel image: https://storage.googleapis.com/syzbot-assets/ed885d1a3f98/bzImage-e32cde8d.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+3999cae1c2d59c2cc8b9@xxxxxxxxxxxxxxxxxxxxxxxxx

==================================================================
BUG: KCSAN: data-race in fat16_ent_get / fat16_ent_put

write to 0xffff888104b849d2 of 2 bytes by task 13613 on cpu 0:
 fat16_ent_put+0x28/0x60 fs/fat/fatent.c:183
 fat_free_clusters+0x2a6/0x7a0 fs/fat/fatent.c:597
 fat_free fs/fat/file.c:376 [inline]
 fat_truncate_blocks+0x4a8/0x530 fs/fat/file.c:394
 fat_evict_inode+0x102/0x160 fs/fat/inode.c:656
 evict+0x2f0/0x580 fs/inode.c:723
 iput_final fs/inode.c:1875 [inline]
 iput+0x42a/0x5b0 fs/inode.c:1901
 do_unlinkat+0x282/0x4c0 fs/namei.c:4540
 __do_sys_unlink fs/namei.c:4581 [inline]
 __se_sys_unlink fs/namei.c:4579 [inline]
 __x64_sys_unlink+0x2e/0x40 fs/namei.c:4579
 x64_sys_call+0x280f/0x2d60 arch/x86/include/generated/asm/syscalls_64.h:88
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xc9/0x1c0 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

read to 0xffff888104b849d2 of 2 bytes by task 14376 on cpu 1:
 fat16_ent_get+0x23/0x70 fs/fat/fatent.c:140
 fat_ent_read+0x3e0/0x5a0 fs/fat/fatent.c:372
 fat_get_cluster+0x4b9/0x830 fs/fat/cache.c:266
 fat_free fs/fat/file.c:346 [inline]
 fat_truncate_blocks+0x271/0x530 fs/fat/file.c:394
 fat_write_failed fs/fat/inode.c:218 [inline]
 fat_write_begin+0xc0/0xe0 fs/fat/inode.c:232
 generic_perform_write+0x1a8/0x4a0 mm/filemap.c:4054
 __generic_file_write_iter+0xa1/0x120 mm/filemap.c:4155
 generic_file_write_iter+0x77/0x1c0 mm/filemap.c:4181
 __kernel_write_iter+0x24b/0x4e0 fs/read_write.c:616
 dump_emit_page fs/coredump.c:884 [inline]
 dump_user_range+0x3a7/0x550 fs/coredump.c:945
 elf_core_dump+0x1b66/0x1c60 fs/binfmt_elf.c:2121
 do_coredump+0x1736/0x1ce0 fs/coredump.c:758
 get_signal+0xdc0/0x1070 kernel/signal.c:2902
 arch_do_signal_or_restart+0x95/0x4b0 arch/x86/kernel/signal.c:337
 exit_to_user_mode_loop kernel/entry/common.c:111 [inline]
 exit_to_user_mode_prepare include/linux/entry-common.h:328 [inline]
 irqentry_exit_to_user_mode+0x9a/0x130 kernel/entry/common.c:231
 irqentry_exit+0x12/0x50 kernel/entry/common.c:334
 exc_general_protection+0x33d/0x4d0 arch/x86/kernel/traps.c:693
 asm_exc_general_protection+0x26/0x30 arch/x86/include/asm/idtentry.h:617

value changed: 0x03ea -> 0x0000

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 UID: 0 PID: 14376 Comm: syz.3.1622 Not tainted 6.12.0-rc1-syzkaller-00031-ge32cde8d2bd7 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
==================================================================
FAT-fs (loop3): error, fat_get_cluster: invalid cluster chain (i_pos 1050)
FAT-fs (loop3): Filesystem has been set read-only
FAT-fs (loop3): error, fat_free_clusters: deleting FAT entry beyond EOF


---
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 syzkaller@xxxxxxxxxxxxxxxx.

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




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux