[11743.705538] run fstests generic/251 at 2023-08-03 00:07:54
[11744.132934] BTRFS: device fsid 442e5b9d-ccad-458f-8dc7-acd1904d321e devid 1 transid 1377631 /dev/mapper/vg0-lv0 scanned by mount (1546328)
[11744.134207] BTRFS info (device dm-0): using crc32c (crc32c-intel) checksum algorithm
[11744.134214] BTRFS info (device dm-0): using free space tree
[11744.138536] BTRFS info (device dm-0): auto enabling async discard
[11744.385111] BTRFS: device fsid 720d5767-6e1e-4f14-8e13-6d0bae27e0e1 devid 1 transid 6 /dev/mapper/vg0-lv7 scanned by mkfs.btrfs (1546376)
[11744.408936] BTRFS info (device dm-7): using crc32c (crc32c-intel) checksum algorithm
[11744.408946] BTRFS info (device dm-7): using free space tree
[11744.431720] BTRFS info (device dm-7): auto enabling async discard
[11744.431863] BTRFS info (device dm-7): checking UUID tree

[12355.662999] ======================================================
[12355.663229] WARNING: possible circular locking dependency detected
[12355.663515] 6.5.0-rc3+ #1259 Not tainted
[12355.663704] ------------------------------------------------------
[12355.663931] kswapd0/47 is trying to acquire lock:
[12355.664167] ffff8be3aaf02378 (btrfs_trans_num_writers){++++}-{0:0}, at: join_transaction+0x1af/0x590
[12355.664629] 
               but task is already holding lock:
[12355.664881] ffff8be396c3b600 (sb_internal){++++}-{0:0}, at: btrfs_commit_inode_delayed_inode+0x5f/0x120
[12355.665205] 
               which lock already depends on the new lock.

[12355.665546] 
               the existing dependency chain (in reverse order) is:
[12355.665828] 
               -> #3 (sb_internal){++++}-{0:0}:
[12355.666077]        start_transaction+0x3f9/0x740
[12355.666257]        btrfs_commit_inode_delayed_inode+0x5f/0x120
[12355.666500]        btrfs_evict_inode+0x273/0x3c0
[12355.666915]        evict+0xcc/0x1d0
[12355.667082]        inode_lru_isolate+0x14d/0x1e0
[12355.667264]        __list_lru_walk_one+0xbe/0x1c0
[12355.667449]        list_lru_walk_one+0x58/0x80
[12355.667628]        prune_icache_sb+0x39/0x60
[12355.667816]        super_cache_scan+0x161/0x1f0
[12355.667994]        do_shrink_slab+0x163/0x340
[12355.668173]        shrink_slab+0x1d7/0x2a0
[12355.668347]        shrink_node+0x2eb/0x7b0
[12355.668522]        balance_pgdat+0x344/0x780
[12355.668702]        kswapd+0x205/0x410
[12355.668864]        kthread+0xfc/0x130
[12355.669031]        ret_from_fork+0x2d/0x50
[12355.669201]        ret_from_fork_asm+0x1b/0x30
[12355.669514] 
               -> #2 (fs_reclaim){+.+.}-{0:0}:
[12355.669770]        fs_reclaim_acquire+0xa5/0xe0
[12355.669955]        kmem_cache_alloc_lru+0x4e/0x570
[12355.670140]        btrfs_alloc_inode+0x2d/0x250
[12355.670325]        alloc_inode+0x1a/0xc0
[12355.670498]        iget5_locked+0xba/0x110
[12355.670675]        btrfs_iget+0x43/0xe0
[12355.670853]        create_reloc_inode+0x19d/0x370
[12355.671040]        btrfs_relocate_block_group+0x1b7/0x410
[12355.671241]        btrfs_relocate_chunk+0x4c/0x1b0
[12355.671426]        btrfs_balance+0x8e7/0x11d0
[12355.671604]        btrfs_ioctl+0x1d3d/0x2900
[12355.671932]        __x64_sys_ioctl+0x8b/0xc0
[12355.672114]        do_syscall_64+0x38/0x90
[12355.672286]        entry_SYSCALL_64_after_hwframe+0x6e/0xd8
[12355.672484] 
               -> #1 (btrfs_trans_num_extwriters){++++}-{0:0}:
[12355.672763]        join_transaction+0xb4/0x590
[12355.672939]        start_transaction+0x187/0x740
[12355.673122]        btrfs_dirty_inode+0x40/0xd0
[12355.673308]        touch_atime+0x15b/0x280
[12355.673486]        iterate_dir+0x129/0x200
[12355.673656]        __x64_sys_getdents64+0x6a/0x120
[12355.673869]        do_syscall_64+0x38/0x90
[12355.674043]        entry_SYSCALL_64_after_hwframe+0x6e/0xd8
[12355.674246] 
               -> #0 (btrfs_trans_num_writers){++++}-{0:0}:
