====================================================== WARNING: possible circular locking dependency detected 4.19.211-syzkaller #0 Not tainted ------------------------------------------------------ syz-executor.4/3758 is trying to acquire lock: 0000000097839719 (&pipe->mutex/1){+.+.}, at: pipe_lock_nested fs/pipe.c:77 [inline] 0000000097839719 (&pipe->mutex/1){+.+.}, at: pipe_lock+0x63/0x80 fs/pipe.c:85 but task is already holding lock: 000000002ca0dbc0 (sb_writers#3){.+.+}, at: file_start_write include/linux/fs.h:2779 [inline] 000000002ca0dbc0 (sb_writers#3){.+.+}, at: do_splice fs/splice.c:1153 [inline] 000000002ca0dbc0 (sb_writers#3){.+.+}, at: __do_sys_splice fs/splice.c:1428 [inline] 000000002ca0dbc0 (sb_writers#3){.+.+}, at: __se_sys_splice+0x11de/0x16d0 fs/splice.c:1408 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #2 (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 -> #1 (&ovl_i_mutex_key[depth]){+.+.}: 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 -> #0 (&pipe->mutex/1){+.+.}: __mutex_lock_common kernel/locking/mutex.c:937 [inline] __mutex_lock+0xd7/0x1190 kernel/locking/mutex.c:1078 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 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: &pipe->mutex/1 --> &ovl_i_mutex_key[depth] --> sb_writers#3 Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(sb_writers#3); lock(&ovl_i_mutex_key[depth]); lock(sb_writers#3); lock(&pipe->mutex/1); *** DEADLOCK *** 1 lock held by syz-executor.4/3758: #0: 000000002ca0dbc0 (sb_writers#3){.+.+}, at: file_start_write include/linux/fs.h:2779 [inline] #0: 000000002ca0dbc0 (sb_writers#3){.+.+}, at: do_splice fs/splice.c:1153 [inline] #0: 000000002ca0dbc0 (sb_writers#3){.+.+}, at: __do_sys_splice fs/splice.c:1428 [inline] #0: 000000002ca0dbc0 (sb_writers#3){.+.+}, at: __se_sys_splice+0x11de/0x16d0 fs/splice.c:1408 stack backtrace: CPU: 1 PID: 3758 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 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 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:0x7fd63e91f0d9 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:00007fd63ce91168 EFLAGS: 00000246 ORIG_RAX: 0000000000000113 RAX: ffffffffffffffda RBX: 00007fd63ea3ef80 RCX: 00007fd63e91f0d9 RDX: 0000000000000005 RSI: 0000000000000000 RDI: 0000000000000003 RBP: 00007fd63e97aae9 R08: 00000000ffffffe1 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffdbe50df0f R14: 00007fd63ce91300 R15: 0000000000022000 netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond133 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond133: link is not ready 8021q: adding VLAN 0 to HW filter on device bond133 bond133: The slave device specified does not support setting the MAC address netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond134 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond134: link is not ready 8021q: adding VLAN 0 to HW filter on device bond134 bond134: The slave device specified does not support setting the MAC address netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond135 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond135: link is not ready 8021q: adding VLAN 0 to HW filter on device bond135 bond135: The slave device specified does not support setting the MAC address netlink: 12 bytes leftover after parsing attributes in process `syz-executor.4'. device bond1 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond1: link is not ready 8021q: adding VLAN 0 to HW filter on device bond1 bond1: The slave device specified does not support setting the MAC address netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond136 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond136: link is not ready 8021q: adding VLAN 0 to HW filter on device bond136 bond136: The slave device specified does not support setting the MAC address netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond137 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond137: link is not ready 8021q: adding VLAN 0 to HW filter on device bond137 netlink: 12 bytes leftover after parsing attributes in process `syz-executor.4'. device bond2 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond2: link is not ready 8021q: adding VLAN 0 to HW filter on device bond2 bond137: The slave device specified does not support setting the MAC address bond2: The slave device specified does not support setting the MAC address netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond138 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond138: link is not ready 8021q: adding VLAN 0 to HW filter on device bond138 device bond3 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond3: link is not ready 8021q: adding VLAN 0 to HW filter on device bond3 bond138: The slave device specified does not support setting the MAC address bond3: The slave device specified does not support setting the MAC address device bond139 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond139: link is not ready 8021q: adding VLAN 0 to HW filter on device bond139 bond139: The slave device specified does not support setting the MAC address nla_parse: 2 callbacks suppressed netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond140 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond140: link is not ready 8021q: adding VLAN 0 to HW filter on device bond140 bond140: The slave device specified does not support setting the MAC address netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond141 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond141: link is not ready 8021q: adding VLAN 0 to HW filter on device bond141 netlink: 12 bytes leftover after parsing attributes in process `syz-executor.4'. bond4 (uninitialized): Released all slaves bond141: The slave device specified does not support setting the MAC address netlink: 12 bytes leftover after parsing attributes in process `syz-executor.4'. bond4 (uninitialized): Released all slaves netlink: 12 bytes leftover after parsing attributes in process `syz-executor.4'. bond4 (uninitialized): Released all slaves netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond142 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond142: link is not ready 8021q: adding VLAN 0 to HW filter on device bond142 bond142: The slave device specified does not support setting the MAC address netlink: 12 bytes leftover after parsing attributes in process `syz-executor.4'. device bond4 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond4: link is not ready 8021q: adding VLAN 0 to HW filter on device bond4 netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond143 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond143: link is not ready 8021q: adding VLAN 0 to HW filter on device bond143 bond143: The slave device specified does not support setting the MAC address netlink: 12 bytes leftover after parsing attributes in process `syz-executor.4'. device bond5 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond5: link is not ready 8021q: adding VLAN 0 to HW filter on device bond5 netlink: 12 bytes leftover after parsing attributes in process `syz-executor.4'. device bond6 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond6: link is not ready 8021q: adding VLAN 0 to HW filter on device bond6 device bond144 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond144: link is not ready 8021q: adding VLAN 0 to HW filter on device bond144 bond144: The slave device specified does not support setting the MAC address bond7 (uninitialized): Released all slaves device bond145 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond145: link is not ready 8021q: adding VLAN 0 to HW filter on device bond145 bond145: The slave device specified does not support setting the MAC address bond7 (uninitialized): Released all slaves device bond146 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond146: link is not ready 8021q: adding VLAN 0 to HW filter on device bond146 bond7 (uninitialized): Released all slaves bond146: The slave device specified does not support setting the MAC address device bond147 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond147: link is not ready 8021q: adding VLAN 0 to HW filter on device bond147 bond147: The slave device specified does not support setting the MAC address device bond148 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond148: link is not ready 8021q: adding VLAN 0 to HW filter on device bond148 bond148: The slave device specified does not support setting the MAC address device bond149 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond149: link is not ready 8021q: adding VLAN 0 to HW filter on device bond149 bond149: The slave device specified does not support setting the MAC address device bond7 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond7: link is not ready 8021q: adding VLAN 0 to HW filter on device bond7 device bond150 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond150: link is not ready 8021q: adding VLAN 0 to HW filter on device bond150 bond150: The slave device specified does not support setting the MAC address device bond8 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond8: link is not ready 8021q: adding VLAN 0 to HW filter on device bond8 device bond1 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond1: link is not ready 8021q: adding VLAN 0 to HW filter on device bond1 bond1: The slave device specified does not support setting the MAC address device bond151 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond151: link is not ready 8021q: adding VLAN 0 to HW filter on device bond151 bond151: The slave device specified does not support setting the MAC address device bond9 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond9: link is not ready 8021q: adding VLAN 0 to HW filter on device bond9 device bond2 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond2: link is not ready 8021q: adding VLAN 0 to HW filter on device bond2 nla_parse: 16 callbacks suppressed netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond152 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond152: link is not ready 8021q: adding VLAN 0 to HW filter on device bond152 netlink: 12 bytes leftover after parsing attributes in process `syz-executor.4'. bond10 (uninitialized): Released all slaves bond152: The slave device specified does not support setting the MAC address netlink: 12 bytes leftover after parsing attributes in process `syz-executor.4'. bond10 (uninitialized): Released all slaves netlink: 12 bytes leftover after parsing attributes in process `syz-executor.0'. device bond3 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond3: link is not ready 8021q: adding VLAN 0 to HW filter on device bond3 netlink: 12 bytes leftover after parsing attributes in process `syz-executor.2'. device bond153 entered promiscuous mode IPv6: ADDRCONF(NETDEV_UP): bond153: link is not ready 8021q: adding VLAN 0 to HW filter on device bond153 bond3: The slave device specified does not support setting the MAC address