syzbot


possible deadlock in jfs_commit_inode

Status: upstream: reported on 2026/04/02 05:31
Subsystems: jfs
[Documentation on labels]
Reported-by: syzbot+8f2651aaae7c1281c2a7@syzkaller.appspotmail.com
First crash: 24d, last: 13h20m
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [jfs?] possible deadlock in jfs_commit_inode 0 (1) 2026/04/02 05:31

Sample crash report:
======================================================
WARNING: possible circular locking dependency detected
syzkaller #0 Not tainted
------------------------------------------------------
syz-executor/5821 is trying to acquire lock:
ffff8880643c9ee0 (&jfs_ip->commit_mutex){+.+.}-{4:4}, at: jfs_commit_inode+0x1ca/0x530 fs/jfs/inode.c:108

but task is already holding lock:
ffff88803f1cf150 (&(log)->loglock){+.+.}-{4:4}, at: jfs_umount+0x17f/0x3d0 fs/jfs/jfs_umount.c:66

which lock already depends on the new lock.


the existing dependency chain (in reverse order) is:

-> #1 (&(log)->loglock){+.+.}-{4:4}:
       __mutex_lock_common kernel/locking/rtmutex_api.c:534 [inline]
       mutex_lock_nested+0x5a/0x1d0 kernel/locking/rtmutex_api.c:553
       lmLog+0x78/0xa30 fs/jfs/jfs_logmgr.c:234
       diLog fs/jfs/jfs_txnmgr.c:1454 [inline]
       txLog fs/jfs/jfs_txnmgr.c:1406 [inline]
       txCommit+0x16fb/0x5410 fs/jfs/jfs_txnmgr.c:1266
       jfs_commit_inode+0x2ef/0x530 fs/jfs/inode.c:114
       jfs_write_inode+0x145/0x220 fs/jfs/inode.c:138
       write_inode fs/fs-writeback.c:1582 [inline]
       __writeback_single_inode+0x75d/0x10e0 fs/fs-writeback.c:1825
       writeback_sb_inodes+0x97f/0x1980 fs/fs-writeback.c:2054
       wb_writeback+0x445/0xb00 fs/fs-writeback.c:2239
       wb_do_writeback fs/fs-writeback.c:2386 [inline]
       wb_workfn+0x3fd/0xf20 fs/fs-writeback.c:2426
       process_one_work kernel/workqueue.c:3302 [inline]
       process_scheduled_works+0xb5d/0x1860 kernel/workqueue.c:3385
       worker_thread+0xa53/0xfc0 kernel/workqueue.c:3466
       kthread+0x388/0x470 kernel/kthread.c:436
       ret_from_fork+0x514/0xb70 arch/x86/kernel/process.c:158
       ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245

-> #0 (&jfs_ip->commit_mutex){+.+.}-{4:4}:
       check_prev_add kernel/locking/lockdep.c:3165 [inline]
       check_prevs_add kernel/locking/lockdep.c:3284 [inline]
       validate_chain kernel/locking/lockdep.c:3908 [inline]
       __lock_acquire+0x15a5/0x2cf0 kernel/locking/lockdep.c:5237
       lock_acquire+0x106/0x350 kernel/locking/lockdep.c:5868
       __mutex_lock_common kernel/locking/rtmutex_api.c:534 [inline]
       mutex_lock_nested+0x5a/0x1d0 kernel/locking/rtmutex_api.c:553
       jfs_commit_inode+0x1ca/0x530 fs/jfs/inode.c:108
       jfs_write_inode+0x145/0x220 fs/jfs/inode.c:138
       write_inode fs/fs-writeback.c:1582 [inline]
       __writeback_single_inode+0x75d/0x10e0 fs/fs-writeback.c:1825
       writeback_single_inode+0x488/0xd60 fs/fs-writeback.c:1881
       write_inode_now+0x1c2/0x290 fs/fs-writeback.c:2972
       iput_final fs/inode.c:1950 [inline]
       iput+0x8c1/0xe80 fs/inode.c:2009
       jfs_umount+0x198/0x3d0 fs/jfs/jfs_umount.c:72
       jfs_put_super+0x8c/0x190 fs/jfs/super.c:194
       generic_shutdown_super+0x13d/0x2d0 fs/super.c:646
       kill_block_super+0x44/0x90 fs/super.c:1725
       deactivate_locked_super+0xbc/0x130 fs/super.c:476
       cleanup_mnt+0x437/0x4d0 fs/namespace.c:1312
       task_work_run+0x1d9/0x270 kernel/task_work.c:233
       resume_user_mode_work include/linux/resume_user_mode.h:50 [inline]
       __exit_to_user_mode_loop kernel/entry/common.c:67 [inline]
       exit_to_user_mode_loop+0xed/0x480 kernel/entry/common.c:98
       __exit_to_user_mode_prepare include/linux/irq-entry-common.h:207 [inline]
       syscall_exit_to_user_mode_prepare include/linux/irq-entry-common.h:238 [inline]
       syscall_exit_to_user_mode include/linux/entry-common.h:318 [inline]
       do_syscall_64+0x33e/0xf80 arch/x86/entry/syscall_64.c:100
       entry_SYSCALL_64_after_hwframe+0x77/0x7f

