====================================================== WARNING: possible circular locking dependency detected 5.15.111-syzkaller #0 Not tainted ------------------------------------------------------ syz-executor.1/16970 is trying to acquire lock: ffff0000d45ac0e0 (&type->s_umount_key#30){++++}-{3:3}, at: __do_sys_quotactl_fd fs/quota/quota.c:998 [inline] ffff0000d45ac0e0 (&type->s_umount_key#30){++++}-{3:3}, at: __se_sys_quotactl_fd fs/quota/quota.c:971 [inline] ffff0000d45ac0e0 (&type->s_umount_key#30){++++}-{3:3}, at: __arm64_sys_quotactl_fd+0x30c/0x4a4 fs/quota/quota.c:971 but task is already holding lock: ffff0000d45ac460 (sb_writers#3){.+.+}-{0:0}, at: mnt_want_write+0x44/0x9c fs/namespace.c:377 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #1 (sb_writers#3){.+.+}-{0:0}: percpu_down_read include/linux/percpu-rwsem.h:51 [inline] __sb_start_write include/linux/fs.h:1742 [inline] sb_start_write include/linux/fs.h:1812 [inline] write_mmp_block+0x170/0xd18 fs/ext4/mmp.c:50 ext4_multi_mount_protect+0x2e0/0x894 fs/ext4/mmp.c:351 ext4_remount+0x1fc8/0x2710 fs/ext4/super.c:5951 legacy_reconfigure+0xfc/0x114 fs/fs_context.c:633 reconfigure_super+0x340/0x690 fs/super.c:916 vfs_fsconfig_locked fs/fsopen.c:254 [inline] __do_sys_fsconfig fs/fsopen.c:439 [inline] __se_sys_fsconfig fs/fsopen.c:314 [inline] __arm64_sys_fsconfig+0xa1c/0xd18 fs/fsopen.c:314 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142 do_el0_svc+0x58/0x14c arch/arm64/kernel/syscall.c:181 el0_svc+0x7c/0x1f0 arch/arm64/kernel/entry-common.c:596 el0t_64_sync_handler+0x84/0xe4 arch/arm64/kernel/entry-common.c:614 el0t_64_sync+0x1a0/0x1a4 arch/arm64/kernel/entry.S:584 -> #0 (&type->s_umount_key#30){++++}-{3:3}: check_prev_add kernel/locking/lockdep.c:3053 [inline] check_prevs_add kernel/locking/lockdep.c:3172 [inline] validate_chain kernel/locking/lockdep.c:3787 [inline] __lock_acquire+0x32cc/0x7620 kernel/locking/lockdep.c:5011 lock_acquire+0x240/0x77c kernel/locking/lockdep.c:5622 down_read+0xbc/0x11c kernel/locking/rwsem.c:1488 __do_sys_quotactl_fd fs/quota/quota.c:998 [inline] __se_sys_quotactl_fd fs/quota/quota.c:971 [inline] __arm64_sys_quotactl_fd+0x30c/0x4a4 fs/quota/quota.c:971 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142 do_el0_svc+0x58/0x14c arch/arm64/kernel/syscall.c:181 el0_svc+0x7c/0x1f0 arch/arm64/kernel/entry-common.c:596 el0t_64_sync_handler+0x84/0xe4 arch/arm64/kernel/entry-common.c:614 el0t_64_sync+0x1a0/0x1a4 arch/arm64/kernel/entry.S:584 other info that might help us debug this: Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(sb_writers#3); lock(&type->s_umount_key#30); lock(sb_writers#3); lock(&type->s_umount_key#30); *** DEADLOCK *** 1 lock held by syz-executor.1/16970: #0: ffff0000d45ac460 (sb_writers#3){.+.+}-{0:0}, at: mnt_want_write+0x44/0x9c fs/namespace.c:377 stack backtrace: CPU: 1 PID: 16970 Comm: syz-executor.1 Not tainted 5.15.111-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/14/2023 Call trace: dump_backtrace+0x0/0x530 arch/arm64/kernel/stacktrace.c:152 show_stack+0x2c/0x3c arch/arm64/kernel/stacktrace.c:216 __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x108/0x170 lib/dump_stack.c:106 dump_stack+0x1c/0x58 lib/dump_stack.c:113 print_circular_bug+0x150/0x1b8 kernel/locking/lockdep.c:2011 check_noncircular+0x2cc/0x378 kernel/locking/lockdep.c:2133 check_prev_add kernel/locking/lockdep.c:3053 [inline] check_prevs_add kernel/locking/lockdep.c:3172 [inline] validate_chain kernel/locking/lockdep.c:3787 [inline] __lock_acquire+0x32cc/0x7620 kernel/locking/lockdep.c:5011 lock_acquire+0x240/0x77c kernel/locking/lockdep.c:5622 down_read+0xbc/0x11c kernel/locking/rwsem.c:1488 __do_sys_quotactl_fd fs/quota/quota.c:998 [inline] __se_sys_quotactl_fd fs/quota/quota.c:971 [inline] __arm64_sys_quotactl_fd+0x30c/0x4a4 fs/quota/quota.c:971 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline] invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:52 el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142 do_el0_svc+0x58/0x14c arch/arm64/kernel/syscall.c:181 el0_svc+0x7c/0x1f0 arch/arm64/kernel/entry-common.c:596 el0t_64_sync_handler+0x84/0xe4 arch/arm64/kernel/entry-common.c:614 el0t_64_sync+0x1a0/0x1a4 arch/arm64/kernel/entry.S:584