program: r0 = socket$inet6_udp(0xa, 0x2, 0x0) setsockopt$inet6_mtu(r0, 0x29, 0x17, &(0x7f0000000000)=0x1, 0x4) setsockopt$inet6_udp_int(r0, 0x11, 0x67, &(0x7f0000000180)=0x5, 0x4) sendmmsg$inet6(r0, &(0x7f0000000700)=[{{&(0x7f0000000040)={0xa, 0x4e20, 0x1ff, @ipv4={'\x00', '\xff\xff', @remote}, 0x2}, 0x1c, 0x0}}, {{&(0x7f0000000780)={0xa, 0x4e20, 0x7, @ipv4={'\x00', '\xff\xff', @loopback}, 0x9}, 0x1c, &(0x7f0000000640)=[{&(0x7f0000000240)="29ff92dc4ff64db6f0c458de9006cd667134cb2c9b451e65479fda0e7cbb3e0d820e30314be72fb28b553af8a6b715a396e6bfcb987eb8145223618b7c116d14539e9b2378618dd8c1192a8932ba270815b6600731e6503c90f66bb51f42011761554c1327d7eb18d25f20e6ee6e55619a49133431357bfb1865c78c1b87d51ab2", 0x81}, {&(0x7f0000000400)="ef1bad62c3c5ed6c46f1eced837de77c4cd63ffdd01a53e48fb4e4e8dfad74697239d2b38c15e9db49318cec89ad215292f01bd57b37030e088ba4207309bceed6d334d9c14c1573d9859c4b63c2717db0868da5784356ecf00e9bfb478bbd94596ffc9fa85816eacd4ba2775427e28c64288439f492414637e84c6d3979b79748c834b686ee38b0f7c8a9f6def39921fcac8fadbf4e01a22e2321639ca0226d608780ca521519cbe64737d8824d8de62c4ecf80", 0xb4}, {&(0x7f0000000300)="26c9cdbf62d8fdd1c84d0c29a5f9b6854c9d316edcfeb68b2bdb9dd1f3e84452cf6f9d83f08b126d1de684f17178614d200434e9fbb0118a89001923728e60d316caf2ec23cf8ac96b109fb54affb3", 0x4f}, {&(0x7f00000004c0)="f1f91d625b458cf2f6403346a9cc8fa03c1df11fefdab52ca9ac741a76609c3e24c12fceb3a741ffdc142fb5f2c95d361fa1589f8b6558f7f4e5d41b267d3e49208885c7a134f76eb09bcb25f83c6f5fabad5ef7830a35f5dd611ab5358a59aa708f3417d75ce744b2cc5bb71f09bbe1dde7e6155aff2f2cf406e2691b68929d32630a2f74d808", 0x87}, {&(0x7f0000000580)="ae66a1d8fe6ce6894b03972e3101f65fb7e21697b34aeb83b4033dd035ad2943a5482b06880e5f6e3ab68a4a77b9fdc78c82a8951fe034ab97ec8d054e9b5c1eae1b4772c9ee18b398dc917369a7d154c2b84122e3d63c03f524573f086204e93911526fc9dc43426b09e143d6712fccaec7c95879cd", 0x76}], 0x5}}], 0x2, 0x20000040) syz_mount_image$hfsplus(&(0x7f0000000040), &(0x7f0000000080)='./file1\x00', 0x400, &(0x7f0000000140)=ANY=[], 0x1, 0x694, &(0x7f0000001100)="$eJzs3U1sHGf9B/DvbnbX3vz/Sp02SQOqRNRIBRGROLGSYi4NCKFIVKgqB8TRSpzGyiatHBc5EYLwfuDCoXeKRG5cQOIeVM7AqVcfKyFx6SmAxKKZnbXXr9l1Yq8tPp9odp5nnpd5nt/M7OzOKnKA/1nXzqXxOLVcO/fmcpFfeTTTWXk0c6efTjKRpJ40eqvU7ia1j5Kr6S35TLGx6q623X4+WJh9++NPVz7p5RrVUtav79Rukyv1LTY+rJacSXKkWj+Ddf1d39Bfa+TuaqszLAJ2th84GLdmku463z21VvJUw1+3wIFVK++bm6/5qeRoksnqc0Dvrti7Zx9qD8c9AAAAANgHL/yy/Ap/bNzjAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAgMOk9/f/i1W51PvpM6n1//5/q9qWKn2oPR73AAAAAAAAAABgdN/8/w0bPvckT7KcY/18t1b+5v9qmTlRvv5f3s+9zGcx57OcuSxlKYu5mGSqLG+Wr63luaWlxYtDtLy02jIDLS8NOYP27icPAAAAAAAAAIdFY/QmP861td//AQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgIKglR3qrcjnRT0+l3kgymaRV1HuY/LWfPpB+/afBXPff3dKmao/3c0wAAAAwJi88yZMs51g/362V3/lPld/7J/N+7mYpC1l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AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcEhdOzdRpc5PF68rj2Y6xdJPr1Ysq9WT1L6f1D5Krqa3ZGqgu9p2+/lgYfbtjz9d+aSXa1RLWb++rl1zN7N4WC05k+RItR40+Qz9Xa/WuxpZqbY6wyJgZ/uBg3H7bwAAAP//2wMQAg==") r1 = creat(&(0x7f0000000140)='./file1\x00', 0x188) io_setup(0x388c1b36, &(0x7f0000000100)) io_setup(0x202, &(0x7f0000000200)=0x0) io_submit(r2, 0x3b, &(0x7f0000000540)=[&(0x7f00000000c0)={0x25, 0xe7030000, 0x0, 0x1, 0x0, r1, &(0x7f0000000000), 0x70000}]) [ 58.415973][ T5341] loop0: detected capacity change from 0 to 1024 [ 58.467351][ T5341] [ 58.468256][ T5341] ============================================ [ 58.470444][ T5341] WARNING: possible recursive locking detected [ 58.472799][ T5341] 6.12.0-syzkaller-10689-g7af08b57bcb9 #0 Not tainted [ 58.475293][ T5341] -------------------------------------------- [ 58.477661][ T5341] syz.0.0/5341 is trying to acquire lock: [ 58.479603][ T5341] ffff888052cfc108 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{4:4}, at: hfsplus_file_extend+0x21b/0x1b70 [ 58.483566][ T5341] [ 58.483566][ T5341] but task is already holding lock: [ 58.486271][ T5341] ffff888052cfe988 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{4:4}, at: hfsplus_file_extend+0x21b/0x1b70 [ 58.490107][ T5341] [ 58.490107][ T5341] other info that might help us debug this: [ 58.493294][ T5341] Possible unsafe locking scenario: [ 58.493294][ T5341] [ 58.496038][ T5341] CPU0 [ 58.497277][ T5341] ---- [ 58.498509][ T5341] lock(&HFSPLUS_I(inode)->extents_lock); [ 58.500762][ T5341] lock(&HFSPLUS_I(inode)->extents_lock); [ 58.503063][ T5341] [ 58.503063][ T5341] *** DEADLOCK *** [ 58.503063][ T5341] [ 58.506116][ T5341] May be due to missing lock nesting notation [ 58.506116][ T5341] [ 58.509026][ T5341] 3 locks held by syz.0.0/5341: [ 58.510672][ T5341] #0: ffff888052cfeb78 (&sb->s_type->i_mutex_key#19){+.+.}-{4:4}, at: generic_file_write_iter+0x82/0x310 [ 58.514743][ T5341] #1: ffff888052cfe988 (&HFSPLUS_I(inode)->extents_lock){+.+.}-{4:4}, at: hfsplus_file_extend+0x21b/0x1b70 [ 58.518991][ T5341] #2: ffff888036f680b0 (&tree->tree_lock/1){+.+.}-{4:4}, at: hfsplus_find_init+0x14a/0x1c0 [ 58.522658][ T5341] [ 58.522658][ T5341] stack backtrace: [ 58.524789][ T5341] CPU: 0 UID: 0 PID: 5341 Comm: syz.0.0 Not tainted 6.12.0-syzkaller-10689-g7af08b57bcb9 #0 [ 58.528381][ T5341] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014 [ 58.532093][ T5341] Call Trace: [ 58.533334][ T5341] [ 58.534374][ T5341] dump_stack_lvl+0x241/0x360 [ 58.536072][ T5341] ? __pfx_dump_stack_lvl+0x10/0x10 [ 58.537898][ T5341] ? __pfx__printk+0x10/0x10 [ 58.540163][ T5341] ? lockdep_unlock+0x16a/0x300 [ 58.542522][ T5341] print_deadlock_bug+0x483/0x620 [ 58.544484][ T5341] validate_chain+0x15e2/0x5920 [ 58.546230][ T5341] ? __bfs+0x368/0x6f0 [ 58.547712][ T5341] ? __pfx_hlock_conflict+0x10/0x10 [ 58.549498][ T5341] ? __pfx_validate_chain+0x10/0x10 [ 58.551494][ T5341] ? check_path+0x21/0x40 [ 58.553459][ T5341] ? check_noncircular+0x259/0x4a0 [ 58.555719][ T5341] ? look_up_lock_class+0x77/0x170 [ 58.557576][ T5341] ? register_lock_class+0x102/0x980 [ 58.559513][ T5341] ? lockdep_unlock+0x16a/0x300 [ 58.561276][ T5341] ? __pfx_register_lock_class+0x10/0x10 [ 58.563478][ T5341] ? mark_lock+0x9a/0x360 [ 58.565142][ T5341] __lock_acquire+0x1397/0x2100 [ 58.566991][ T5341] lock_acquire+0x1ed/0x550 [ 58.568467][ T5341] ? hfsplus_file_extend+0x21b/0x1b70 [ 58.570352][ T5341] ? __pfx_lock_acquire+0x10/0x10 [ 58.572190][ T5341] ? __pfx___might_resched+0x10/0x10 [ 58.574154][ T5341] __mutex_lock+0x1ac/0xee0 [ 58.575870][ T5341] ? hfsplus_file_extend+0x21b/0x1b70 [ 58.577769][ T5341] ? lockdep_hardirqs_on_prepare+0x43d/0x780 [ 58.579833][ T5341] ? mark_lock+0x9a/0x360 [ 58.581423][ T5341] ? hfsplus_file_extend+0x21b/0x1b70 [ 58.583326][ T5341] ? __pfx___mutex_lock+0x10/0x10 [ 58.584967][ T5341] hfsplus_file_extend+0x21b/0x1b70 [ 58.586727][ T5341] ? __pfx_hfsplus_file_extend+0x10/0x10 [ 58.588823][ T5341] ? __pfx___mutex_trylock_common+0x10/0x10 [ 58.591096][ T5341] ? rcu_is_watching+0x15/0xb0 [ 58.592961][ T5341] ? trace_contention_end+0x3c/0x120 [ 58.595034][ T5341] ? __mutex_lock+0x37f/0xee0 [ 58.596821][ T5341] ? hfsplus_brec_find+0x19d/0x570 [ 58.598728][ T5341] hfsplus_bmap_reserve+0x105/0x4e0 [ 58.600727][ T5341] __hfsplus_ext_write_extent+0x2a4/0x5c0 [ 58.602758][ T5341] __hfsplus_ext_cache_extent+0x84/0xe10 [ 58.604820][ T5341] hfsplus_file_extend+0x48c/0x1b70 [ 58.606795][ T5341] ? __pfx_hfsplus_file_extend+0x10/0x10 [ 58.608477][ T5341] ? clean_bdev_aliases+0x654/0x7e0 [ 58.610127][ T5341] ? __pfx_clean_bdev_aliases+0x10/0x10 [ 58.611828][ T5341] hfsplus_get_block+0x406/0x14f0 [ 58.613490][ T5341] ? __pfx_hfsplus_get_block+0x10/0x10 [ 58.615203][ T5341] ? create_empty_buffers+0x53e/0x740 [ 58.616865][ T5341] __block_write_begin_int+0x50c/0x1a70 [ 58.618625][ T5341] ? irqentry_exit+0x63/0x90 [ 58.620137][ T5341] ? __pfx_hfsplus_get_block+0x10/0x10 [ 58.621896][ T5341] ? __pfx___block_write_begin_int+0x10/0x10 [ 58.623997][ T5341] cont_write_begin+0x6e2/0x9d0 [ 58.625906][ T5341] ? __pfx_cont_write_begin+0x10/0x10 [ 58.627959][ T5341] ? __pfx_fault_in_readable+0x10/0x10 [ 58.630033][ T5341] ? __mark_inode_dirty+0x3db/0xe90 [ 58.632138][ T5341] hfsplus_write_begin+0x68/0xb0 [ 58.634390][ T5341] ? __pfx_hfsplus_get_block+0x10/0x10 [ 58.637020][ T5341] generic_perform_write+0x344/0x6d0 [ 58.639453][ T5341] ? __pfx_generic_perform_write+0x10/0x10 [ 58.641661][ T5341] ? file_update_time+0x2ab/0x450 [ 58.643348][ T5341] ? __generic_file_write_iter+0x102/0x230 [ 58.645202][ T5341] generic_file_write_iter+0xae/0x310 [ 58.647091][ T5341] aio_write+0x56b/0x7c0 [ 58.648643][ T5341] ? __pfx_aio_write+0x10/0x10 [ 58.650229][ T5341] ? __might_fault+0xaa/0x120 [ 58.651851][ T5341] ? __pfx_lock_release+0x10/0x10 [ 58.653558][ T5341] ? __fget_files+0x2a/0x410 [ 58.655224][ T5341] ? __might_fault+0xaa/0x120 [ 58.657058][ T5341] io_submit_one+0x8a7/0x18a0 [ 58.658838][ T5341] ? __pfx_io_submit_one+0x10/0x10 [ 58.660691][ T5341] ? __might_fault+0xaa/0x120 [ 58.662465][ T5341] ? __pfx_lock_release+0x10/0x10 [ 58.664363][ T5341] ? __might_fault+0xaa/0x120 [ 58.665955][ T5341] ? __might_fault+0xc6/0x120 [ 58.667666][ T5341] __se_sys_io_submit+0x171/0x2e0 [ 58.669332][ T5341] ? __pfx___se_sys_io_submit+0x10/0x10 [ 58.671313][ T5341] ? lockdep_hardirqs_on_prepare+0x43d/0x780 [ 58.673496][ T5341] ? do_syscall_64+0x100/0x230 [ 58.675200][ T5341] ? do_syscall_64+0xb6/0x230 [ 58.676967][ T5341] do_syscall_64+0xf3/0x230 [ 58.678687][ T5341] ? clear_bhb_loop+0x35/0x90 [ 58.680285][ T5341] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 58.682444][ T5341] RIP: 0033:0x7f8499980849 [ 58.684087][ T5341] Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 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 a8 ff ff ff f7 d8 64 89 01 48 [ 58.690536][ T5341] RSP: 002b:00007f849a7d9058 EFLAGS: 00000246 ORIG_RAX: 00000000000000d1 [ 58.693413][ T5341] RAX: ffffffffffffffda RBX: 00007f8499b45fa0 RCX: 00007f8499980849 [ 58.696190][ T5341] RDX: 0000000020000540 RSI: 000000000000003b RDI: 00007f849a78f000 [ 58.699212][ T5341] RBP: 00007f84999f3986 R08: 0000000000000000 R09: 0000000000000000 [ 58.702159][ T5341] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 [ 58.705074][ T5341] R13: 0000000000000000 R14: 00007f8499b45fa0 R15: 00007ffcc7fdbd18 [ 58.707562][ T5341] [ 58.710173][ T4684] Bluetooth: hci0: command tx timeout