possible deadlock in mnt_want_write (9)

Status: upstream: reported C repro on 2026/08/05 08:12
Subsystems: overlayfs
Labels: prio:low
[Documentation on labels]
Reported-by: syzbot+da381387152f0dd8bedf@syzkaller.appspotmail.com
First crash: 10d, last: 6d01h
✨ AI Patch Versions (1)
Version Stage Reported Report Link Job
1 moderation 2026/08/05 12:22 Discussion 43881a07-9f58-4a9b-b110-6696a48ed088
✨ AI Jobs (2)
ID Workflow Result Correct Bug Created Started Finished Revision
43881a07 patching possible deadlock in mnt_want_write (9) 2026/08/05 08:19 2026/08/05 08:19 2026/08/05 12:22 52aa2820
13c50770 assessment-security DenialOfService: ✅ Exploitable: ❌ FilesystemTrigger: ❌ NetworkTrigger: ❌ PeripheralTrigger: ❌ RemoteTrigger: ❌ Unprivileged: ❌ UserNamespace: ❌ VMGuestTrigger: ❌ VMHostTrigger: ❌ possible deadlock in mnt_want_write (9) 2026/08/03 00:23 2026/08/03 00:23 2026/08/03 01:12 e611ffe1
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [overlayfs?] possible deadlock in mnt_want_write (9) 0 (1) 2026/08/05 08:12
Similar bugs (15)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream possible deadlock in mnt_want_write (8) ext4 4 syz, C 3 47d 64d 0/29 closed as dup on 2026/06/09 14:03
linux-6.6 possible deadlock in mnt_want_write 4 2 6d05h 10d 0/2 upstream: reported on 2026/08/01 11:19
linux-5.15 possible deadlock in mnt_want_write missing-backport 4 syz, C done 117 987d 1239d 0/3 auto-obsoleted due to no activity on 2024/10/15 12:27
upstream possible deadlock in mnt_want_write (6) kernfs 4 1 428d 424d 0/29 auto-obsoleted due to no activity on 2025/08/08 23:21
upstream possible deadlock in mnt_want_write fs 4 syz, C done done 662 2133d 2941d 15/29 fixed on 2020/11/16 12:12
upstream possible deadlock in mnt_want_write (5) kernfs 4 1 578d 574d 0/29 auto-obsoleted due to no activity on 2025/04/20 18:48
linux-5.15 possible deadlock in mnt_want_write (2) 4 4 1d06h 7d12h 0/3 upstream: reported on 2026/08/04 15:47
linux-6.1 possible deadlock in mnt_want_write origin:upstream missing-backport 4 syz, C done 56 988d 1232d 0/3 upstream: reported C repro on 2023/03/28 13:05
linux-4.19 possible deadlock in mnt_want_write romfs 4 syz, C 730 1253d 2671d 0/1 upstream: reported C repro on 2019/04/19 16:54
android-49 possible deadlock in mnt_want_write 4 1 2924d 2924d 0/3 auto-closed as invalid on 2019/02/22 14:57
upstream possible deadlock in mnt_want_write (4) kernfs 4 1 703d 699d 0/29 auto-obsoleted due to no activity on 2024/12/16 14:12
upstream possible deadlock in mnt_want_write (2) integrity overlayfs 4 syz, C done 867 1015d 1883d 25/29 fixed on 2023/12/21 01:43
upstream possible deadlock in mnt_want_write (3) kernfs 4 9 850d 953d 0/29 auto-obsoleted due to no activity on 2024/07/22 10:45
upstream possible deadlock in mnt_want_write (7) fs 4 3 222d 225d 0/29 auto-obsoleted due to no activity on 2026/04/11 06:22
linux-4.14 possible deadlock in mnt_want_write ubifs 4 syz, C 10467 1253d 2665d 0/1 upstream: reported C repro on 2019/04/25 05:09

