BTRFS critical (device loop3): panic in insert_ordered_extent:264: overlapping ordered extents, existing oe file_offset 36864 num_bytes 425984 flags 0x1089, new oe file_offset 36864 num_bytes 425984 flags 0x80 (errno=-17 Object already exists)
------------[ cut here ]------------
kernel BUG at fs/btrfs/ordered-data.c:264!
Oops: invalid opcode: 0000 [#1] SMP KASAN PTI
CPU: 1 UID: 0 PID: 7292 Comm: syz.3.194 Not tainted syzkaller #0 PREEMPT(full) 
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.2-debian-1.16.2-1 04/01/2014
RIP: 0010:btrfs_alloc_ordered_extent+0x943/0xad0
Code: 21 8e ba 08 01 00 00 b9 ef ff ff ff 49 c7 c0 a0 d9 38 8c 4d 89 f9 ff 75 00 41 54 41 55 41 56 53 e8 b2 c5 12 fd 48 83 c4 28 90 <0f> 0b e8 06 33 af fd 48 c7 c7 00 d1 38 8c 48 c7 c6 60 d1 38 8c 48
RSP: 0018:ffffc9000445ec10 EFLAGS: 00010292
RAX: addb694df9908500 RBX: 0000000000068000 RCX: 1ffff9200088bd60
RDX: 0000000000000006 RSI: ffffffff8e22e8dc RDI: ffffffff8c4be580
RBP: ffff888170d308e0 R08: ffffffff90579f37 R09: 1ffffffff20af3e6
R10: dffffc0000000000 R11: fffffbfff20af3e7 R12: 0000000000068000
R13: 0000000000009000 R14: 0000000000001089 R15: 0000000000009000
FS:  00007ff5c24da6c0(0000) GS:ffff8882a8f4b000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000055bbc3e1d668 CR3: 000000011034a000 CR4: 00000000000006f0
Call Trace:
 <TASK>
 cow_file_range+0x744/0x12a0
 btrfs_run_delalloc_range+0x89e/0x1fd0
 writepage_delalloc+0x104d/0x1ba0
 btrfs_writepages+0x1667/0x28b0
 do_writepages+0x338/0x560
 filemap_fdatawrite_range+0x1ef/0x2f0
 btrfs_fdatawrite_range+0x54/0xf0
 btrfs_direct_write+0x69d/0xc20
 btrfs_do_write_iter+0x325/0x790
 do_iter_readv_writev+0x612/0x8c0
 vfs_writev+0x343/0x990
 __se_sys_pwritev2+0x177/0x2a0
 do_syscall_64+0x174/0x580
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7ff5c159e019
Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 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 e8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ff5c24da028 EFLAGS: 00000246 ORIG_RAX: 0000000000000148
RAX: ffffffffffffffda RBX: 00007ff5c1826180 RCX: 00007ff5c159e019
RDX: 0000000000000001 RSI: 0000200000000240 RDI: 0000000000000005
RBP: 00007ff5c163500c R08: 0000000000000000 R09: 0000000000000003
R10: 0000000000007000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ff5c1826218 R14: 00007ff5c1826180 R15: 00007ffe935c4508
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:btrfs_alloc_ordered_extent+0x943/0xad0
Code: 21 8e ba 08 01 00 00 b9 ef ff ff ff 49 c7 c0 a0 d9 38 8c 4d 89 f9 ff 75 00 41 54 41 55 41 56 53 e8 b2 c5 12 fd 48 83 c4 28 90 <0f> 0b e8 06 33 af fd 48 c7 c7 00 d1 38 8c 48 c7 c6 60 d1 38 8c 48
RSP: 0018:ffffc9000445ec10 EFLAGS: 00010292
RAX: addb694df9908500 RBX: 0000000000068000 RCX: 1ffff9200088bd60
RDX: 0000000000000006 RSI: ffffffff8e22e8dc RDI: ffffffff8c4be580
RBP: ffff888170d308e0 R08: ffffffff90579f37 R09: 1ffffffff20af3e6
R10: dffffc0000000000 R11: fffffbfff20af3e7 R12: 0000000000068000
R13: 0000000000009000 R14: 0000000000001089 R15: 0000000000009000
FS:  00007ff5c24da6c0(0000) GS:ffff8882a8f4b000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000055bbc3e1d668 CR3: 000000011034a000 CR4: 00000000000006f0
