[53632.588013] run fstests generic/251 at 2023-07-20 11:48:08
[53633.009873] BTRFS: device fsid ec3e1159-917e-46d6-82d2-6d36aac552b0 devid 1 transid 2355520 /dev/mapper/vg0-lv0 scanned by mount (3747879)
[53633.010393] BTRFS info (device dm-0): using crc32c (crc32c-intel) checksum algorithm
[53633.010399] BTRFS info (device dm-0): using free space tree
[53633.014681] BTRFS info (device dm-0): auto enabling async discard
[53633.277350] BTRFS: device fsid b941fbc1-ea05-4637-8aca-36774a7f951a devid 1 transid 6 /dev/mapper/vg0-lv9 scanned by mkfs.btrfs (3747927)
[53633.301198] BTRFS info (device dm-9): using crc32c (crc32c-intel) checksum algorithm
[53633.301207] BTRFS info (device dm-9): turning on sync discard
[53633.301209] BTRFS info (device dm-9): enabling free space tree
[53633.301211] BTRFS info (device dm-9): using free space tree
[53633.304117] BTRFS info: devid 1 device path /dev/mapper/vg0-lv9 changed to /dev/dm-9 scanned by systemd-udevd (3746806)
[53633.304216] BTRFS info (device dm-9): creating free space tree
[53633.304840] BTRFS info (device dm-9): setting compat-ro feature flag for FREE_SPACE_TREE (0x1)
[53633.304846] BTRFS info (device dm-9): setting compat-ro feature flag for FREE_SPACE_TREE_VALID (0x2)
[53633.312296] BTRFS info: devid 1 device path /dev/dm-9 changed to /dev/mapper/vg0-lv9 scanned by systemd-udevd (3746806)
[53633.312489] BTRFS info (device dm-9): cleaning free space cache v1
[53633.321696] BTRFS info (device dm-9): checking UUID tree

[54231.134563] ======================================================
[54231.134816] WARNING: possible circular locking dependency detected
[54231.135078] 6.5.0-rc2+ #1245 Not tainted
[54231.135248] ------------------------------------------------------
[54231.135502] kswapd0/47 is trying to acquire lock:
[54231.135699] ffff967a160e6378 (btrfs_trans_num_writers){++++}-{0:0}, at: join_transaction+0x19f/0x550
[54231.136085] 
               but task is already holding lock:
[54231.136327] ffff967a61fdd600 (sb_internal#2){++++}-{0:0}, at: btrfs_commit_inode_delayed_inode+0x5f/0x120
[54231.136787] 
               which lock already depends on the new lock.

[54231.137125] 
               the existing dependency chain (in reverse order) is:
[54231.137429] 
               -> #3 (sb_internal#2){++++}-{0:0}:
[54231.137675]        start_transaction+0x401/0x730
[54231.137871]        btrfs_commit_inode_delayed_inode+0x5f/0x120
[54231.138120]        btrfs_evict_inode+0x273/0x3c0
[54231.138316]        evict+0xcc/0x1d0
[54231.138467]        inode_lru_isolate+0x14d/0x1e0
[54231.138662]        __list_lru_walk_one+0xbe/0x1c0
[54231.138862]        list_lru_walk_one+0x58/0x80
[54231.139055]        prune_icache_sb+0x39/0x60
[54231.139238]        super_cache_scan+0x161/0x1f0
[54231.139431]        do_shrink_slab+0x163/0x340
[54231.139619]        shrink_slab+0x1d7/0x2a0
[54231.139795]        shrink_node+0x2eb/0x7b0
[54231.139975]        balance_pgdat+0x344/0x780
[54231.140161]        kswapd+0x205/0x410
[54231.140321]        kthread+0xfc/0x130
[54231.140482]        ret_from_fork+0x2d/0x50
[54231.140657]        ret_from_fork_asm+0x1b/0x30
[54231.140849] 
               -> #2 (fs_reclaim){+.+.}-{0:0}:
[54231.141092]        fs_reclaim_acquire+0xa5/0xe0
[54231.141287]        kmem_cache_alloc_lru+0x4e/0x570
[54231.141492]        btrfs_alloc_inode+0x2d/0x250
[54231.141686]        alloc_inode+0x1a/0xc0
[54231.141857]        iget5_locked+0xba/0x110
[54231.142035]        btrfs_iget+0x43/0xe0
[54231.142200]        create_reloc_inode+0x19d/0x370
[54231.142401]        btrfs_relocate_block_group+0x1b7/0x410
[54231.142629]        btrfs_relocate_chunk+0x4c/0x190
[54231.142832]        btrfs_balance+0x8e7/0x11d0
[54231.143021]        btrfs_ioctl+0x1d3d/0x2900
[54231.143205]        __x64_sys_ioctl+0x8b/0xc0
[54231.143391]        do_syscall_64+0x38/0x90
[54231.143582]        entry_SYSCALL_64_after_hwframe+0x6e/0xd8
[54231.143820] 
               -> #1 (btrfs_trans_num_extwriters){++++}-{0:0}:
[54231.144118]        join_transaction+0xdb/0x550
[54231.144313]        start_transaction+0x24f/0x730
[54231.144511]        btrfs_uuid_scan_kthread+0x2bc/0x3d0
[54231.144725]        kthread+0xfc/0x130
[54231.144882]        ret_from_fork+0x2d/0x50
[54231.145059]        ret_from_fork_asm+0x1b/0x30
[54231.145251] 
               -> #0 (btrfs_trans_num_writers){++++}-{0:0}:
[54231.145605]        __lock_acquire+0x1415/0x2190
[54231.145801]        lock_acquire+0xc7/0x2b0
[54231.145980]        join_transaction+0x1cd/0x550
[54231.146172]        start_transaction+0x24f/0x730
[54231.146368]        btrfs_commit_inode_delayed_inode+0x5f/0x120
[54231.146611]        btrfs_evict_inode+0x273/0x3c0
[54231.146806]        evict+0xcc/0x1d0
[54231.146961]        inode_lru_isolate+0x14d/0x1e0
[54231.147155]        __list_lru_walk_one+0xbe/0x1c0
[54231.147355]        list_lru_walk_one+0x58/0x80
[54231.147544]        prune_icache_sb+0x39/0x60
[54231.147726]        super_cache_scan+0x161/0x1f0
[54231.147918]        do_shrink_slab+0x163/0x340
[54231.148111]        shrink_slab+0x1d7/0x2a0
[54231.148286]        shrink_node+0x2eb/0x7b0
[54231.148462]        balance_pgdat+0x344/0x780
[54231.148646]        kswapd+0x205/0x410
[54231.148803]        kthread+0xfc/0x130
[54231.148964]        ret_from_fork+0x2d/0x50
[54231.149141]        ret_from_fork_asm+0x1b/0x30
[54231.149331] 
               other info that might help us debug this:

[54231.149659] Chain exists of:
                 btrfs_trans_num_writers --> fs_reclaim --> sb_internal#2

[54231.150103]  Possible unsafe locking scenario:

[54231.150351]        CPU0                    CPU1
[54231.150543]        ----                    ----
[54231.150734]   rlock(sb_internal#2);
[54231.150885]                                lock(fs_reclaim);
[54231.151126]                                lock(sb_internal#2);
[54231.151374]   rlock(btrfs_trans_num_writers);
[54231.151561] 
                *** DEADLOCK ***

[54231.151808] 4 locks held by kswapd0/47:
[54231.151976]  #0: ffffffff95e62280 (fs_reclaim){+.+.}-{0:0}, at: balance_pgdat+0x492/0x780
[54231.152318]  #1: ffffffff95e507d0 (shrinker_rwsem){++++}-{3:3}, at: shrink_slab+0x113/0x2a0
[54231.152665]  #2: ffff967a61fdd0e0 (&type->s_umount_key#45){++++}-{3:3}, at: super_cache_scan+0x38/0x1f0
[54231.153054]  #3: ffff967a61fdd600 (sb_internal#2){++++}-{0:0}, at: btrfs_commit_inode_delayed_inode+0x5f/0x120
[54231.153468] 
               stack backtrace:
[54231.153656] CPU: 0 PID: 47 Comm: kswapd0 Not tainted 6.5.0-rc2+ #1245
[54231.153923] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.13.0-2.fc32 04/01/2014
[54231.154301] Call Trace:
[54231.154414]  
[54231.154515]  dump_stack_lvl+0x58/0x90
[54231.154689]  check_noncircular+0x101/0x110
[54231.154869]  __lock_acquire+0x1415/0x2190
[54231.155054]  lock_acquire+0xc7/0x2b0
[54231.155215]  ? join_transaction+0x19f/0x550
[54231.155400]  ? lock_release+0x134/0x270
[54231.155570]  join_transaction+0x1cd/0x550
[54231.155748]  ? join_transaction+0x19f/0x550
[54231.155932]  start_transaction+0x24f/0x730
[54231.156145]  btrfs_commit_inode_delayed_inode+0x5f/0x120
[54231.156378]  btrfs_evict_inode+0x273/0x3c0
[54231.156560]  ? lock_release+0x134/0x270
[54231.156730]  ? __pfx_wake_bit_function+0x10/0x10
[54231.156935]  evict+0xcc/0x1d0
[54231.157080]  inode_lru_isolate+0x14d/0x1e0
[54231.157261]  __list_lru_walk_one+0xbe/0x1c0
[54231.157448]  ? __pfx_inode_lru_isolate+0x10/0x10
[54231.157654]  ? __pfx_inode_lru_isolate+0x10/0x10
[54231.157856]  list_lru_walk_one+0x58/0x80
[54231.158036]  prune_icache_sb+0x39/0x60
[54231.158203]  super_cache_scan+0x161/0x1f0
[54231.158384]  do_shrink_slab+0x163/0x340
[54231.158557]  shrink_slab+0x1d7/0x2a0
[54231.158720]  shrink_node+0x2eb/0x7b0
[54231.158881]  balance_pgdat+0x344/0x780
[54231.159058]  kswapd+0x205/0x410
[54231.159203]  ? __pfx_autoremove_wake_function+0x10/0x10
[54231.159431]  ? __pfx_kswapd+0x10/0x10
[54231.159594]  kthread+0xfc/0x130
[54231.159739]  ? __pfx_kthread+0x10/0x10
[54231.159908]  ret_from_fork+0x2d/0x50
[54231.160071]  ? __pfx_kthread+0x10/0x10
[54231.160237]  ret_from_fork_asm+0x1b/0x30
[54231.160413] RIP: 0000:0x0
[54231.160551] Code: Unable to access opcode bytes at 0xffffffffffffffd6.
[54231.160828] RSP: 0000:0000000000000000 EFLAGS: 00000000 ORIG_RAX: 0000000000000000
[54231.161155] RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000000
[54231.161460] RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
[54231.161763] RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000
[54231.162070] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
[54231.162375] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
[54231.162684]  
[54448.231539] BTRFS warning (device dm-9): failed to trim 9 block group(s), last error -512
[54451.777767] BTRFS: device fsid b941fbc1-ea05-4637-8aca-36774a7f951a devid 1 transid 202 /dev/mapper/vg0-lv9 scanned by mount (3757943)
[54451.779432] BTRFS info (device dm-9): using crc32c (crc32c-intel) checksum algorithm
[54451.779713] BTRFS info (device dm-9): turning on sync discard
[54451.779935] BTRFS info (device dm-9): using free space tree