syzbot


possible deadlock in hfsplus_find_init

Status: upstream: reported C repro on 2023/04/06 17:26
Bug presence: origin:upstream
[Documentation on labels]
Reported-by: syzbot+5da1fef4d17e09c820db@syzkaller.appspotmail.com
First crash: 606d, last: 3d06h
Fix bisection: failed (error log, bisect log)
  
Bug presence (1)
Date Name Commit Repro Result
2023/05/22 upstream (ToT) 44c026a73be8 C [report] possible deadlock in hfsplus_find_init
Similar bugs (4)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-4.14 possible deadlock in hfsplus_find_init hfsplus C 4 638d 706d 0/1 upstream: reported C repro on 2022/12/27 19:37
linux-4.19 possible deadlock in hfsplus_find_init hfsplus C error 9 692d 731d 0/1 upstream: reported C repro on 2022/12/03 13:19
linux-6.1 possible deadlock in hfsplus_find_init origin:upstream C error 74 88d 629d 0/3 upstream: reported C repro on 2023/03/15 11:24
upstream possible deadlock in hfsplus_find_init hfs C error error 488 10h43m 712d 0/28 upstream: reported C repro on 2022/12/22 07:31
Last patch testing requests (5)
Created Duration User Patch Repo Result
2024/11/27 09:59 12m retest repro linux-5.15.y report log
2024/10/15 03:45 0m retest repro linux-5.15.y error
2024/10/15 03:45 0m retest repro linux-5.15.y error
2024/10/15 03:45 0m retest repro linux-5.15.y error
2024/10/15 03:45 0m retest repro linux-5.15.y error
Fix bisection attempts (7)
Created Duration User Patch Repo Result
2024/09/18 01:59 1m bisect fix linux-5.15.y error job log
2024/03/30 23:25 1h24m bisect fix linux-5.15.y OK (0) job log log
2024/01/29 07:24 1h24m bisect fix linux-5.15.y OK (0) job log log
2023/12/16 06:43 58m bisect fix linux-5.15.y OK (0) job log log
2023/11/15 12:25 57m bisect fix linux-5.15.y OK (0) job log log
2023/10/13 02:24 1h44m bisect fix linux-5.15.y OK (0) job log log
2023/09/01 10:05 1h45m bisect fix linux-5.15.y OK (0) job log log

Sample crash report:
loop0: detected capacity change from 0 to 1024
============================================
WARNING: possible recursive locking detected
5.15.118-syzkaller #0 Not tainted
--------------------------------------------
syz-executor332/3497 is trying to acquire lock:
ffff8880161ea0b0 (&tree->tree_lock/1){+.+.}-{3:3}, at: hfsplus_find_init+0x146/0x1c0

but task is already holding lock:
ffff8880161ea0b0 (&tree->tree_lock/1){+.+.}-{3:3}, at: hfsplus_find_init+0x146/0x1c0

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

       CPU0
       ----
  lock(&tree->tree_lock/1);
  lock(&tree->tree_lock/1);

 *** DEADLOCK ***

 May be due to missing lock nesting notation

5 locks held by syz-executor332/3497:
 #0: ffff8880161ec460 (sb_writers#9){.+.+}-{0:0}, at: vfs_write+0x29a/0xe50 fs/read_write.c:590
 #1: ffff888078638300 (&sb->s_type->i_mutex_key#15){+.+.}-{3:3}, at: inode_lock include/linux/fs.h:787 [inline]
 #1: ffff888078638300 (&sb->s_type->i_mutex_key#15){+.+.}-{3:3}, at: generic_file_write_iter+0x7c/0x1b0 mm/filemap.c:3932
 #2: ffff888078638108 (&hip->extents_lock){+.+.}-{3:3}, at: hfsplus_file_extend+0x1d2/0x1b10 fs/hfsplus/extents.c:457
 #3: ffff8880161ea0b0 (&tree->tree_lock/1){+.+.}-{3:3}, at: hfsplus_find_init+0x146/0x1c0
 #4: ffff888076ac0108 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{3:3}, at: hfsplus_file_extend+0x1d2/0x1b10 fs/hfsplus/extents.c:457