other info that might help us debug this:

 Possible unsafe locking scenario:

       CPU0                    CPU1
       ----                    ----
  lock(&(log)->loglock);
                               lock(&jfs_ip->commit_mutex);
                               lock(&(log)->loglock);
  lock(&jfs_ip->commit_mutex);

 *** DEADLOCK ***

2 locks held by syz-executor/5821:
 #0: ffff88802a63a0d0 (&type->s_umount_key#74){++++}-{4:4}, at: __super_lock fs/super.c:58 [inline]
 #0: ffff88802a63a0d0 (&type->s_umount_key#74){++++}-{4:4}, at: __super_lock_excl fs/super.c:73 [inline]
 #0: ffff88802a63a0d0 (&type->s_umount_key#74){++++}-{4:4}, at: deactivate_super+0xa9/0xe0 fs/super.c:508
 #1: ffff88803f1cf150 (&(log)->loglock){+.+.}-{4:4}, at: jfs_umount+0x17f/0x3d0 fs/jfs/jfs_umount.c:66

stack backtrace:
CPU: 1 UID: 0 PID: 5821 Comm: syz-executor Not tainted syzkaller #0 PREEMPT_{RT,(full)} 
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/18/2026
Call Trace:
 <TASK>
 dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
 print_circular_bug+0x2e1/0x300 kernel/locking/lockdep.c:2043
 check_noncircular+0x12e/0x150 kernel/locking/lockdep.c:2175
 check_prev_add kernel/locking/lockdep.c:3165 [inline]
 check_prevs_add kernel/locking/lockdep.c:3284 [inline]
 validate_chain kernel/locking/lockdep.c:3908 [inline]
 __lock_acquire+0x15a5/0x2cf0 kernel/locking/lockdep.c:5237
 lock_acquire+0x106/0x350 kernel/locking/lockdep.c:5868
 __mutex_lock_common kernel/locking/rtmutex_api.c:534 [inline]
 mutex_lock_nested+0x5a/0x1d0 kernel/locking/rtmutex_api.c:553
 jfs_commit_inode+0x1ca/0x530 fs/jfs/inode.c:108
 jfs_write_inode+0x145/0x220 fs/jfs/inode.c:138
 write_inode fs/fs-writeback.c:1582 [inline]
 __writeback_single_inode+0x75d/0x10e0 fs/fs-writeback.c:1825
 writeback_single_inode+0x488/0xd60 fs/fs-writeback.c:1881
 write_inode_now+0x1c2/0x290 fs/fs-writeback.c:2972
 iput_final fs/inode.c:1950 [inline]
 iput+0x8c1/0xe80 fs/inode.c:2009
 jfs_umount+0x198/0x3d0 fs/jfs/jfs_umount.c:72
 jfs_put_super+0x8c/0x190 fs/jfs/super.c:194
 generic_shutdown_super+0x13d/0x2d0 fs/super.c:646
 kill_block_super+0x44/0x90 fs/super.c:1725
 deactivate_locked_super+0xbc/0x130 fs/super.c:476
 cleanup_mnt+0x437/0x4d0 fs/namespace.c:1312
 task_work_run+0x1d9/0x270 kernel/task_work.c:233
 resume_user_mode_work include/linux/resume_user_mode.h:50 [inline]
 __exit_to_user_mode_loop kernel/entry/common.c:67 [inline]
 exit_to_user_mode_loop+0xed/0x480 kernel/entry/common.c:98
 __exit_to_user_mode_prepare include/linux/irq-entry-common.h:207 [inline]
 syscall_exit_to_user_mode_prepare include/linux/irq-entry-common.h:238 [inline]
 syscall_exit_to_user_mode include/linux/entry-common.h:318 [inline]
 do_syscall_64+0x33e/0xf80 arch/x86/entry/syscall_64.c:100
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fefa143da57
Code: a2 c7 05 9c fc 24 00 00 00 00 00 eb 96 e8 e1 12 00 00 90 31 f6 e9 09 00 00 00 66 0f 1f 84 00 00 00 00 00 b8 a6 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 01 c3 48 c7 c2 e8 ff ff ff f7 d8 64 89 02 b8
RSP: 002b:00007fffb78bcd48 EFLAGS: 00000246 ORIG_RAX: 00000000000000a6
RAX: 0000000000000000 RBX: 00007fefa14d2048 RCX: 00007fefa143da57
RDX: 0000000000000000 RSI: 0000000000000009 RDI: 00007fffb78bce00
RBP: 00007fffb78bce00 R08: 00007fffb78bde00 R09: 00000000ffffffff
R10: 0000000000000000 R11: 0000000000000246 R12: 00007fffb78bde90
R13: 00007fefa14d2048 R14: 0000000000046bfa R15: 00007fffb78bded0
 </TASK>
