audit: type=1800 audit(1674970308.643:517): pid=23756 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.3" name="bus" dev="sda1" ino=14274 res=0 ====================================================== WARNING: possible circular locking dependency detected 4.19.211-syzkaller #0 Not tainted ------------------------------------------------------ syz-executor.4/23753 is trying to acquire lock: 00000000088ae0f0 (&ovl_i_mutex_key[depth]){+.+.}, at: inode_lock include/linux/fs.h:748 [inline] 00000000088ae0f0 (&ovl_i_mutex_key[depth]){+.+.}, at: ovl_write_iter+0x148/0xb40 fs/overlayfs/file.c:270 but task is already holding lock: 000000004533e21b (&pipe->mutex/1){+.+.}, at: pipe_lock_nested fs/pipe.c:77 [inline] 000000004533e21b (&pipe->mutex/1){+.+.}, at: pipe_lock fs/pipe.c:85 [inline] 000000004533e21b (&pipe->mutex/1){+.+.}, at: pipe_wait+0x1bd/0x1e0 fs/pipe.c:133 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: audit: type=1800 audit(1674970308.643:518): pid=23763 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.3" name="bus" dev="sda1" ino=14274 res=0 -> #2 (&pipe->mutex/1){+.+.}: pipe_lock_nested fs/pipe.c:77 [inline] pipe_lock+0x63/0x80 fs/pipe.c:85 iter_file_splice_write+0x183/0xbb0 fs/splice.c:700 audit: type=1800 audit(1674970308.643:519): pid=23763 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.3" name="bus" dev="sda1" ino=14274 res=0 do_splice_from fs/splice.c:852 [inline] do_splice fs/splice.c:1154 [inline] __do_sys_splice fs/splice.c:1428 [inline] __se_sys_splice+0xfe7/0x16d0 fs/splice.c:1408 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe -> #1 (sb_writers#3){.+.+}: sb_start_write include/linux/fs.h:1579 [inline] mnt_want_write+0x3a/0xb0 fs/namespace.c:360 ovl_setattr+0xdd/0x920 fs/overlayfs/inode.c:30 notify_change+0x70b/0xfc0 fs/attr.c:334 do_truncate+0x134/0x1f0 fs/open.c:63 handle_truncate fs/namei.c:3009 [inline] do_last fs/namei.c:3427 [inline] path_openat+0x2308/0x2df0 fs/namei.c:3537 do_filp_open+0x18c/0x3f0 fs/namei.c:3567 do_sys_open+0x3b3/0x520 fs/open.c:1085 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe -> #0 (&ovl_i_mutex_key[depth]){+.+.}: down_write+0x34/0x90 kernel/locking/rwsem.c:70 inode_lock include/linux/fs.h:748 [inline] ovl_write_iter+0x148/0xb40 fs/overlayfs/file.c:270 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 __kernel_write+0x109/0x370 fs/read_write.c:506 write_pipe_buf+0x153/0x1f0 fs/splice.c:798 splice_from_pipe_feed fs/splice.c:503 [inline] __splice_from_pipe+0x389/0x800 fs/splice.c:627 splice_from_pipe fs/splice.c:662 [inline] default_file_splice_write+0xd8/0x180 fs/splice.c:810 do_splice_from fs/splice.c:852 [inline] do_splice fs/splice.c:1154 [inline] __do_sys_splice fs/splice.c:1428 [inline] __se_sys_splice+0xfe7/0x16d0 fs/splice.c:1408 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: Chain exists of: &ovl_i_mutex_key[depth] --> sb_writers#3 --> &pipe->mutex/1 Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&pipe->mutex/1); lock(sb_writers#3); lock(&pipe->mutex/1); lock(&ovl_i_mutex_key[depth]); *** DEADLOCK *** 2 locks held by syz-executor.4/23753: #0: 0000000076d655f8 (sb_writers#19){.+.+}, at: file_start_write include/linux/fs.h:2779 [inline] #0: 0000000076d655f8 (sb_writers#19){.+.+}, at: do_splice fs/splice.c:1153 [inline] #0: 0000000076d655f8 (sb_writers#19){.+.+}, at: __do_sys_splice fs/splice.c:1428 [inline] #0: 0000000076d655f8 (sb_writers#19){.+.+}, at: __se_sys_splice+0x11de/0x16d0 fs/splice.c:1408 #1: 000000004533e21b (&pipe->mutex/1){+.+.}, at: pipe_lock_nested fs/pipe.c:77 [inline] #1: 000000004533e21b (&pipe->mutex/1){+.+.}, at: pipe_lock fs/pipe.c:85 [inline] #1: 000000004533e21b (&pipe->mutex/1){+.+.}, at: pipe_wait+0x1bd/0x1e0 fs/pipe.c:133 stack backtrace: CPU: 1 PID: 23753 Comm: syz-executor.4 Not tainted 4.19.211-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/12/2023 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 down_write+0x34/0x90 kernel/locking/rwsem.c:70 inode_lock include/linux/fs.h:748 [inline] ovl_write_iter+0x148/0xb40 fs/overlayfs/file.c:270 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 __kernel_write+0x109/0x370 fs/read_write.c:506 write_pipe_buf+0x153/0x1f0 fs/splice.c:798 splice_from_pipe_feed fs/splice.c:503 [inline] __splice_from_pipe+0x389/0x800 fs/splice.c:627 splice_from_pipe fs/splice.c:662 [inline] default_file_splice_write+0xd8/0x180 fs/splice.c:810 do_splice_from fs/splice.c:852 [inline] do_splice fs/splice.c:1154 [inline] __do_sys_splice fs/splice.c:1428 [inline] __se_sys_splice+0xfe7/0x16d0 fs/splice.c:1408 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x7fa4f610c0c9 Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 f1 19 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 b8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fa4f467e168 EFLAGS: 00000246 ORIG_RAX: 0000000000000113 RAX: ffffffffffffffda RBX: 00007fa4f622bf80 RCX: 00007fa4f610c0c9 RDX: 0000000000000005 RSI: 0000000000000000 RDI: 0000000000000004 RBP: 00007fa4f6167ae9 R08: 000000000000fdef R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffcf25319ef R14: 00007fa4f467e300 R15: 0000000000022000 REISERFS (device loop1): found reiserfs format "3.6" with non-standard journal REISERFS (device loop1): using ordered data mode reiserfs: using flush barriers REISERFS (device loop1): journal params: device loop1, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 REISERFS (device loop1): checking transaction log (loop1) REISERFS (device loop1): Using r5 hash to sort names REISERFS (device loop1): Created .reiserfs_priv - reserved for xattr storage. netlink: 76 bytes leftover after parsing attributes in process `syz-executor.2'. audit: type=1804 audit(1674970309.683:520): pid=23788 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.1" name="/root/syzkaller-testdir2247647388/syzkaller.oOU5iq/524/file1/bus" dev="loop1" ino=4 res=1 audit: type=1804 audit(1674970309.703:521): pid=23788 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=ToMToU comm="syz-executor.1" name="/root/syzkaller-testdir2247647388/syzkaller.oOU5iq/524/file1/bus" dev="loop1" ino=4 res=1 f2fs_msg: 2 callbacks suppressed F2FS-fs (loop5): invalid crc value F2FS-fs (loop5): Found nat_bits in checkpoint F2FS-fs (loop5): f2fs_check_nid_range: out-of-range nid=2, run fsck to fix. audit: type=1804 audit(1674970309.833:522): pid=23831 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=ToMToU comm="syz-executor.1" name="/root/syzkaller-testdir2247647388/syzkaller.oOU5iq/524/file1/bus" dev="loop1" ino=4 res=1 F2FS-fs (loop5): Mounted with checkpoint version = 48b305e4 audit: type=1800 audit(1674970310.013:523): pid=23843 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=collect_data cause=failed(directio) comm="syz-executor.5" name="bus" dev="loop5" ino=10 res=0 netlink: 76 bytes leftover after parsing attributes in process `syz-executor.2'. REISERFS (device loop1): found reiserfs format "3.6" with non-standard journal REISERFS (device loop1): using ordered data mode reiserfs: using flush barriers REISERFS (device loop1): journal params: device loop1, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 REISERFS (device loop1): checking transaction log (loop1) REISERFS (device loop1): Using r5 hash to sort names REISERFS (device loop1): Created .reiserfs_priv - reserved for xattr storage. audit: type=1804 audit(1674970310.483:524): pid=23885 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.1" name="/root/syzkaller-testdir2247647388/syzkaller.oOU5iq/525/file1/bus" dev="loop1" ino=4 res=1 audit: type=1804 audit(1674970310.533:525): pid=23885 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=ToMToU comm="syz-executor.1" name="/root/syzkaller-testdir2247647388/syzkaller.oOU5iq/525/file1/bus" dev="loop1" ino=4 res=1 REISERFS (device loop1): found reiserfs format "3.6" with non-standard journal REISERFS (device loop1): using ordered data mode reiserfs: using flush barriers REISERFS (device loop1): journal params: device loop1, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 REISERFS (device loop1): checking transaction log (loop1) REISERFS (device loop1): Using r5 hash to sort names REISERFS (device loop1): Created .reiserfs_priv - reserved for xattr storage. REISERFS (device loop1): found reiserfs format "3.6" with non-standard journal REISERFS (device loop1): using ordered data mode reiserfs: using flush barriers REISERFS (device loop1): journal params: device loop1, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 REISERFS (device loop1): checking transaction log (loop1) REISERFS (device loop1): Using r5 hash to sort names REISERFS (device loop1): Created .reiserfs_priv - reserved for xattr storage. F2FS-fs (loop2): invalid crc value F2FS-fs (loop2): Found nat_bits in checkpoint F2FS-fs (loop2): f2fs_check_nid_range: out-of-range nid=2, run fsck to fix. F2FS-fs (loop2): Mounted with checkpoint version = 48b305e4 overlayfs: unrecognized mount option "workd" or missing value REISERFS (device loop1): found reiserfs format "3.6" with non-standard journal REISERFS (device loop1): using ordered data mode reiserfs: using flush barriers REISERFS (device loop1): journal params: device loop1, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 REISERFS (device loop1): checking transaction log (loop1) REISERFS (device loop4): found reiserfs format "3.6" with non-standard journal REISERFS (device loop5): found reiserfs format "3.6" with non-standard journal REISERFS (device loop4): using ordered data mode REISERFS (device loop1): Using r5 hash to sort names REISERFS (device loop5): using ordered data mode REISERFS (device loop1): Created .reiserfs_priv - reserved for xattr storage. reiserfs: using flush barriers reiserfs: using flush barriers REISERFS (device loop5): journal params: device loop5, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 overlayfs: unrecognized mount option "workd" or missing value REISERFS (device loop5): checking transaction log (loop5) REISERFS (device loop4): journal params: device loop4, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 overlayfs: unrecognized mount option "workd" or missing value REISERFS (device loop4): checking transaction log (loop4) overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value REISERFS (device loop5): Using r5 hash to sort names overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value REISERFS (device loop4): Using r5 hash to sort names overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value REISERFS (device loop5): Created .reiserfs_priv - reserved for xattr storage. overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value REISERFS (device loop4): Created .reiserfs_priv - reserved for xattr storage. overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value kauditd_printk_skb: 21 callbacks suppressed audit: type=1804 audit(1674970313.894:547): pid=24088 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.5" name="/root/syzkaller-testdir3978681800/syzkaller.Oy8ODc/541/file1/bus" dev="loop5" ino=4 res=1 overlayfs: unrecognized mount option "workd" or missing value REISERFS (device loop1): found reiserfs format "3.6" with non-standard journal overlayfs: unrecognized mount option "workd" or missing value REISERFS (device loop1): using ordered data mode overlayfs: unrecognized mount option "workd" or missing value reiserfs: using flush barriers audit: type=1804 audit(1674970313.894:548): pid=24088 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=ToMToU comm="syz-executor.5" name="/root/syzkaller-testdir3978681800/syzkaller.Oy8ODc/541/file1/bus" dev="loop5" ino=4 res=1 REISERFS (device loop1): journal params: device loop1, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 overlayfs: unrecognized mount option "workd" or missing value overlayfs: unrecognized mount option "workd" or missing value REISERFS (device loop1): checking transaction log (loop1) audit: type=1804 audit(1674970313.944:549): pid=24085 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.4" name="/root/syzkaller-testdir378471692/syzkaller.dMrZZ6/553/file1/bus" dev="loop4" ino=4 res=1 audit: type=1804 audit(1674970313.954:550): pid=24085 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=ToMToU comm="syz-executor.4" name="/root/syzkaller-testdir378471692/syzkaller.dMrZZ6/553/file1/bus" dev="loop4" ino=4 res=1 REISERFS (device loop1): Using r5 hash to sort names REISERFS (device loop1): Created .reiserfs_priv - reserved for xattr storage. overlayfs: unrecognized mount option "workd" or missing value audit: type=1804 audit(1674970314.084:551): pid=24120 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=ToMToU comm="syz-executor.4" name="/root/syzkaller-testdir378471692/syzkaller.dMrZZ6/553/file1/bus" dev="loop4" ino=4 res=1 audit: type=1804 audit(1674970314.084:552): pid=24119 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=ToMToU comm="syz-executor.5" name="/root/syzkaller-testdir3978681800/syzkaller.Oy8ODc/541/file1/bus" dev="loop5" ino=4 res=1 REISERFS (device loop5): found reiserfs format "3.6" with non-standard journal REISERFS (device loop5): using ordered data mode reiserfs: using flush barriers REISERFS (device loop5): journal params: device loop5, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 audit: type=1804 audit(1674970314.364:553): pid=24111 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.1" name="/root/syzkaller-testdir2247647388/syzkaller.oOU5iq/529/file1/bus" dev="loop1" ino=4 res=1 REISERFS (device loop5): checking transaction log (loop5) REISERFS (device loop1): found reiserfs format "3.6" with non-standard journal audit: type=1804 audit(1674970314.364:554): pid=24111 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=ToMToU comm="syz-executor.1" name="/root/syzkaller-testdir2247647388/syzkaller.oOU5iq/529/file1/bus" dev="loop1" ino=4 res=1 REISERFS (device loop1): using ordered data mode reiserfs: using flush barriers REISERFS (device loop1): journal params: device loop1, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 audit: type=1804 audit(1674970314.494:555): pid=24138 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=ToMToU comm="syz-executor.1" name="/root/syzkaller-testdir2247647388/syzkaller.oOU5iq/529/file1/bus" dev="loop1" ino=4 res=1 REISERFS (device loop1): checking transaction log (loop1) REISERFS (device loop1): Using r5 hash to sort names REISERFS (device loop1): Created .reiserfs_priv - reserved for xattr storage. REISERFS (device loop5): Using r5 hash to sort names audit: type=1804 audit(1674970315.334:556): pid=24151 uid=0 auid=4294967295 ses=4294967295 subj==unconfined op=invalid_pcr cause=open_writers comm="syz-executor.1" name="/root/syzkaller-testdir2247647388/syzkaller.oOU5iq/530/file1/bus" dev="loop1" ino=4 res=1 REISERFS (device loop5): Created .reiserfs_priv - reserved for xattr storage. F2FS-fs (loop2): invalid crc value F2FS-fs (loop2): Found nat_bits in checkpoint F2FS-fs (loop2): f2fs_check_nid_range: out-of-range nid=2, run fsck to fix. F2FS-fs (loop2): Mounted with checkpoint version = 48b305e4 REISERFS (device loop1): found reiserfs format "3.6" with non-standard journal REISERFS (device loop1): using ordered data mode reiserfs: using flush barriers TCP: request_sock_TCP: Possible SYN flooding on port 20002. Sending cookies. Check SNMP counters. REISERFS (device loop1): journal params: device loop1, size 512, journal first block 18, max trans len 256, max batch 225, max commit age 30, max trans age 30 REISERFS (device loop1): checking transaction log (loop1) 9pnet: Insufficient options for proto=fd REISERFS (device loop1): Using r5 hash to sort names TCP: request_sock_TCP: Possible SYN flooding on port 20002. Sending cookies. Check SNMP counters. REISERFS (device loop1): Created .reiserfs_priv - reserved for xattr storage. F2FS-fs (loop2): invalid crc value F2FS-fs (loop2): Found nat_bits in checkpoint F2FS-fs (loop2): f2fs_check_nid_range: out-of-range nid=2, run fsck to fix. F2FS-fs (loop2): Mounted with checkpoint version = 48b305e4 netlink: 48 bytes leftover after parsing attributes in process `syz-executor.3'. TCP: request_sock_TCP: Possible SYN flooding on port 20002. Sending cookies. Check SNMP counters. REISERFS (device loop1): found reiserfs format "3.6" with non-standard journal netlink: 48 bytes leftover after parsing attributes in process `syz-executor.3'. REISERFS (device loop1): using ordered data mode 9pnet: Insufficient options for proto=fd reiserfs: using flush barriers