syz.0.0: attempt to access beyond end of device loop0: rw=6145, sector=10464, nr_sectors = 8 limit=64 BTRFS error (device loop0): bdev /dev/loop0 errs: wr 1, rd 0, flush 0, corrupt 0, gen 0 syz.0.0: attempt to access beyond end of device loop0: rw=6145, sector=10472, nr_sectors = 8 limit=64 BTRFS error (device loop0): bdev /dev/loop0 errs: wr 2, rd 0, flush 0, corrupt 0, gen 0 syz.0.0: attempt to access beyond end of device loop0: rw=6145, sector=10480, nr_sectors = 8 limit=64 BTRFS error (device loop0): bdev /dev/loop0 errs: wr 3, rd 0, flush 0, corrupt 0, gen 0 BTRFS error (device loop0): error while writing out transaction: -5 BTRFS warning (device loop0): Skipping commit of aborted transaction. BTRFS error (device loop0 state A): Transaction 10 aborted (error -5) BTRFS: error (device loop0 state A) in cleanup_transaction:2068: errno=-5 IO failure BTRFS info (device loop0 state EA): forced readonly BTRFS info (device loop0 state EA): last unmount of filesystem ed167579-eb65-4e76-9a50-61ac97e9b59d ------------[ cut here ]------------ 1 WARNING: fs/btrfs/space-info.h:286 at btrfs_space_info_update_bytes_may_use+0x318/0x650 fs/btrfs/space-info.h:286, CPU#0: syz.0.0/5325 Modules linked in: CPU: 0 UID: 0 PID: 5325 Comm: syz.0.0 Not tainted syzkaller #0 PREEMPT(full) Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 RIP: 0010:btrfs_space_info_update_bytes_may_use+0x318/0x650 fs/btrfs/space-info.h:286 Code: 00 00 74 08 4c 89 ff e8 d6 06 fe fd 4d 8b 27 4c 89 e7 48 8b 6c 24 18 48 89 ee e8 f3 dd 8e fd 49 39 ec 73 1c e8 89 db 8e fd 90 <0f> 0b 90 31 db 43 80 7c 35 00 00 0f 85 48 ff ff ff e9 4b ff ff ff RSP: 0018:ffffc9000e70f8b8 EFLAGS: 00010293 RAX: ffffffff8437a647 RBX: ffffffffffea1000 RCX: ffff888031a82540 RDX: 0000000000000000 RSI: 000000000015f000 RDI: 000000000015e000 RBP: 000000000015f000 R08: ffffffff9057abf7 R09: 1ffffffff20af57e R10: dffffc0000000000 R11: fffffbfff20af57f R12: 000000000015e000 R13: 1ffff110023ad910 R14: dffffc0000000000 R15: ffff888011d6c880 FS: 0000000000000000(0000) GS:ffff88808c549000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000200000001480 CR3: 000000005117c000 CR4: 0000000000352ef0 Call Trace: btrfs_space_info_free_bytes_may_use fs/btrfs/space-info.h:323 [inline] block_rsv_release_bytes fs/btrfs/block-rsv.c:153 [inline] btrfs_block_rsv_release+0x47b/0x590 fs/btrfs/block-rsv.c:291 btrfs_release_global_block_rsv+0x33/0x300 fs/btrfs/block-rsv.c:462 btrfs_free_block_groups+0xdf1/0x1090 fs/btrfs/block-group.c:4777 close_ctree+0x788/0x11b0 fs/btrfs/disk-io.c:4542 generic_shutdown_super+0x13d/0x2d0 fs/super.c:647 kill_anon_super+0x3b/0x70 fs/super.c:1232 btrfs_kill_super+0x41/0x50 fs/btrfs/super.c:2154 deactivate_locked_super+0xbc/0x130 fs/super.c:477 cleanup_mnt+0x3d3/0x460 fs/namespace.c:1317 task_work_run+0x1d9/0x270 kernel/task_work.c:233 exit_task_work include/linux/task_work.h:40 [inline] do_exit+0x73a/0x2360 kernel/exit.c:1009 do_group_exit+0x22d/0x2f0 kernel/exit.c:1152 __do_sys_exit_group kernel/exit.c:1163 [inline] __se_sys_exit_group kernel/exit.c:1161 [inline] __x64_sys_exit_group+0x3f/0x40 kernel/exit.c:1161 x64_sys_call+0x221a/0x2240 arch/x86/include/generated/asm/syscalls_64.h:232 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0x174/0x580 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f7b7379de99 Code: Unable to access opcode bytes at 0x7f7b7379de6f. RSP: 002b:00007ffe77aae8f8 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f7b7379de99 RDX: 0000000000000064 RSI: 0000000000000000 RDI: 0000000000000000 RBP: 0000000000000003 R08: 0000000000000000 R09: 00007f7b739ea3e0 R10: 0000000000000001 R11: 0000000000000246 R12: 0000000000000000 R13: 00007f7b739ea3e0 R14: 0000000000000003 R15: 00007ffe77aae9b0