stack backtrace:
CPU: 1 PID: 3497 Comm: syz-executor332 Not tainted 5.15.118-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/27/2023
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1e3/0x2cb lib/dump_stack.c:106
 print_deadlock_bug kernel/locking/lockdep.c:2946 [inline]
 check_deadlock kernel/locking/lockdep.c:2989 [inline]
 validate_chain+0x46cf/0x58b0 kernel/locking/lockdep.c:3774
 __lock_acquire+0x1295/0x1ff0 kernel/locking/lockdep.c:5011
 lock_acquire+0x1db/0x4f0 kernel/locking/lockdep.c:5622
 __mutex_lock_common+0x1da/0x25a0 kernel/locking/mutex.c:596
 __mutex_lock kernel/locking/mutex.c:729 [inline]
 mutex_lock_nested+0x17/0x20 kernel/locking/mutex.c:743
 hfsplus_find_init+0x146/0x1c0
 hfsplus_ext_read_extent fs/hfsplus/extents.c:216 [inline]
 hfsplus_file_extend+0x40a/0x1b10 fs/hfsplus/extents.c:461
 hfsplus_bmap_reserve+0x101/0x4e0 fs/hfsplus/btree.c:357
 __hfsplus_ext_write_extent+0x2a4/0x5b0 fs/hfsplus/extents.c:104
 __hfsplus_ext_cache_extent+0x84/0xe00 fs/hfsplus/extents.c:186
 hfsplus_ext_read_extent fs/hfsplus/extents.c:218 [inline]
 hfsplus_file_extend+0x435/0x1b10 fs/hfsplus/extents.c:461
 hfsplus_get_block+0x402/0x14e0 fs/hfsplus/extents.c:245
 __block_write_begin_int+0x60b/0x1650 fs/buffer.c:2012
 __block_write_begin fs/buffer.c:2062 [inline]
 block_write_begin fs/buffer.c:2122 [inline]
 cont_write_begin+0x5d6/0x840 fs/buffer.c:2471
 hfsplus_write_begin+0x92/0xd0 fs/hfsplus/inode.c:53
 generic_perform_write+0x2bf/0x5b0 mm/filemap.c:3776
 __generic_file_write_iter+0x243/0x4f0 mm/filemap.c:3903
 generic_file_write_iter+0xa7/0x1b0 mm/filemap.c:3935
 call_write_iter include/linux/fs.h:2103 [inline]
 new_sync_write fs/read_write.c:507 [inline]
 vfs_write+0xacf/0xe50 fs/read_write.c:594
 ksys_write+0x1a2/0x2c0 fs/read_write.c:647
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7f2af95337e9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 51 14 00 00 90 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 c0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffc58a8f888 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f2af95337e9
RDX: 00000000fffffff0 RSI: 0000000020004200 RDI: 0000000000000004
RBP: 00007f2af94f3080 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000647 R11: 0000000000000246 R12: 00007f2af94f3110
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
 </TASK>

