R10: 0000000000000006 R11: 0000000000000246 R12: 0000000000000002 R13: 000000000000000b R14: 00007f36d139bf80 R15: 00007ffdc7126168 ------------[ cut here ]------------ kernel BUG at fs/btrfs/extent-io-tree.c:560! invalid opcode: 0000 [#1] PREEMPT SMP KASAN CPU: 1 PID: 17301 Comm: syz-executor.3 Not tainted 6.7.0-rc7-syzkaller-00041-gf016f7547aee #0 Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.2-debian-1.16.2-1 04/01/2014 RIP: 0010:clear_state_bit+0x322/0x3b0 fs/btrfs/extent-io-tree.c:560 Code: 4c 89 f0 83 e0 07 83 c0 03 38 d0 7c 04 84 d2 75 35 8b 6b 7c e9 aa fe ff ff e8 0a c4 ea fd 90 0f 0b 90 eb 96 e8 ff c3 ea fd 90 <0f> 0b 4c 89 f7 e8 14 ab 40 fe e9 6b fd ff ff 4c 89 f7 e8 07 ab 40 RSP: 0018:ffffc9002ada6af0 EFLAGS: 00010246 RAX: 0000000000040000 RBX: ffff88806024bb40 RCX: ffffc90005936000 RDX: 0000000000040000 RSI: ffffffff839ba081 RDI: 0000000000000005 RBP: 00000000fffffff4 R08: 0000000000000005 R09: 0000000000000000 R10: 00000000fffffff4 R11: 0000000000000002 R12: ffff88805fd1b280 R13: 0000000000000000 R14: ffff88806024bbbc R15: 0000000000000fff FS: 00007f36d1eee6c0(0000) GS:ffff88806b700000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000001b31338000 CR3: 000000010faed000 CR4: 0000000000350ef0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: __clear_extent_bit+0x531/0xc60 fs/btrfs/extent-io-tree.c:731 __btrfs_qgroup_release_data+0x1bc/0xa30 fs/btrfs/qgroup.c:4136 alloc_ordered_extent+0x57d/0x6b0 fs/btrfs/ordered-data.c:168 btrfs_alloc_ordered_extent+0x76/0xae0 fs/btrfs/ordered-data.c:275 cow_file_range+0x56c/0x1070 fs/btrfs/inode.c:1426 btrfs_run_delalloc_range+0x361/0xff0 fs/btrfs/inode.c:2280 writepage_delalloc+0x16a/0x360 fs/btrfs/extent_io.c:1189 __extent_writepage fs/btrfs/extent_io.c:1440 [inline] extent_write_cache_pages+0x7e8/0x1b80 fs/btrfs/extent_io.c:2108 extent_writepages+0x21b/0x4a0 fs/btrfs/extent_io.c:2230 do_writepages+0x1b4/0x690 mm/page-writeback.c:2553 filemap_fdatawrite_wbc mm/filemap.c:387 [inline] filemap_fdatawrite_wbc+0x144/0x1b0 mm/filemap.c:377 __filemap_fdatawrite_range+0xba/0x100 mm/filemap.c:420 btrfs_fdatawrite_range+0x4a/0x110 fs/btrfs/file.c:3863 btrfs_direct_write fs/btrfs/file.c:1617 [inline] btrfs_do_write_iter+0xc12/0x1120 fs/btrfs/file.c:1684 call_write_iter include/linux/fs.h:2020 [inline] do_iter_readv_writev+0x21e/0x3c0 fs/read_write.c:735 do_iter_write+0x17f/0x7f0 fs/read_write.c:860 vfs_iter_write+0x7a/0xb0 fs/read_write.c:901 iter_file_splice_write+0x698/0xc00 fs/splice.c:736 do_splice_from fs/splice.c:933 [inline] direct_splice_actor+0x118/0x180 fs/splice.c:1142 splice_direct_to_actor+0x347/0xa30 fs/splice.c:1088 do_splice_direct+0x1af/0x280 fs/splice.c:1194 do_sendfile+0xb3e/0x1310 fs/read_write.c:1254 __do_sys_sendfile64 fs/read_write.c:1322 [inline] __se_sys_sendfile64 fs/read_write.c:1308 [inline] __x64_sys_sendfile64+0x1d6/0x220 fs/read_write.c:1308 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0x40/0x110 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x63/0x6b RIP: 0033:0x7f36d127cce9 Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f36d1eee0c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000028 RAX: ffffffffffffffda RBX: 00007f36d139bf80 RCX: 00007f36d127cce9 RDX: 0000000000000000 RSI: 0000000000000007 RDI: 0000000000000006 RBP: 00007f36d1eee120 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000006 R11: 0000000000000246 R12: 0000000000000002 R13: 000000000000000b R14: 00007f36d139bf80 R15: 00007ffdc7126168 Modules linked in: ---[ end trace 0000000000000000 ]--- RIP: 0010:clear_state_bit+0x322/0x3b0 fs/btrfs/extent-io-tree.c:560 Code: 4c 89 f0 83 e0 07 83 c0 03 38 d0 7c 04 84 d2 75 35 8b 6b 7c e9 aa fe ff ff e8 0a c4 ea fd 90 0f 0b 90 eb 96 e8 ff c3 ea fd 90 <0f> 0b 4c 89 f7 e8 14 ab 40 fe e9 6b fd ff ff 4c 89 f7 e8 07 ab 40 RSP: 0018:ffffc9002ada6af0 EFLAGS: 00010246 RAX: 0000000000040000 RBX: ffff88806024bb40 RCX: ffffc90005936000 RDX: 0000000000040000 RSI: ffffffff839ba081 RDI: 0000000000000005 RBP: 00000000fffffff4 R08: 0000000000000005 R09: 0000000000000000 R10: 00000000fffffff4 R11: 0000000000000002 R12: ffff88805fd1b280 R13: 0000000000000000 R14: ffff88806024bbbc R15: 0000000000000fff FS: 00007f36d1eee6c0(0000) GS:ffff88806b700000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000001b31338000 CR3: 000000010faed000 CR4: 0000000000350ef0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400