------------[ cut here ]------------ WARNING: CPU: 0 PID: 4754 at fs/btrfs/block-group.c:3674 do_chunk_alloc fs/btrfs/block-group.c:3674 [inline] WARNING: CPU: 0 PID: 4754 at fs/btrfs/block-group.c:3674 btrfs_chunk_alloc+0xd5c/0xfa4 fs/btrfs/block-group.c:3916 Modules linked in: CPU: 0 PID: 4754 Comm: kworker/u4:14 Not tainted 6.1.97-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/07/2024 Workqueue: events_unbound btrfs_async_reclaim_metadata_space pstate: 60400005 (nZCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--) pc : do_chunk_alloc fs/btrfs/block-group.c:3674 [inline] pc : btrfs_chunk_alloc+0xd5c/0xfa4 fs/btrfs/block-group.c:3916 lr : do_chunk_alloc fs/btrfs/block-group.c:3674 [inline] lr : btrfs_chunk_alloc+0xd5c/0xfa4 fs/btrfs/block-group.c:3916 sp : ffff80001ded6680 x29: ffff80001ded66f0 x28: ffff0000e014d000 x27: 1fffe0001ba96713 x26: 1fffe0001bec2159 x25: ffff0000df610acb x24: dfff800000000000 x23: ffff0000df610a80 x22: 0000000000000000 x21: 0000000000000000 x20: ffffffffffffffe4 x19: ffff0000dd4b3800 x18: ffff80001ded5a80 x17: 0000000000000000 x16: ffff80001216ee24 x15: 0000000000000000 x14: 00000000ffffffff x13: 0000000000000001 x12: 0000000000000001 x11: 0000000000ff0100 x10: 0000000000000000 x9 : de6fd006477d1900 x8 : de6fd006477d1900 x7 : 0000000000000001 x6 : 0000000000000001 x5 : ffff80001ded5f78 x4 : ffff800015942b20 x3 : ffff800008588a2c x2 : 0000000000000001 x1 : 0000000100000000 x0 : 0000000000000000 Call trace: do_chunk_alloc fs/btrfs/block-group.c:3674 [inline] btrfs_chunk_alloc+0xd5c/0xfa4 fs/btrfs/block-group.c:3916 find_free_extent_update_loop fs/btrfs/extent-tree.c:4124 [inline] find_free_extent+0x3c70/0x48c0 fs/btrfs/extent-tree.c:4510 btrfs_reserve_extent+0x364/0x680 fs/btrfs/extent-tree.c:4603 cow_file_range+0x3e8/0xd0c fs/btrfs/inode.c:1276 btrfs_run_delalloc_range+0x568/0x1004 fs/btrfs/inode.c:2229 writepage_delalloc+0x1e0/0x470 fs/btrfs/extent_io.c:1972 __extent_writepage+0x5b8/0xd3c fs/btrfs/extent_io.c:2276 extent_write_cache_pages fs/btrfs/extent_io.c:3191 [inline] extent_writepages+0xa48/0x1254 fs/btrfs/extent_io.c:3313 btrfs_writepages+0x28/0x38 fs/btrfs/inode.c:8280 do_writepages+0x2e8/0x56c mm/page-writeback.c:2469 filemap_fdatawrite_wbc+0x124/0x174 mm/filemap.c:388 start_delalloc_inodes+0x628/0xa00 fs/btrfs/inode.c:9756 btrfs_start_delalloc_roots+0x5d0/0x894 fs/btrfs/inode.c:9835 shrink_delalloc fs/btrfs/space-info.c:622 [inline] flush_space+0x578/0xdb8 fs/btrfs/space-info.c:730 btrfs_async_reclaim_metadata_space+0x260/0x30c fs/btrfs/space-info.c:1080 process_one_work+0x7ac/0x1404 kernel/workqueue.c:2292 worker_thread+0x8e4/0xfec kernel/workqueue.c:2439 kthread+0x250/0x2d8 kernel/kthread.c:376 ret_from_fork+0x10/0x20 arch/arm64/kernel/entry.S:864 irq event stamp: 1895786 hardirqs last enabled at (1895785): [] __up_console_sem+0xb4/0x100 kernel/printk/printk.c:261 hardirqs last disabled at (1895786): [] el1_dbg+0x24/0x80 arch/arm64/kernel/entry-common.c:405 softirqs last enabled at (1895234): [] softirq_handle_end kernel/softirq.c:414 [inline] softirqs last enabled at (1895234): [] handle_softirqs+0xb84/0xd58 kernel/softirq.c:599 softirqs last disabled at (1895189): [] __do_softirq+0x14/0x20 kernel/softirq.c:605 ---[ end trace 0000000000000000 ]--- BTRFS info (device loop3: state A): dumping space info: BTRFS info (device loop3: state A): space_info DATA+METADATA has 4206592 free, is not full BTRFS info (device loop3: state A): space_info total=11534336, used=53248, pinned=20480, reserved=0, may_use=7254016, readonly=0 zone_unusable=0 BTRFS info (device loop3: state A): space_info SYSTEM has -98304 free, is not full BTRFS info (device loop3: state A): space_info total=4194304, used=4096, pinned=0, reserved=0, may_use=98304, readonly=4190208 zone_unusable=0 BTRFS info (device loop3: state A): global_block_rsv: size 917504 reserved 917504 BTRFS info (device loop3: state A): trans_block_rsv: size 0 reserved 0 BTRFS info (device loop3: state A): chunk_block_rsv: size 98304 reserved 98304 BTRFS info (device loop3: state A): delayed_block_rsv: size 0 reserved 0 BTRFS info (device loop3: state A): delayed_refs_rsv: size 393216 reserved 393216 BTRFS: error (device loop3: state A) in do_chunk_alloc:3674: errno=-28 No space left BTRFS info (device loop3: state EA): forced readonly BTRFS: error (device loop3: state EA) in btrfs_create_pending_block_groups:2532: errno=-28 No space left