Crashes (55):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/06/24 21:31 linux-5.15.y f67653019430 79782afc .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/05/22 19:15 linux-5.15.y 9d6bde853685 4bce1a3e .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/05/22 17:47 linux-5.15.y 9d6bde853685 4bce1a3e .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2024/05/13 04:10 linux-5.15.y 284087d4f7d5 9026e142 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/05/12 16:15 linux-5.15.y 284087d4f7d5 9026e142 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/11/30 09:44 linux-5.15.y 0a51d2d4527b 68914665 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2024/06/17 22:58 linux-5.15.y 4878aadf2d15 1f11cfd7 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2024/05/23 15:36 linux-5.15.y 83655231580b 4c2072ee .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2024/05/01 22:03 linux-5.15.y b925f60c6ee7 3ba885bc .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2024/04/28 05:02 linux-5.15.y b925f60c6ee7 07b455f9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2024/04/27 19:49 linux-5.15.y b925f60c6ee7 07b455f9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2024/04/26 12:13 linux-5.15.y c52b9710c83d 059e9963 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/12/29 06:12 linux-5.15.y d93fa2c78854 fb427a07 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2024/10/15 07:19 linux-5.15.y 3a5928702e71 b01b6661 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/09/29 20:52 linux-5.15.y 3a5928702e71 ba29ff75 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/08/18 19:20 linux-5.15.y 7e89efd3ae1c dbc93b08 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/08/17 00:59 linux-5.15.y 7e89efd3ae1c dbc93b08 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/08/03 00:12 linux-5.15.y 7e89efd3ae1c 1786a2a8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/07/21 13:14 linux-5.15.y 7c6d66f0266f b88348e9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/06/26 20:20 linux-5.15.y 4878aadf2d15 c6d33a01 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/06/25 16:54 linux-5.15.y 4878aadf2d15 04bd2a30 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/06/07 21:58 linux-5.15.y c61bd26ae81a 82c05ab8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/05/19 04:17 linux-5.15.y 83655231580b c0f1611a .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/05/01 22:00 linux-5.15.y b925f60c6ee7 3ba885bc .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/05/01 04:25 linux-5.15.y b925f60c6ee7 3ba885bc .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/04/24 20:55 linux-5.15.y c52b9710c83d 8bdc0f22 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/04/14 23:35 linux-5.15.y fa3df276cd36 c8349e48 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/04/13 13:54 linux-5.15.y fa3df276cd36 c8349e48 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2024/02/29 15:07 linux-5.15.y 458ce51d0356 352ab904 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/06/12 23:38 linux-5.15.y 7349e40704a0 aaed0183 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/06/11 00:41 linux-5.15.y 7349e40704a0 49519f06 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/06/10 04:12 linux-5.15.y 7349e40704a0 9018a337 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/06/02 13:49 linux-5.15.y 0ab06468cbd1 a4ae4f42 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/05/30 22:32 linux-5.15.y 0ab06468cbd1 df37c7f1 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/05/26 01:35 linux-5.15.y 1fe619a7d252 0513b3e6 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/05/25 09:26 linux-5.15.y 1fe619a7d252 4bce1a3e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/05/15 14:52 linux-5.15.y b0ece631f84a c4d362e7 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/05/13 18:21 linux-5.15.y b0ece631f84a 2b9ba477 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan possible deadlock in hfsplus_find_init
2023/05/31 11:59 linux-5.15.y 0ab06468cbd1 09898419 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/05/31 08:08 linux-5.15.y 0ab06468cbd1 09898419 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/05/29 15:29 linux-5.15.y 1fe619a7d252 cf184559 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/05/27 02:42 linux-5.15.y 1fe619a7d252 cf184559 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/05/25 01:03 linux-5.15.y 1fe619a7d252 4bce1a3e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/05/24 19:53 linux-5.15.y 1fe619a7d252 4bce1a3e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/05/10 11:44 linux-5.15.y 8a7f2a5c5aa1 14b12a99 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/04/27 04:28 linux-5.15.y f48aeeaaa64c 19a3dabe .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/04/19 18:59 linux-5.15.y 4fdad925aa1a a219f34e .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/04/18 21:56 linux-5.15.y 4fdad925aa1a d931e9f0 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/04/14 03:52 linux-5.15.y 4fdad925aa1a 3cfcaa1b .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/04/14 00:48 linux-5.15.y 4fdad925aa1a 3cfcaa1b .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/04/10 17:34 linux-5.15.y d86dfc4d95cd 71147e29 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
2023/04/06 17:26 linux-5.15.y d86dfc4d95cd 08707520 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-5-15-kasan-arm64 possible deadlock in hfsplus_find_init
* Struck through repros no longer work on HEAD.