IPVS: ftp: loaded support on port[0] = 21 ====================================================== WARNING: possible circular locking dependency detected 4.19.211-syzkaller #0 Not tainted ------------------------------------------------------ syz-executor.4/26291 is trying to acquire lock: 00000000ea38508f (&tree->tree_lock/1){+.+.}, at: hfs_find_init+0x17e/0x230 fs/hfs/bfind.c:33 but task is already holding lock: 00000000f63011c0 (&HFS_I(tree->inode)->extents_lock){+.+.}, at: hfs_get_block+0x532/0x7e0 fs/hfs/extent.c:365 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #1 (&HFS_I(tree->inode)->extents_lock){+.+.}: hfs_extend_file+0x93/0xac0 fs/hfs/extent.c:397 hfs_bmap_reserve+0x241/0x390 fs/hfs/btree.c:231 __hfs_ext_write_extent+0x3c1/0x510 fs/hfs/extent.c:121 __hfs_ext_cache_extent fs/hfs/extent.c:174 [inline] hfs_ext_read_extent+0x810/0xa20 fs/hfs/extent.c:202 hfs_extend_file+0x4a0/0xac0 fs/hfs/extent.c:401 hfs_get_block+0x17b/0x7e0 fs/hfs/extent.c:353 __block_write_begin_int+0x46c/0x17b0 fs/buffer.c:1978 __block_write_begin fs/buffer.c:2028 [inline] block_write_begin+0x58/0x2e0 fs/buffer.c:2087 cont_write_begin+0x55a/0x820 fs/buffer.c:2440 hfs_write_begin+0x87/0x150 fs/hfs/inode.c:58 generic_perform_write+0x1f8/0x4d0 mm/filemap.c:3170 __generic_file_write_iter+0x24b/0x610 mm/filemap.c:3295 generic_file_write_iter+0x3f8/0x730 mm/filemap.c:3323 call_write_iter include/linux/fs.h:1821 [inline] new_sync_write fs/read_write.c:474 [inline] __vfs_write+0x51b/0x770 fs/read_write.c:487 vfs_write+0x1f3/0x540 fs/read_write.c:549 ksys_write+0x12b/0x2a0 fs/read_write.c:599 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe -> #0 (&tree->tree_lock/1){+.+.}: __mutex_lock_common kernel/locking/mutex.c:937 [inline] __mutex_lock+0xd7/0x1190 kernel/locking/mutex.c:1078 hfs_find_init+0x17e/0x230 fs/hfs/bfind.c:33 hfs_ext_read_extent+0x191/0xa20 fs/hfs/extent.c:200 hfs_get_block+0x53d/0x7e0 fs/hfs/extent.c:366 block_read_full_page+0x288/0xd10 fs/buffer.c:2259 do_read_cache_page+0x533/0x1170 mm/filemap.c:2828 read_mapping_page include/linux/pagemap.h:402 [inline] hfs_btree_open+0x6ae/0x1430 fs/hfs/btree.c:78 hfs_mdb_get+0x148c/0x1cf0 fs/hfs/mdb.c:198 hfs_fill_super+0xd6a/0x1310 fs/hfs/super.c:413 mount_bdev+0x2fc/0x3b0 fs/super.c:1158 mount_fs+0xa3/0x310 fs/super.c:1261 vfs_kern_mount.part.0+0x68/0x470 fs/namespace.c:961 vfs_kern_mount fs/namespace.c:951 [inline] do_new_mount fs/namespace.c:2492 [inline] do_mount+0x115c/0x2f50 fs/namespace.c:2822 ksys_mount+0xcf/0x130 fs/namespace.c:3038 __do_sys_mount fs/namespace.c:3052 [inline] __se_sys_mount fs/namespace.c:3049 [inline] __x64_sys_mount+0xba/0x150 fs/namespace.c:3049 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe other info that might help us debug this: Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&HFS_I(tree->inode)->extents_lock); lock(&tree->tree_lock/1); lock(&HFS_I(tree->inode)->extents_lock); lock(&tree->tree_lock/1); *** DEADLOCK *** 2 locks held by syz-executor.4/26291: #0: 000000008119ee56 (&type->s_umount_key#70/1){+.+.}, at: alloc_super fs/super.c:226 [inline] #0: 000000008119ee56 (&type->s_umount_key#70/1){+.+.}, at: sget_userns+0x20b/0xcd0 fs/super.c:519 #1: 00000000f63011c0 (&HFS_I(tree->inode)->extents_lock){+.+.}, at: hfs_get_block+0x532/0x7e0 fs/hfs/extent.c:365 stack backtrace: CPU: 0 PID: 26291 Comm: syz-executor.4 Not tainted 4.19.211-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x1fc/0x2ef lib/dump_stack.c:118 print_circular_bug.constprop.0.cold+0x2d7/0x41e kernel/locking/lockdep.c:1222 check_prev_add kernel/locking/lockdep.c:1866 [inline] check_prevs_add kernel/locking/lockdep.c:1979 [inline] validate_chain kernel/locking/lockdep.c:2420 [inline] __lock_acquire+0x30c9/0x3ff0 kernel/locking/lockdep.c:3416 lock_acquire+0x170/0x3c0 kernel/locking/lockdep.c:3908 __mutex_lock_common kernel/locking/mutex.c:937 [inline] __mutex_lock+0xd7/0x1190 kernel/locking/mutex.c:1078 hfs_find_init+0x17e/0x230 fs/hfs/bfind.c:33 hfs_ext_read_extent+0x191/0xa20 fs/hfs/extent.c:200 hfs_get_block+0x53d/0x7e0 fs/hfs/extent.c:366 block_read_full_page+0x288/0xd10 fs/buffer.c:2259 do_read_cache_page+0x533/0x1170 mm/filemap.c:2828 read_mapping_page include/linux/pagemap.h:402 [inline] hfs_btree_open+0x6ae/0x1430 fs/hfs/btree.c:78 hfs_mdb_get+0x148c/0x1cf0 fs/hfs/mdb.c:198 hfs_fill_super+0xd6a/0x1310 fs/hfs/super.c:413 mount_bdev+0x2fc/0x3b0 fs/super.c:1158 mount_fs+0xa3/0x310 fs/super.c:1261 vfs_kern_mount.part.0+0x68/0x470 fs/namespace.c:961 vfs_kern_mount fs/namespace.c:951 [inline] do_new_mount fs/namespace.c:2492 [inline] do_mount+0x115c/0x2f50 fs/namespace.c:2822 ksys_mount+0xcf/0x130 fs/namespace.c:3038 __do_sys_mount fs/namespace.c:3052 [inline] __se_sys_mount fs/namespace.c:3049 [inline] __x64_sys_mount+0xba/0x150 fs/namespace.c:3049 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x7f7b1b5905fa Code: 48 c7 c2 b8 ff ff ff f7 d8 64 89 02 b8 ff ff ff ff eb d2 e8 b8 04 00 00 0f 1f 84 00 00 00 00 00 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f7b19b00f88 EFLAGS: 00000202 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 000000000000026e RCX: 00007f7b1b5905fa RDX: 0000000020000000 RSI: 00000000200001c0 RDI: 00007f7b19b00fe0 RBP: 00007f7b19b01020 R08: 00007f7b19b01020 R09: 0000000001000c08 R10: 0000000001000c08 R11: 0000000000000202 R12: 0000000020000000 R13: 00000000200001c0 R14: 00007f7b19b00fe0 R15: 0000000020000080 hfs: unable to open catalog tree hfs: can't find a HFS filesystem on dev loop4 kauditd_printk_skb: 67 callbacks suppressed audit: type=1804 audit(1673607708.424:517): pid=26357 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.5" name="/root/syzkaller-testdir1145829131/syzkaller.GJhqGg/110/bus" dev="sda1" ino=13908 res=1 IPVS: ftp: loaded support on port[0] = 21 audit: type=1800 audit(1673607708.424:518): pid=26357 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.5" name="bus" dev="sda1" ino=13908 res=0 hfs: unable to open catalog tree hfs: can't find a HFS filesystem on dev loop4 hfs: unable to open catalog tree IPVS: ftp: loaded support on port[0] = 21 hfs: can't find a HFS filesystem on dev loop4 IPVS: ftp: loaded support on port[0] = 21 audit: type=1804 audit(1673607709.384:519): pid=26465 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.5" name="/root/syzkaller-testdir1145829131/syzkaller.GJhqGg/111/bus" dev="sda1" ino=13895 res=1 audit: type=1800 audit(1673607709.384:520): pid=26465 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.5" name="bus" dev="sda1" ino=13895 res=0 audit: type=1804 audit(1673607709.404:521): pid=26474 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.4" name="/root/syzkaller-testdir1148052982/syzkaller.P6HR6U/143/bus" dev="sda1" ino=13906 res=1 audit: type=1800 audit(1673607709.404:522): pid=26474 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.4" name="bus" dev="sda1" ino=13906 res=0 audit: type=1804 audit(1673607709.894:523): pid=26522 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.3" name="/root/syzkaller-testdir3407938476/syzkaller.19msAc/496/bus" dev="sda1" ino=14610 res=1 audit: type=1800 audit(1673607709.894:524): pid=26522 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.3" name="bus" dev="sda1" ino=14610 res=0 audit: type=1804 audit(1673607710.404:525): pid=26533 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.5" name="/root/syzkaller-testdir1145829131/syzkaller.GJhqGg/112/bus" dev="sda1" ino=14452 res=1 audit: type=1800 audit(1673607710.404:526): pid=26533 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.5" name="bus" dev="sda1" ino=14452 res=0 netlink: 28 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 28 bytes leftover after parsing attributes in process `syz-executor.2'. kauditd_printk_skb: 6 callbacks suppressed audit: type=1804 audit(1673607714.985:533): pid=26804 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.0" name="/root/syzkaller-testdir1888450429/syzkaller.FA8piO/113/bus" dev="sda1" ino=14849 res=1 audit: type=1800 audit(1673607714.985:534): pid=26804 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.0" name="bus" dev="sda1" ino=14849 res=0 audit: type=1804 audit(1673607714.985:535): pid=26807 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.3" name="/root/syzkaller-testdir3407938476/syzkaller.19msAc/500/bus" dev="sda1" ino=14865 res=1 audit: type=1800 audit(1673607714.985:536): pid=26807 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.3" name="bus" dev="sda1" ino=14865 res=0 audit: type=1804 audit(1673607715.015:537): pid=26810 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.4" name="/root/syzkaller-testdir1148052982/syzkaller.P6HR6U/147/bus" dev="sda1" ino=14884 res=1 audit: type=1800 audit(1673607715.015:538): pid=26810 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.4" name="bus" dev="sda1" ino=14884 res=0 audit: type=1804 audit(1673607717.065:539): pid=26864 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.0" name="/root/syzkaller-testdir1888450429/syzkaller.FA8piO/114/bus" dev="sda1" ino=14994 res=1 audit: type=1800 audit(1673607717.075:540): pid=26864 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.0" name="bus" dev="sda1" ino=14994 res=0