binder: 9616:9621 BC_CLEAR_DEATH_NOTIFICATION invalid ref 0 ====================================================== WARNING: possible circular locking dependency detected 4.15.0-rc4-mm1+ #49 Not tainted ------------------------------------------------------ syz-executor0/9634 is trying to acquire lock: (&pipe->mutex/1){+.+.}, at: [<00000000994ae687>] __pipe_lock fs/pipe.c:88 [inline] (&pipe->mutex/1){+.+.}, at: [<00000000994ae687>] fifo_open+0x15c/0xa30 fs/pipe.c:916 but task is already holding lock: (&sig->cred_guard_mutex){+.+.}, at: [<000000002a9214ac>] prepare_bprm_creds+0x53/0x110 fs/exec.c:1385 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #2 (&sig->cred_guard_mutex){+.+.}: __mutex_lock_common kernel/locking/mutex.c:756 [inline] __mutex_lock+0x16f/0x1a80 kernel/locking/mutex.c:893 mutex_lock_killable_nested+0x16/0x20 kernel/locking/mutex.c:923 do_io_accounting+0x1c2/0xf50 fs/proc/base.c:2711 proc_tgid_io_accounting+0x22/0x30 fs/proc/base.c:2760 proc_single_show+0xf8/0x170 fs/proc/base.c:746 seq_read+0x385/0x13d0 fs/seq_file.c:234 __vfs_read+0xef/0xa00 fs/read_write.c:411 vfs_read+0x11e/0x350 fs/read_write.c:447 SYSC_pread64 fs/read_write.c:611 [inline] SyS_pread64+0x15b/0x190 fs/read_write.c:598 entry_SYSCALL_64_fastpath+0x1f/0x96 -> #1 (&p->lock){+.+.}: __mutex_lock_common kernel/locking/mutex.c:756 [inline] __mutex_lock+0x16f/0x1a80 kernel/locking/mutex.c:893 mutex_lock_nested+0x16/0x20 kernel/locking/mutex.c:908 seq_read+0xd5/0x13d0 fs/seq_file.c:165 proc_reg_read+0xe8/0x160 fs/proc/inode.c:217 do_loop_readv_writev fs/read_write.c:673 [inline] do_iter_read+0x3d2/0x5a0 fs/read_write.c:897 vfs_readv+0x121/0x1c0 fs/read_write.c:959 kernel_readv fs/splice.c:361 [inline] default_file_splice_read+0x508/0xae0 fs/splice.c:416 do_splice_to+0x10a/0x160 fs/splice.c:880 do_splice fs/splice.c:1173 [inline] SYSC_splice fs/splice.c:1402 [inline] SyS_splice+0x1187/0x1610 fs/splice.c:1382 entry_SYSCALL_64_fastpath+0x1f/0x96 -> #0 (&pipe->mutex/1){+.+.}: lock_acquire+0x1d5/0x580 kernel/locking/lockdep.c:3914 __mutex_lock_common kernel/locking/mutex.c:756 [inline] __mutex_lock+0x16f/0x1a80 kernel/locking/mutex.c:893 mutex_lock_nested+0x16/0x20 kernel/locking/mutex.c:908 __pipe_lock fs/pipe.c:88 [inline] fifo_open+0x15c/0xa30 fs/pipe.c:916 do_dentry_open+0x667/0xd40 fs/open.c:752 vfs_open+0x107/0x220 fs/open.c:866 do_last fs/namei.c:3397 [inline] path_openat+0x1151/0x3530 fs/namei.c:3537 do_filp_open+0x25b/0x3b0 fs/namei.c:3572 do_open_execat+0x1b9/0x5c0 fs/exec.c:849 do_execveat_common.isra.30+0x90c/0x22a0 fs/exec.c:1736 do_execve fs/exec.c:1843 [inline] SYSC_execve fs/exec.c:1924 [inline] SyS_execve+0x39/0x50 fs/exec.c:1919 do_syscall_64+0x26c/0x920 arch/x86/entry/common.c:285 return_from_SYSCALL_64+0x0/0x75 other info that might help us debug this: Chain exists of: &pipe->mutex/1 --> &p->lock --> &sig->cred_guard_mutex Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&sig->cred_guard_mutex); lock(&p->lock); lock(&sig->cred_guard_mutex); lock(&pipe->mutex/1); *** DEADLOCK *** 1 lock held by syz-executor0/9634: #0: (&sig->cred_guard_mutex){+.+.}, at: [<000000002a9214ac>] prepare_bprm_creds+0x53/0x110 fs/exec.c:1385 stack backtrace: CPU: 0 PID: 9634 Comm: syz-executor0 Not tainted 4.15.0-rc4-mm1+ #49 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x194/0x257 lib/dump_stack.c:53 print_circular_bug.isra.37+0x2cd/0x2dc kernel/locking/lockdep.c:1218 check_prev_add kernel/locking/lockdep.c:1858 [inline] check_prevs_add kernel/locking/lockdep.c:1971 [inline] validate_chain kernel/locking/lockdep.c:2412 [inline] __lock_acquire+0x30a8/0x3e00 kernel/locking/lockdep.c:3426 lock_acquire+0x1d5/0x580 kernel/locking/lockdep.c:3914 __mutex_lock_common kernel/locking/mutex.c:756 [inline] __mutex_lock+0x16f/0x1a80 kernel/locking/mutex.c:893 mutex_lock_nested+0x16/0x20 kernel/locking/mutex.c:908 __pipe_lock fs/pipe.c:88 [inline] fifo_open+0x15c/0xa30 fs/pipe.c:916 do_dentry_open+0x667/0xd40 fs/open.c:752 vfs_open+0x107/0x220 fs/open.c:866 do_last fs/namei.c:3397 [inline] path_openat+0x1151/0x3530 fs/namei.c:3537 do_filp_open+0x25b/0x3b0 fs/namei.c:3572 do_open_execat+0x1b9/0x5c0 fs/exec.c:849 do_execveat_common.isra.30+0x90c/0x22a0 fs/exec.c:1736 do_execve fs/exec.c:1843 [inline] SYSC_execve fs/exec.c:1924 [inline] SyS_execve+0x39/0x50 fs/exec.c:1919 do_syscall_64+0x26c/0x920 arch/x86/entry/common.c:285 entry_SYSCALL64_slow_path+0x25/0x25 RIP: 0033:0x452ac9 RSP: 002b:00007ff8d9536c58 EFLAGS: 00000212 ORIG_RAX: 000000000000003b RAX: ffffffffffffffda RBX: 000000000071bea0 RCX: 0000000000452ac9 RDX: 0000000020435000 RSI: 0000000020475ff8 RDI: 0000000020c0bff8 RBP: 0000000000000066 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000212 R12: 00000000006eda30 R13: 00000000ffffffff R14: 00007ff8d95376d4 R15: 0000000000000000 binder: 9616:9631 BC_REQUEST_DEATH_NOTIFICATION invalid ref 0 binder: 9621 RLIMIT_NICE not set binder: 9616:9649 BC_DEAD_BINDER_DONE 0000000000000003 not found binder: 9616:9631 Acquire 1 refcount change on invalid ref 0 ret -22 binder: 9616:9649 BC_REQUEST_DEATH_NOTIFICATION invalid ref 0 binder: 9616:9631 BC_CLEAR_DEATH_NOTIFICATION invalid ref 0 binder: 9631 RLIMIT_NICE not set binder: 9616:9631 BC_DEAD_BINDER_DONE 0000000000000003 not found device gre0 entered promiscuous mode kauditd_printk_skb: 279 callbacks suppressed audit: type=1326 audit(1514403629.863:814): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=9869 comm="syz-executor4" exe="/root/syz-executor4" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403629.863:815): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=9869 comm="syz-executor4" exe="/root/syz-executor4" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403629.864:816): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=9869 comm="syz-executor4" exe="/root/syz-executor4" sig=0 arch=c000003e syscall=55 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403629.864:817): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=9869 comm="syz-executor4" exe="/root/syz-executor4" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403629.870:818): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=9869 comm="syz-executor4" exe="/root/syz-executor4" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403629.870:819): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=9869 comm="syz-executor4" exe="/root/syz-executor4" sig=0 arch=c000003e syscall=188 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403629.870:820): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=9869 comm="syz-executor4" exe="/root/syz-executor4" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403629.870:821): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=9869 comm="syz-executor4" exe="/root/syz-executor4" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403629.870:822): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=9869 comm="syz-executor4" exe="/root/syz-executor4" sig=0 arch=c000003e syscall=257 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403629.870:823): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=9869 comm="syz-executor4" exe="/root/syz-executor4" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 Bearer <> rejected, not supported in standalone mode Bearer <> rejected, not supported in standalone mode device gre0 entered promiscuous mode device gre0 left promiscuous mode device gre0 entered promiscuous mode netlink: 3 bytes leftover after parsing attributes in process `syz-executor1'. netlink: 4 bytes leftover after parsing attributes in process `syz-executor3'. QAT: Invalid ioctl netlink: 3 bytes leftover after parsing attributes in process `syz-executor1'. netlink: 4 bytes leftover after parsing attributes in process `syz-executor3'. QAT: Invalid ioctl netlink: 11 bytes leftover after parsing attributes in process `syz-executor6'. netlink: 11 bytes leftover after parsing attributes in process `syz-executor6'. binder: 10207:10213 ERROR: BC_REGISTER_LOOPER called without request binder: 10213 RLIMIT_NICE not set binder: 10207:10213 ioctl c0306201 204edfd0 returned -11 binder: 10207:10223 ioctl c0306201 20007000 returned -11 binder: 10207:10238 got reply transaction with no transaction stack binder: 10207:10238 transaction failed 29201/-71, size 0-0 line 2760 binder: release 10207:10223 transaction 49 out, still active binder: 10207:10238 ERROR: BC_REGISTER_LOOPER called without request binder: 10238 RLIMIT_NICE not set binder_alloc: 10207: binder_alloc_buf, no vma binder: 10207:10223 transaction failed 29189/-3, size 0-0 line 2960 binder: 10207:10223 got reply transaction with no transaction stack binder: 10207:10223 transaction failed 29201/-71, size 0-0 line 2760 binder: undelivered TRANSACTION_COMPLETE binder: undelivered TRANSACTION_ERROR: 29201 binder: send failed reply for transaction 49, target dead binder: undelivered TRANSACTION_ERROR: 29201 MPI: mpi too large (16392 bits) device gre0 entered promiscuous mode RDS: rds_bind could not find a transport for 172.20.5.187, load rds_tcp or rds_rdma? RDS: rds_bind could not find a transport for 172.20.5.187, load rds_tcp or rds_rdma? QAT: Invalid ioctl QAT: Invalid ioctl SELinux: unrecognized netlink message: protocol=0 nlmsg_type=0 sclass=netlink_route_socket pig=10576 comm=syz-executor0 QAT: Invalid ioctl QAT: Invalid ioctl QAT: Invalid ioctl QAT: Invalid ioctl SELinux: unrecognized netlink message: protocol=0 nlmsg_type=0 sclass=netlink_route_socket pig=10584 comm=syz-executor0 encrypted_key: insufficient parameters specified device gre0 entered promiscuous mode 8021q: VLANs not supported on lo FAULT_INJECTION: forcing a failure. name failslab, interval 1, probability 0, space 0, times 1 CPU: 1 PID: 10725 Comm: syz-executor2 Not tainted 4.15.0-rc4-mm1+ #49 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x194/0x257 lib/dump_stack.c:53 fail_dump lib/fault-inject.c:51 [inline] should_fail+0x8c0/0xa40 lib/fault-inject.c:149 should_failslab+0xec/0x120 mm/failslab.c:32 slab_pre_alloc_hook mm/slab.h:422 [inline] slab_alloc mm/slab.c:3365 [inline] kmem_cache_alloc+0x47/0x760 mm/slab.c:3539 kmem_cache_zalloc include/linux/slab.h:695 [inline] locks_alloc_lock+0x86/0x260 fs/locks.c:312 fcntl_getlk+0x6f/0x850 fs/locks.c:2126 do_fcntl+0x813/0x1150 fs/fcntl.c:356 SYSC_fcntl fs/fcntl.c:463 [inline] SyS_fcntl+0xd6/0x110 fs/fcntl.c:448 entry_SYSCALL_64_fastpath+0x1f/0x96 RIP: 0033:0x452ac9 RSP: 002b:00007fdab3466c58 EFLAGS: 00000212 ORIG_RAX: 0000000000000048 RAX: ffffffffffffffda RBX: 00007fdab3466aa0 RCX: 0000000000452ac9 RDX: 0000000020010000 RSI: 0000000000000024 RDI: 0000000000000015 RBP: 00007fdab3466a90 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000212 R12: 00000000004b767b R13: 00007fdab3466bc8 R14: 00000000004b767b R15: 0000000000000000 8021q: VLANs not supported on lo device gre0 entered promiscuous mode QAT: Invalid ioctl QAT: Invalid ioctl irq bypass consumer (token 00000000b5d2c673) registration fails: -16 device gre0 entered promiscuous mode device gre0 entered promiscuous mode device gre0 entered promiscuous mode kauditd_printk_skb: 140 callbacks suppressed audit: type=1326 audit(1514403635.314:964): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=11192 comm="syz-executor3" exe="/root/syz-executor3" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 device gre0 entered promiscuous mode audit: type=1326 audit(1514403635.315:965): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=11192 comm="syz-executor3" exe="/root/syz-executor3" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403635.315:966): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=11192 comm="syz-executor3" exe="/root/syz-executor3" sig=0 arch=c000003e syscall=72 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403635.315:967): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=11192 comm="syz-executor3" exe="/root/syz-executor3" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403635.316:968): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=11192 comm="syz-executor3" exe="/root/syz-executor3" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403635.316:969): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=11192 comm="syz-executor3" exe="/root/syz-executor3" sig=0 arch=c000003e syscall=73 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403635.316:970): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=11192 comm="syz-executor3" exe="/root/syz-executor3" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403635.316:971): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=11192 comm="syz-executor3" exe="/root/syz-executor3" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403635.316:972): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=11192 comm="syz-executor3" exe="/root/syz-executor3" sig=0 arch=c000003e syscall=267 compat=0 ip=0x452ac9 code=0x7ffc0000 audit: type=1326 audit(1514403635.316:973): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=11192 comm="syz-executor3" exe="/root/syz-executor3" sig=0 arch=c000003e syscall=202 compat=0 ip=0x452ac9 code=0x7ffc0000 device ip6tnl0 entered promiscuous mode device ip6tnl0 left promiscuous mode device gre0 entered promiscuous mode device gre0 entered promiscuous mode binder: 11634:11639 got reply transaction with no transaction stack binder: 11634:11639 transaction failed 29201/-71, size 64-56 line 2760 binder: 11634:11639 got reply transaction with no transaction stack binder: 11634:11639 transaction failed 29201/-71, size 64-56 line 2760 binder: undelivered TRANSACTION_ERROR: 29201 binder: undelivered TRANSACTION_ERROR: 29201 SELinux: unrecognized netlink message: protocol=6 nlmsg_type=82 sclass=netlink_xfrm_socket pig=11736 comm=syz-executor1 SELinux: unrecognized netlink message: protocol=6 nlmsg_type=82 sclass=netlink_xfrm_socket pig=11736 comm=syz-executor1 FAULT_INJECTION: forcing a failure. name failslab, interval 1, probability 0, space 0, times 0 CPU: 1 PID: 11805 Comm: syz-executor4 Not tainted 4.15.0-rc4-mm1+ #49 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x194/0x257 lib/dump_stack.c:53 fail_dump lib/fault-inject.c:51 [inline] should_fail+0x8c0/0xa40 lib/fault-inject.c:149 should_failslab+0xec/0x120 mm/failslab.c:32 slab_pre_alloc_hook mm/slab.h:422 [inline] slab_alloc mm/slab.c:3365 [inline] kmem_cache_alloc+0x47/0x760 mm/slab.c:3539 ptlock_alloc+0x24/0x70 mm/memory.c:4696 ptlock_init include/linux/mm.h:1796 [inline] pgtable_page_ctor include/linux/mm.h:1830 [inline] pte_alloc_one+0x59/0x100 arch/x86/mm/pgtable.c:32 do_huge_pmd_anonymous_page+0xc20/0x1b00 mm/huge_memory.c:689 create_huge_pmd mm/memory.c:3838 [inline] __handle_mm_fault+0x1a0c/0x3ce0 mm/memory.c:4042 handle_mm_fault+0x38f/0x930 mm/memory.c:4108 __do_page_fault+0x5c9/0xc90 arch/x86/mm/fault.c:1429 do_page_fault+0xee/0x720 arch/x86/mm/fault.c:1504 page_fault+0x2c/0x60 arch/x86/entry/entry_64.S:1243 RIP: 0010:copy_user_generic_unrolled+0x9e/0xc0 arch/x86/lib/copy_user_64.S:74 RSP: 0018:ffff8801c08e79c0 EFLAGS: 00010202 RAX: 0000000000000001 RBX: 0000000020516007 RCX: 0000000000000001 RDX: 0000000000000001 RSI: 0000000020516007 RDI: ffff8801c08e7a70 RBP: ffff8801c08e79f0 R08: ffffed003811cf4e R09: ffffed003811cf4e R10: 0000000000000001 R11: ffffed003811cf4e R12: 0000000000000001 R13: ffff8801c08e7a70 R14: 00007ffffffff000 R15: 0000000020516008 copy_from_user include/linux/uaccess.h:147 [inline] sg_ioctl+0x1dcc/0x2d90 drivers/scsi/sg.c:1073 vfs_ioctl fs/ioctl.c:46 [inline] do_vfs_ioctl+0x1b1/0x1520 fs/ioctl.c:686 SYSC_ioctl fs/ioctl.c:701 [inline] SyS_ioctl+0x8f/0xc0 fs/ioctl.c:692 entry_SYSCALL_64_fastpath+0x1f/0x96 RIP: 0033:0x452ac9 RSP: 002b:00007ffbc619cc58 EFLAGS: 00000212 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 000000000071bea0 RCX: 0000000000452ac9 RDX: 0000000020515fff RSI: 0000000100000001 RDI: 0000000000000014 RBP: 000000000000039b R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000212 R12: 00000000006f2728 R13: 00000000ffffffff R14: 00007ffbc619d6d4 R15: 0000000000000000 QAT: Invalid ioctl QAT: Invalid ioctl