loop2: detected capacity change from 0 to 128 VFS: Found a Xenix FS (block size = 1024) on device loop2 ================================================================== BUG: KASAN: use-after-free in sysv_new_inode+0xd18/0xe90 fs/sysv/ialloc.c:153 Read of size 2 at addr ffff0000fb6a31ce by task syz.2.342/8049 CPU: 1 UID: 0 PID: 8049 Comm: syz.2.342 Not tainted 6.13.0-rc3-syzkaller-g06a573612678 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 Call trace: show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:466 (C) __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0xe4/0x150 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:378 [inline] print_report+0x198/0x538 mm/kasan/report.c:489 kasan_report+0xd8/0x138 mm/kasan/report.c:602 __asan_report_load2_noabort+0x20/0x2c mm/kasan/report_generic.c:379 sysv_new_inode+0xd18/0xe90 fs/sysv/ialloc.c:153 sysv_mknod+0x5c/0x100 fs/sysv/namei.c:53 sysv_create+0x38/0x4c fs/sysv/namei.c:67 lookup_open fs/namei.c:3649 [inline] open_last_lookups fs/namei.c:3748 [inline] path_openat+0x13e4/0x2b14 fs/namei.c:3984 do_filp_open+0x1e8/0x404 fs/namei.c:4014 do_sys_openat2+0x124/0x1b8 fs/open.c:1402 do_sys_open fs/open.c:1417 [inline] __do_sys_openat fs/open.c:1433 [inline] __se_sys_openat fs/open.c:1428 [inline] __arm64_sys_openat+0x1f0/0x240 fs/open.c:1428 __invoke_syscall arch/arm64/kernel/syscall.c:35 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:49 el0_svc_common+0x130/0x23c arch/arm64/kernel/syscall.c:132 do_el0_svc+0x48/0x58 arch/arm64/kernel/syscall.c:151 el0_svc+0x54/0x168 arch/arm64/kernel/entry-common.c:744 el0t_64_sync_handler+0x84/0x108 arch/arm64/kernel/entry-common.c:762 el0t_64_sync+0x198/0x19c arch/arm64/kernel/entry.S:600 The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x1ff7 pfn:0x13b6a3 flags: 0x5ffc00000000000(node=0|zone=2|lastcpupid=0x7ff) raw: 05ffc00000000000 dead000000000100 dead000000000122 0000000000000000 raw: 0000000000001ff7 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff0000fb6a3080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff0000fb6a3100: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff0000fb6a3180: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff0000fb6a3200: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff0000fb6a3280: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ================================================================== syz.2.342: attempt to access beyond end of device loop2: rw=2049, sector=6491536, nr_sectors = 2 limit=128