------------[ cut here ]------------
rtmutex deadlock detected
WARNING: kernel/locking/rtmutex.c:1687 at rt_mutex_handle_deadlock+0x21/0xb0 kernel/locking/rtmutex.c:1687, CPU#1: syz-executor/5821
Modules linked in:
CPU: 1 UID: 0 PID: 5821 Comm: syz-executor Not tainted syzkaller #0 PREEMPT_{RT,(full)} 
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/18/2026
RIP: 0010:rt_mutex_handle_deadlock+0x21/0xb0 kernel/locking/rtmutex.c:1687
Code: 90 90 90 90 90 90 90 90 90 41 57 41 56 41 55 41 54 53 83 ff dd 0f 85 81 00 00 00 48 89 f7 e8 d6 3a 01 00 48 8d 3d ff e1 5f 04 <67> 48 0f b9 3a 4c 8d 3d 00 00 00 00 65 48 8b 1d 43 2e 43 07 4c 8d
RSP: 0018:ffffc90004a67390 EFLAGS: 00010286
RAX: 0000000080000000 RBX: ffffc90004a67420 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffffffff8ba74040 RDI: ffffffff8f8f03b0
RBP: ffffc90004a67528 R08: ffffffff8f8bcef7 R09: 1ffffffff1f179de
R10: dffffc0000000000 R11: fffffbfff1f179df R12: 1ffff9200094ce80
R13: ffffffff8b2f1bfd R14: ffff88803f1cf0f8 R15: dffffc0000000000
FS:  000055557e8c0500(0000) GS:ffff8881261fb000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f0e202c4000 CR3: 0000000034ab6000 CR4: 00000000003526f0
Call Trace:
 <TASK>
 __rt_mutex_slowlock kernel/locking/rtmutex.c:1749 [inline]
 __rt_mutex_slowlock_locked kernel/locking/rtmutex.c:1776 [inline]
 rt_mutex_slowlock+0x73a/0x780 kernel/locking/rtmutex.c:1816
 __rt_mutex_lock kernel/locking/rtmutex.c:1831 [inline]
 __mutex_lock_common kernel/locking/rtmutex_api.c:535 [inline]
 mutex_lock_nested+0x168/0x1d0 kernel/locking/rtmutex_api.c:553
 lmLog+0x78/0xa30 fs/jfs/jfs_logmgr.c:234
 diLog fs/jfs/jfs_txnmgr.c:1454 [inline]
 txLog fs/jfs/jfs_txnmgr.c:1406 [inline]
 txCommit+0x16fb/0x5410 fs/jfs/jfs_txnmgr.c:1266
 jfs_commit_inode+0x2ef/0x530 fs/jfs/inode.c:114
 jfs_write_inode+0x145/0x220 fs/jfs/inode.c:138
 write_inode fs/fs-writeback.c:1582 [inline]
 __writeback_single_inode+0x75d/0x10e0 fs/fs-writeback.c:1825
 writeback_single_inode+0x488/0xd60 fs/fs-writeback.c:1881
 write_inode_now+0x1c2/0x290 fs/fs-writeback.c:2972
 iput_final fs/inode.c:1950 [inline]
 iput+0x8c1/0xe80 fs/inode.c:2009
 jfs_umount+0x198/0x3d0 fs/jfs/jfs_umount.c:72
 jfs_put_super+0x8c/0x190 fs/jfs/super.c:194
 generic_shutdown_super+0x13d/0x2d0 fs/super.c:646
 kill_block_super+0x44/0x90 fs/super.c:1725
 deactivate_locked_super+0xbc/0x130 fs/super.c:476
 cleanup_mnt+0x437/0x4d0 fs/namespace.c:1312
 task_work_run+0x1d9/0x270 kernel/task_work.c:233
 resume_user_mode_work include/linux/resume_user_mode.h:50 [inline]
 __exit_to_user_mode_loop kernel/entry/common.c:67 [inline]
 exit_to_user_mode_loop+0xed/0x480 kernel/entry/common.c:98
 __exit_to_user_mode_prepare include/linux/irq-entry-common.h:207 [inline]
 syscall_exit_to_user_mode_prepare include/linux/irq-entry-common.h:238 [inline]
 syscall_exit_to_user_mode include/linux/entry-common.h:318 [inline]
 do_syscall_64+0x33e/0xf80 arch/x86/entry/syscall_64.c:100
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fefa143da57
Code: a2 c7 05 9c fc 24 00 00 00 00 00 eb 96 e8 e1 12 00 00 90 31 f6 e9 09 00 00 00 66 0f 1f 84 00 00 00 00 00 b8 a6 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 01 c3 48 c7 c2 e8 ff ff ff f7 d8 64 89 02 b8
RSP: 002b:00007fffb78bcd48 EFLAGS: 00000246 ORIG_RAX: 00000000000000a6
RAX: 0000000000000000 RBX: 00007fefa14d2048 RCX: 00007fefa143da57
RDX: 0000000000000000 RSI: 0000000000000009 RDI: 00007fffb78bce00
RBP: 00007fffb78bce00 R08: 00007fffb78bde00 R09: 00000000ffffffff
R10: 0000000000000000 R11: 0000000000000246 R12: 00007fffb78bde90
R13: 00007fefa14d2048 R14: 0000000000046bfa R15: 00007fffb78bded0
 </TASK>