Sample crash report:
Mass Storage Function, version: 2009/09/11
LUN: removable file: (no medium)
============================================
WARNING: possible recursive locking detected
syzkaller #0 Not tainted
--------------------------------------------
syz-executor262/5614 is trying to acquire lock:
ffff88801dfd2510 (sb_writers#8){.+.+}-{0:0}, at: mnt_want_write+0x41/0x90 fs/namespace.c:494

but task is already holding lock:
ffff88801dfd2510 (sb_writers#8){.+.+}-{0:0}, at: file_start_write include/linux/fs.h:2731 [inline]
ffff88801dfd2510 (sb_writers#8){.+.+}-{0:0}, at: vfs_write+0x231/0xbb0 fs/read_write.c:683

other info that might help us debug this:
 Possible unsafe locking scenario:

       CPU0
       ----
  lock(sb_writers#8);
  lock(sb_writers#8);

 *** DEADLOCK ***

 May be due to missing lock nesting notation

locks held by syz-executor262/5614: 4, last CPU#1:
 #0: ffff88801dfd2510 (sb_writers#8){.+.+}-{0:0}, at: file_start_write include/linux/fs.h:2731 [inline]
 #0: ffff88801dfd2510 (sb_writers#8){.+.+}-{0:0}, at: vfs_write+0x231/0xbb0 fs/read_write.c:683
 #1: ffff888028861a78 (&buffer->mutex){+.+.}-{4:4}, at: configfs_write_iter+0x81/0x430 fs/configfs/file.c:226
 #2: ffff888033abd068 (&p->frag_sem){.+.+}-{4:4}, at: flush_write_buffer fs/configfs/file.c:205 [inline]
 #2: ffff888033abd068 (&p->frag_sem){.+.+}-{4:4}, at: configfs_write_iter+0x23b/0x430 fs/configfs/file.c:229
 #3: ffff888038383998 (&common->filesem){+.+.}-{4:4}, at: fsg_store_file+0x163/0x400 drivers/usb/gadget/function/storage_common.c:452

stack backtrace:
CPU: 1 UID: 0 PID: 5614 Comm: syz-executor262 Not tainted syzkaller #0 PREEMPT_{RT,(full)} 
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/24/2026
Call Trace:
 <TASK>
 dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
 print_deadlock_bug+0x27a/0x290 kernel/locking/lockdep.c:3057
 check_deadlock kernel/locking/lockdep.c:3109 [inline]
 validate_chain kernel/locking/lockdep.c:3911 [inline]
 __lock_acquire+0x261c/0x2e40 kernel/locking/lockdep.c:5254
 lock_acquire+0x115/0x350 kernel/locking/lockdep.c:5906
 percpu_down_read_internal include/linux/percpu-rwsem.h:53 [inline]
 percpu_down_read_freezable include/linux/percpu-rwsem.h:83 [inline]
 __sb_start_write include/linux/fs/super.h:19 [inline]
 sb_start_write+0x4d/0x1c0 include/linux/fs/super.h:125
 mnt_want_write+0x41/0x90 fs/namespace.c:494
 open_last_lookups fs/namei.c:4591 [inline]
 path_openat+0xa7b/0x3850 fs/namei.c:4854
 do_file_open+0x23e/0x4a0 fs/namei.c:4886
 file_open_name fs/open.c:1326 [inline]
 filp_open+0x16d/0x1d0 fs/open.c:1343
 fsg_lun_open+0x6c/0xe00 drivers/usb/gadget/function/storage_common.c:194
 fsg_store_file+0x19e/0x400 drivers/usb/gadget/function/storage_common.c:455
 flush_write_buffer fs/configfs/file.c:207 [inline]
 configfs_write_iter+0x33a/0x430 fs/configfs/file.c:229
 new_sync_write fs/read_write.c:595 [inline]
 vfs_write+0x61e/0xbb0 fs/read_write.c:687
 ksys_write+0x156/0x270 fs/read_write.c:739
 do_syscall_x64 arch/x86/entry/syscall_64.c:61 [inline]
 do_syscall_64+0x17b/0x530 arch/x86/entry/syscall_64.c:85
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f79667de649
Code: c0 79 93 eb d5 48 8d 7c 1d 00 eb 99 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 d8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffe39c70488 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 0000200000000100 RCX: 00007f79667de649
RDX: 0000000000000002 RSI: 0000200000000f00 RDI: 0000000000000003
RBP: 69666e6f635f796d R08: 0000000000000006 R09: 0000000000000006
R10: 0000000000000006 R11: 0000000000000246 R12: 00007ffe39c705f8
R13: 0000200000000108 R14: 00007f7966871c40 R15: 0000000000000002
 </TASK>
mass_storage.usb0/lun.0: unable to open backing file: fi

Crashes (5):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/08/02 10:51 linux-next cc2b5f627e8c e611ffe1 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci-upstream-rust-kasan-gce possible deadlock in mnt_want_write
2026/08/06 02:28 upstream 0d8395707651 cd5b1963 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root possible deadlock in mnt_want_write
2026/08/02 22:25 upstream bd1dde877520 e611ffe1 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root possible deadlock in mnt_want_write
2026/08/02 12:13 upstream 2d2338c93da7 e611ffe1 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root possible deadlock in mnt_want_write
2026/08/01 08:06 upstream 0131b508c0e2 e611ffe1 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root possible deadlock in mnt_want_write
* Struck through repros no longer work on HEAD.