[moderation] [mm?] [fs?] KCSAN: data-race in xas_create / xas_find (6)

2 views
Skip to first unread message

syzbot

unread,
Dec 31, 2023, 9:02:29 AM12/31/23
to syzkaller-upst...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 453f5db0619e Merge tag 'trace-v6.7-rc7' of git://git.kerne..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=1643bff1e80000
kernel config: https://syzkaller.appspot.com/x/.config?x=4da1e2da456c3a7d
dashboard link: https://syzkaller.appspot.com/bug?extid=aef01624d1d90b976063
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
CC: [ak...@linux-foundation.org linux-...@vger.kernel.org linux-...@vger.kernel.org linu...@kvack.org wi...@infradead.org]

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

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/c9da66f61dd6/disk-453f5db0.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/8e7a5604afa2/vmlinux-453f5db0.xz
kernel image: https://storage.googleapis.com/syzbot-assets/323c3d73a7c1/bzImage-453f5db0.xz

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

loop4: detected capacity change from 0 to 2048
==================================================================
BUG: KCSAN: data-race in xas_create / xas_find

write to 0xffff888140e5b919 of 1 bytes by task 21827 on cpu 0:
xas_expand lib/xarray.c:612 [inline]
xas_create+0x656/0xbb0 lib/xarray.c:653
xas_store+0x78/0xc90 lib/xarray.c:787
__filemap_add_folio+0x45e/0x730 mm/filemap.c:898
filemap_add_folio+0x70/0x160 mm/filemap.c:937
page_cache_ra_unbounded+0x15e/0x2e0 mm/readahead.c:250
do_page_cache_ra mm/readahead.c:299 [inline]
force_page_cache_ra mm/readahead.c:330 [inline]
page_cache_sync_ra+0x24b/0x2a0 mm/readahead.c:691
page_cache_sync_readahead include/linux/pagemap.h:1283 [inline]
filemap_get_pages+0x251/0xf90 mm/filemap.c:2497
filemap_read+0x214/0x680 mm/filemap.c:2593
blkdev_read_iter+0x217/0x2c0 block/fops.c:742
call_read_iter include/linux/fs.h:2014 [inline]
new_sync_read fs/read_write.c:389 [inline]
vfs_read+0x3c0/0x590 fs/read_write.c:470
ksys_read+0xeb/0x1a0 fs/read_write.c:613
__do_sys_read fs/read_write.c:623 [inline]
__se_sys_read fs/read_write.c:621 [inline]
__x64_sys_read+0x42/0x50 fs/read_write.c:621
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0x44/0x110 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x63/0x6b

read to 0xffff888140e5b919 of 1 bytes by task 15693 on cpu 1:
xas_find+0x372/0x3f0 lib/xarray.c:1262
find_get_entry mm/filemap.c:1958 [inline]
find_lock_entries+0xb1/0x680 mm/filemap.c:2059
truncate_inode_pages_range+0x130/0x6a0 mm/truncate.c:363
truncate_inode_pages+0x24/0x30 mm/truncate.c:448
kill_bdev block/bdev.c:76 [inline]
set_blocksize+0x26c/0x290 block/bdev.c:152
sb_set_blocksize+0x2d/0xb0 block/bdev.c:161
fat_fill_super+0x15d6/0x28e0 fs/fat/inode.c:1685
msdos_fill_super+0x2d/0x40 fs/fat/namei_msdos.c:655
mount_bdev+0x185/0x1f0 fs/super.c:1650
msdos_mount+0x31/0x40 fs/fat/namei_msdos.c:662
legacy_get_tree+0x74/0xd0 fs/fs_context.c:662
vfs_get_tree+0x51/0x1b0 fs/super.c:1771
do_new_mount+0x203/0x660 fs/namespace.c:3337
path_mount+0x496/0xb30 fs/namespace.c:3664
do_mount fs/namespace.c:3677 [inline]
__do_sys_mount fs/namespace.c:3886 [inline]
__se_sys_mount+0x27f/0x2d0 fs/namespace.c:3863
__x64_sys_mount+0x67/0x80 fs/namespace.c:3863
do_syscall_x64 arch/x86/entry/common.c:52 [inline]
do_syscall_64+0x44/0x110 arch/x86/entry/common.c:83
entry_SYSCALL_64_after_hwframe+0x63/0x6b

value changed: 0x18 -> 0x00

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 15693 Comm: syz-executor.4 Not tainted 6.7.0-rc7-syzkaller-00049-g453f5db0619e #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/17/2023
==================================================================
msdos filesystem being mounted at /root/syzkaller-testdir2553321465/syzkaller.8JeL27/1479/file0 supports timestamps until 2107-12-31 (0x10391447e)


---
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

syzbot

unread,
Apr 7, 2024, 8:15:16 PMApr 7
to syzkaller-upst...@googlegroups.com
Auto-closing this bug as obsolete.
Crashes did not happen for a while, no reproducer and no activity.
Reply all
Reply to author
Forward
0 new messages