----------------
Code disassembly (best guess):
   0:	90                   	nop
   1:	90                   	nop
   2:	90                   	nop
   3:	90                   	nop
   4:	90                   	nop
   5:	90                   	nop
   6:	90                   	nop
   7:	90                   	nop
   8:	90                   	nop
   9:	41 57                	push   %r15
   b:	41 56                	push   %r14
   d:	41 55                	push   %r13
   f:	41 54                	push   %r12
  11:	53                   	push   %rbx
  12:	83 ff dd             	cmp    $0xffffffdd,%edi
  15:	0f 85 81 00 00 00    	jne    0x9c
  1b:	48 89 f7             	mov    %rsi,%rdi
  1e:	e8 d6 3a 01 00       	call   0x13af9
  23:	48 8d 3d ff e1 5f 04 	lea    0x45fe1ff(%rip),%rdi        # 0x45fe229
* 2a:	67 48 0f b9 3a       	ud1    (%edx),%rdi <-- trapping instruction
  2f:	4c 8d 3d 00 00 00 00 	lea    0x0(%rip),%r15        # 0x36
  36:	65 48 8b 1d 43 2e 43 	mov    %gs:0x7432e43(%rip),%rbx        # 0x7432e81
  3d:	07
  3e:	4c                   	rex.WR
  3f:	8d                   	.byte 0x8d

Crashes (13):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/04/22 10:00 upstream 6596a02b2078 4595e353 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs possible deadlock in jfs_commit_inode
2026/04/22 08:33 upstream 6596a02b2078 0b6ab7ec .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs possible deadlock in jfs_commit_inode
2026/04/22 05:07 upstream 4ee64205ffaa 0b6ab7ec .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs possible deadlock in jfs_commit_inode
2026/04/21 22:57 upstream 4ee64205ffaa 0b6ab7ec .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs possible deadlock in jfs_commit_inode
2026/04/21 19:01 upstream 4ee64205ffaa 0b6ab7ec .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs possible deadlock in jfs_commit_inode
2026/04/21 12:58 upstream b4e07588e743 3f2e655b .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs possible deadlock in jfs_commit_inode
2026/04/21 05:37 upstream b4e07588e743 3f2e655b .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs possible deadlock in jfs_commit_inode
2026/04/20 08:54 upstream c1f49dea2b8f 303e2802 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs possible deadlock in jfs_commit_inode
2026/04/20 02:51 upstream c1f49dea2b8f 303e2802 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs possible deadlock in jfs_commit_inode
2026/04/18 23:56 upstream eb5249b12507 303e2802 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs possible deadlock in jfs_commit_inode
2026/04/18 23:48 upstream eb5249b12507 303e2802 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs possible deadlock in jfs_commit_inode
2026/04/06 11:25 linux-next cc13002a9f98 4440e7c2 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root possible deadlock in jfs_commit_inode
2026/03/29 05:20 linux-next 3b058d1aeeef 356bdfc9 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root possible deadlock in jfs_commit_inode
* Struck through repros no longer work on HEAD.