Hello, syzbot has tested the proposed patch but the reproducer is still triggering an issue: BUG: MAX_LOCKDEP_KEYS too low! BUG: MAX_LOCKDEP_KEYS too low! turning off the locking correctness validator. CPU: 1 UID: 0 PID: 18394 Comm: syz-executor388 Not tainted 6.12.0-rc7-syzkaller-00133-g17a4e91a431b #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 Call Trace: <TASK> __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120 register_lock_class+0x827/0x980 kernel/locking/lockdep.c:1328 __lock_acquire+0xf3/0x2100 kernel/locking/lockdep.c:5077 lock_acquire+0x1ed/0x550 kernel/locking/lockdep.c:5825 touch_wq_lockdep_map+0xc7/0x170 kernel/workqueue.c:3880 __flush_workqueue+0x14f/0x1600 kernel/workqueue.c:3922 drain_workqueue+0xc9/0x3a0 kernel/workqueue.c:4086 destroy_workqueue+0xba/0xc40 kernel/workqueue.c:5830 btrfs_stop_all_workers+0xbb/0x2a0 fs/btrfs/disk-io.c:1782 close_ctree+0x6bb/0xd60 fs/btrfs/disk-io.c:4360 generic_shutdown_super+0x139/0x2d0 fs/super.c:642 kill_anon_super+0x3b/0x70 fs/super.c:1237 btrfs_kill_super+0x41/0x50 fs/btrfs/super.c:2112 deactivate_locked_super+0xc4/0x130 fs/super.c:473 cleanup_mnt+0x41f/0x4b0 fs/namespace.c:1373 task_work_run+0x24f/0x310 kernel/task_work.c:239 resume_user_mode_work include/linux/resume_user_mode.h:50 [inline] exit_to_user_mode_loop kernel/entry/common.c:114 [inline] exit_to_user_mode_prepare include/linux/entry-common.h:328 [inline] __syscall_exit_to_user_mode_work kernel/entry/common.c:207 [inline] syscall_exit_to_user_mode+0x168/0x370 kernel/entry/common.c:218 do_syscall_64+0x100/0x230 arch/x86/entry/common.c:89 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f378bf8c357 Code: 08 00 48 83 c4 08 5b 5d c3 66 2e 0f 1f 84 00 00 00 00 00 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 b8 a6 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 01 c3 48 c7 c2 b0 ff ff ff f7 d8 64 89 02 b8 RSP: 002b:00007ffd4c441108 EFLAGS: 00000202 ORIG_RAX: 00000000000000a6 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 00007f378bf8c357 RDX: 0000000000000000 RSI: 0000000000000009 RDI: 00007ffd4c4411c0 RBP: 00007ffd4c4411c0 R08: 0000000000000000 R09: 0000000000000000 R10: 00000000ffffffff R11: 0000000000000202 R12: 00007ffd4c442280 R13: 00005555591197d0 R14: 431bde82d7b634db R15: 00007ffd4c442224 </TASK> BTRFS info (device loop2): last unmount of filesystem bf719321-eb1f-43c1-9145-be0044cdbc04 BTRFS info (device loop2): last unmount of filesystem 454c899b-20f1-4098-b6bd-9b424eb38c60 BTRFS info (device loop2): last unmount of filesystem e789dab4-7b2e-44bb-bb97-19a8dd7be099 BTRFS info (device loop2): last unmount of filesystem a11fd0de-3a92-4478-af85-4e70dfb2fb44 BTRFS info (device loop2): last unmount of filesystem 85ccfa0b-566f-4eb9-b1a6-ea2fe97ca044 BTRFS info (device loop2): last unmount of filesystem 5a8c012e-dba3-4ff5-a22f-46e4b5bb2f55 BTRFS info (device loop2): last unmount of filesystem 2fe685f2-8834-419b-bd91-466d40ccece7 BTRFS info (device loop2): last unmount of filesystem fc366aaa-c1c0-4d55-9034-d39fce006f22 BTRFS info (device loop2): last unmount of filesystem 364312bb-b5a2-487f-aaa2-e36f3a1b701f BTRFS info (device loop2): last unmount of filesystem 14d642db-7b15-43e4-81e6-4b8fac6a25f8 Tested on: commit: 17a4e91a btrfs: test if we need to wait the writeback .. git tree: https://github.com/adam900710/linux.git writeback_fix console output: https://syzkaller.appspot.com/x/log.txt?x=1501b9e8580000 kernel config: https://syzkaller.appspot.com/x/.config?x=fa4954ad2c62b915 dashboard link: https://syzkaller.appspot.com/bug?extid=aac7bff85be224de5156 compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40 Note: no patches were applied.