[12355.674646]        __lock_acquire+0x1415/0x2190
[12355.674834]        lock_acquire+0xc7/0x2b0
[12355.675011]        join_transaction+0x1de/0x590
[12355.675188]        start_transaction+0x187/0x740
[12355.675377]        btrfs_commit_inode_delayed_inode+0x5f/0x120
[12355.675586]        btrfs_evict_inode+0x273/0x3c0
[12355.675776]        evict+0xcc/0x1d0
[12355.675937]        inode_lru_isolate+0x14d/0x1e0
[12355.676120]        __list_lru_walk_one+0xbe/0x1c0
[12355.676307]        list_lru_walk_one+0x58/0x80
[12355.676489]        prune_icache_sb+0x39/0x60
[12355.676663]        super_cache_scan+0x161/0x1f0
[12355.676969]        do_shrink_slab+0x163/0x340
[12355.677158]        shrink_slab+0x1d7/0x2a0
[12355.677334]        shrink_node+0x2eb/0x7b0
[12355.677534]        balance_pgdat+0x344/0x780
[12355.677718]        kswapd+0x205/0x410
[12355.677887]        kthread+0xfc/0x130
[12355.678055]        ret_from_fork+0x2d/0x50
[12355.678229]        ret_from_fork_asm+0x1b/0x30
[12355.678411] 
               other info that might help us debug this:

[12355.678742] Chain exists of:
                 btrfs_trans_num_writers --> fs_reclaim --> sb_internal

[12355.679129]  Possible unsafe locking scenario:

[12355.679524]        CPU0                    CPU1
[12355.679708]        ----                    ----
[12355.679887]   rlock(sb_internal);
[12355.680046]                                lock(fs_reclaim);
[12355.680249]                                lock(sb_internal);
[12355.680450]   rlock(btrfs_trans_num_writers);
[12355.680629] 
                *** DEADLOCK ***

[12355.680923] 4 locks held by kswapd0/47:
[12355.681089]  #0: ffffffffb5e62280 (fs_reclaim){+.+.}-{0:0}, at: balance_pgdat+0x492/0x780
[12355.681387]  #1: ffffffffb5e507d0 (shrinker_rwsem){++++}-{3:3}, at: shrink_slab+0x113/0x2a0
[12355.681697]  #2: ffff8be396c3b0e0 (&type->s_umount_key#35){++++}-{3:3}, at: super_cache_scan+0x38/0x1f0
[12355.682183]  #3: ffff8be396c3b600 (sb_internal){++++}-{0:0}, at: btrfs_commit_inode_delayed_inode+0x5f/0x120
[12355.682518] 
               stack backtrace:
[12355.682742] CPU: 1 PID: 47 Comm: kswapd0 Not tainted 6.5.0-rc3+ #1259
[12355.682959] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.13.0-2.fc32 04/01/2014
[12355.683258] Call Trace:
[12355.683406]  
[12355.683544]  dump_stack_lvl+0x58/0x90
[12355.683724]  check_noncircular+0x101/0x110
[12355.683905]  __lock_acquire+0x1415/0x2190
[12355.684079]  lock_acquire+0xc7/0x2b0
[12355.684242]  ? join_transaction+0x1af/0x590
[12355.685777]  ? lock_release+0x134/0x270
[12355.686169]  join_transaction+0x1de/0x590
[12355.686345]  ? join_transaction+0x1af/0x590
[12355.686582]  start_transaction+0x187/0x740
[12355.686766]  btrfs_commit_inode_delayed_inode+0x5f/0x120
[12355.686999]  btrfs_evict_inode+0x273/0x3c0
[12355.687174]  ? lock_release+0x134/0x270
[12355.687342]  ? __pfx_wake_bit_function+0x10/0x10
[12355.687530]  evict+0xcc/0x1d0
[12355.687690]  inode_lru_isolate+0x14d/0x1e0
[12355.687862]  __list_lru_walk_one+0xbe/0x1c0
[12355.688035]  ? __pfx_inode_lru_isolate+0x10/0x10
[12355.688223]  ? __pfx_inode_lru_isolate+0x10/0x10
[12355.688410]  list_lru_walk_one+0x58/0x80
[12355.688580]  prune_icache_sb+0x39/0x60
[12355.688762]  super_cache_scan+0x161/0x1f0
[12355.688938]  do_shrink_slab+0x163/0x340
[12355.689106]  ? lock_is_held_type+0xe2/0x140
[12355.689281]  shrink_slab+0x1d7/0x2a0
[12355.689453]  shrink_node+0x2eb/0x7b0
[12355.689621]  balance_pgdat+0x344/0x780
[12355.689796]  kswapd+0x205/0x410
[12355.689951]  ? __pfx_autoremove_wake_function+0x10/0x10
[12355.690148]  ? __pfx_kswapd+0x10/0x10
[12355.690327]  kthread+0xfc/0x130
[12355.690484]  ? __pfx_kthread+0x10/0x10
[12355.690655]  ret_from_fork+0x2d/0x50
[12355.690831]  ? __pfx_kthread+0x10/0x10
[12355.690999]  ret_from_fork_asm+0x1b/0x30
[12355.691175] RIP: 0000:0x0
[12355.691333] Code: Unable to access opcode bytes at 0xffffffffffffffd6.
[12355.691553] RSP: 0000:0000000000000000 EFLAGS: 00000000 ORIG_RAX: 0000000000000000
[12355.691838] RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000000
[12355.692071] RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
[12355.692307] RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000
[12355.692539] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
[12355.692772] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
[12355.693003]  
[12604.486995] BTRFS: device fsid 720d5767-6e1e-4f14-8e13-6d0bae27e0e1 devid 1 transid 85 /dev/mapper/vg0-lv7 scanned by mount (1554635)
[12604.489281] BTRFS info (device dm-7): using crc32c (crc32c-intel) checksum algorithm
[12604.489572] BTRFS info (device dm-7): using free space tree
[12604.494164] BTRFS info (device dm-7): auto enabling async discard