====================================================== [ INFO: possible circular locking dependency detected ] 4.4.120-gd63fdf6 #29 Not tainted ------------------------------------------------------- syz-executor7/6847 is trying to acquire lock: audit: type=1400 audit(1521786924.605:17): avc: denied { relabelto } for pid=6853 comm="syz-executor4" name="UDPv6" dev="sockfs" ino=15168 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:netcontrol_device_t:s0 tclass=udp_socket permissive=1 audit: type=1400 audit(1521786924.605:18): avc: denied { ioctl } for pid=6853 comm="syz-executor4" path="socket:[15168]" dev="sockfs" ino=15168 ioctlcmd=8916 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:netcontrol_device_t:s0 tclass=sock_file permissive=1 (&sb->s_type->i_mutex_key#10){+.+.+.}, at: [] shmem_file_llseek+0xf1/0x240 mm/shmem.c:1816 but task is already holding lock: (ashmem_mutex){+.+.+.}, at: [] ashmem_llseek+0x56/0x1f0 drivers/staging/android/ashmem.c:330 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: [] lock_acquire+0x15e/0x460 kernel/locking/lockdep.c:3592 [] __mutex_lock_common kernel/locking/mutex.c:521 [inline] [] mutex_lock_nested+0xbb/0x850 kernel/locking/mutex.c:621 [] ashmem_mmap+0x53/0x400 drivers/staging/android/ashmem.c:366 [] mmap_region+0x94f/0x1250 mm/mmap.c:1664 [] do_mmap+0x4fd/0x9d0 mm/mmap.c:1441 [] do_mmap_pgoff include/linux/mm.h:1915 [inline] [] vm_mmap_pgoff+0x16e/0x1c0 mm/util.c:296 [] SYSC_mmap_pgoff mm/mmap.c:1491 [inline] [] SyS_mmap_pgoff+0x33f/0x560 mm/mmap.c:1449 [] do_syscall_32_irqs_on arch/x86/entry/common.c:392 [inline] [] do_fast_syscall_32+0x321/0x8a0 arch/x86/entry/common.c:459 [] sysenter_flags_fixed+0xd/0x17 [] lock_acquire+0x15e/0x460 kernel/locking/lockdep.c:3592 [] __might_fault+0x14a/0x1d0 mm/memory.c:3810 [] copy_to_user arch/x86/include/asm/uaccess.h:760 [inline] [] filldir+0x162/0x2d0 fs/readdir.c:180 [] dir_emit_dot include/linux/fs.h:3070 [inline] [] dir_emit_dots include/linux/fs.h:3081 [inline] [] dcache_readdir+0x11e/0x7b0 fs/libfs.c:150 [] iterate_dir+0x1c8/0x420 fs/readdir.c:42 [] SYSC_getdents fs/readdir.c:215 [inline] [] SyS_getdents+0x14a/0x270 fs/readdir.c:196 [] entry_SYSCALL_64_fastpath+0x1c/0x98 [] check_prev_add kernel/locking/lockdep.c:1853 [inline] [] check_prevs_add kernel/locking/lockdep.c:1958 [inline] [] validate_chain kernel/locking/lockdep.c:2144 [inline] [] __lock_acquire+0x371f/0x4b50 kernel/locking/lockdep.c:3213 [] lock_acquire+0x15e/0x460 kernel/locking/lockdep.c:3592 [] __mutex_lock_common kernel/locking/mutex.c:521 [inline] [] mutex_lock_nested+0xbb/0x850 kernel/locking/mutex.c:621 [] shmem_file_llseek+0xf1/0x240 mm/shmem.c:1816 [] vfs_llseek+0xa2/0xd0 fs/read_write.c:260 [] ashmem_llseek+0xe7/0x1f0 drivers/staging/android/ashmem.c:342 [] vfs_llseek fs/read_write.c:260 [inline] [] SYSC_lseek fs/read_write.c:285 [inline] [] SyS_lseek fs/read_write.c:276 [inline] [] C_SYSC_lseek fs/read_write.c:297 [inline] [] compat_SyS_lseek+0xeb/0x170 fs/read_write.c:295 [] do_syscall_32_irqs_on arch/x86/entry/common.c:392 [inline] [] do_fast_syscall_32+0x321/0x8a0 arch/x86/entry/common.c:459 [] sysenter_flags_fixed+0xd/0x17 other info that might help us debug this: Chain exists of: Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(ashmem_mutex); lock(&mm->mmap_sem); lock(ashmem_mutex); lock(&sb->s_type->i_mutex_key#10); *** DEADLOCK *** 1 lock held by syz-executor7/6847: #0: (ashmem_mutex){+.+.+.}, at: [] ashmem_llseek+0x56/0x1f0 drivers/staging/android/ashmem.c:330 stack backtrace: CPU: 0 PID: 6847 Comm: syz-executor7 Not tainted 4.4.120-gd63fdf6 #29 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 0000000000000000 049669f5b6a1fd3c ffff8800b8dcfa58 ffffffff81d0408d ffffffff8519fe60 ffffffff851a99a0 ffffffff851be970 ffff8800b95188f8 ffff8800b9518000 ffff8800b8dcfaa0 ffffffff81233ba1 ffff8800b95188f8 Call Trace: [] __dump_stack lib/dump_stack.c:15 [inline] [] dump_stack+0xc1/0x124 lib/dump_stack.c:51 [] print_circular_bug+0x271/0x310 kernel/locking/lockdep.c:1226 [] check_prev_add kernel/locking/lockdep.c:1853 [inline] [] check_prevs_add kernel/locking/lockdep.c:1958 [inline] [] validate_chain kernel/locking/lockdep.c:2144 [inline] [] __lock_acquire+0x371f/0x4b50 kernel/locking/lockdep.c:3213 [] lock_acquire+0x15e/0x460 kernel/locking/lockdep.c:3592 [] __mutex_lock_common kernel/locking/mutex.c:521 [inline] [] mutex_lock_nested+0xbb/0x850 kernel/locking/mutex.c:621 [] shmem_file_llseek+0xf1/0x240 mm/shmem.c:1816 [] vfs_llseek+0xa2/0xd0 fs/read_write.c:260 [] ashmem_llseek+0xe7/0x1f0 drivers/staging/android/ashmem.c:342 [] vfs_llseek fs/read_write.c:260 [inline] [] SYSC_lseek fs/read_write.c:285 [inline] [] SyS_lseek fs/read_write.c:276 [inline] [] C_SYSC_lseek fs/read_write.c:297 [inline] [] compat_SyS_lseek+0xeb/0x170 fs/read_write.c:295 [] do_syscall_32_irqs_on arch/x86/entry/common.c:392 [inline] [] do_fast_syscall_32+0x321/0x8a0 arch/x86/entry/common.c:459 [] sysenter_flags_fixed+0xd/0x17 capability: warning: `syz-executor5' uses deprecated v2 capabilities in a way that may be insecure audit: type=1400 audit(1521786925.255:19): avc: denied { ioctl } for pid=6900 comm="syz-executor3" path="socket:[15277]" dev="sockfs" ino=15277 ioctlcmd=6419 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_netfilter_socket permissive=1 TCP: request_sock_TCP: Possible SYN flooding on port 20002. Sending cookies. Check SNMP counters. PF_BRIDGE: RTM_SETLINK with unknown ifindex PF_BRIDGE: RTM_SETLINK with unknown ifindex syz-executor2 (7108): /proc/7104/oom_adj is deprecated, please use /proc/7104/oom_score_adj instead. TCP: request_sock_TCP: Possible SYN flooding on port 20002. Sending cookies. Check SNMP counters. audit: type=1400 audit(1521786926.205:20): avc: denied { create } for pid=7197 comm="syz-executor5" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:unlabeled_t:s0 tclass=key permissive=1 BUG: using __this_cpu_read() in preemptible [00000000] code: syz-executor7/7276 caller is __this_cpu_preempt_check+0x1c/0x20 lib/smp_processor_id.c:62 CPU: 1 PID: 7276 Comm: syz-executor7 Not tainted 4.4.120-gd63fdf6 #29 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 0000000000000000 b63462080e613def ffff8800b6e9f648 ffffffff81d0408d 0000000000000001 ffffffff839fe5a0 ffffffff83d0be20 ffff8801d3931800 0000000000000003 ffff8800b6e9f688 ffffffff81d63fe4 ffff8800b6e9f6a0 Call Trace: [] __dump_stack lib/dump_stack.c:15 [inline] [] dump_stack+0xc1/0x124 lib/dump_stack.c:51 [] check_preemption_disabled+0x1d4/0x200 lib/smp_processor_id.c:46 [] __this_cpu_preempt_check+0x1c/0x20 lib/smp_processor_id.c:62 [] ipcomp_alloc_tfms net/xfrm/xfrm_ipcomp.c:286 [inline] [] ipcomp_init_state+0x188/0x980 net/xfrm/xfrm_ipcomp.c:363 [] ipcomp4_init_state+0xb0/0x7d0 net/ipv4/ipcomp.c:137 [] __xfrm_init_state+0x3e7/0xb30 net/xfrm/xfrm_state.c:2058 [] xfrm_init_state+0x1a/0x20 net/xfrm/xfrm_state.c:2084 [] pfkey_msg2xfrm_state net/key/af_key.c:1289 [inline] [] pfkey_add+0x1fbb/0x3490 net/key/af_key.c:1506 [] pfkey_process+0x68b/0x750 net/key/af_key.c:2834 [] pfkey_sendmsg+0x3a9/0x760 net/key/af_key.c:3678 [] sock_sendmsg_nosec net/socket.c:625 [inline] [] sock_sendmsg+0xca/0x110 net/socket.c:635 [] ___sys_sendmsg+0x6c1/0x7c0 net/socket.c:1962 [] __sys_sendmsg+0xd3/0x190 net/socket.c:1996 [] C_SYSC_sendmsg net/compat.c:720 [inline] [] compat_SyS_sendmsg+0x2a/0x40 net/compat.c:718 [] do_syscall_32_irqs_on arch/x86/entry/common.c:392 [inline] [] do_fast_syscall_32+0x321/0x8a0 arch/x86/entry/common.c:459 [] sysenter_flags_fixed+0xd/0x17 vmalloc: allocation failure: 0 bytes syz-executor4: page allocation failure: order:0, mode:0x24000c2 CPU: 0 PID: 7322 Comm: syz-executor4 Not tainted 4.4.120-gd63fdf6 #29 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 0000000000000000 d44cd0d9cffbd5e1 ffff8801c33a7898 ffffffff81d0408d 1ffff10038674f16 ffff8801d3cc6000 00000000024000c2 0000000000000000 0000000000000001 ffff8801c33a79a8 ffffffff81431059 ffffffff838ac620 Call Trace: [] __dump_stack lib/dump_stack.c:15 [inline] [] dump_stack+0xc1/0x124 lib/dump_stack.c:51 [] warn_alloc_failed+0x1d9/0x240 mm/page_alloc.c:2757 [] __vmalloc_node_range+0x41d/0x630 mm/vmalloc.c:1692 [] __vmalloc_node mm/vmalloc.c:1715 [inline] [] __vmalloc_node_flags mm/vmalloc.c:1729 [inline] [] vmalloc+0x5b/0x70 mm/vmalloc.c:1744 [] sel_write_load+0x130/0xff0 security/selinux/selinuxfs.c:527 audit: type=1326 audit(1521786927.455:21): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=7351 comm="syz-executor1" exe="/root/syz-executor1" sig=31 arch=40000003 syscall=240 compat=1 ip=0xf77bbba9 code=0x0 [] __vfs_write+0x103/0x450 fs/read_write.c:489 audit: type=1326 audit(1521786927.525:22): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=7351 comm="syz-executor1" exe="/root/syz-executor1" sig=31 arch=40000003 syscall=240 compat=1 ip=0xf77bbba9 code=0x0 [] vfs_write+0x18a/0x530 fs/read_write.c:538 [] SYSC_pwrite64 fs/read_write.c:627 [inline] [] SyS_pwrite64+0x13f/0x170 fs/read_write.c:614 [] sys32_pwrite+0x39/0x50 arch/x86/ia32/sys_ia32.c:186 [] do_syscall_32_irqs_on arch/x86/entry/common.c:392 [inline] [] do_fast_syscall_32+0x321/0x8a0 arch/x86/entry/common.c:459 [] sysenter_flags_fixed+0xd/0x17 Mem-Info: active_anon:51838 inactive_anon:44 isolated_anon:0 active_file:3529 inactive_file:8469 isolated_file:0 unevictable:0 dirty:93 writeback:0 unstable:0 slab_reclaimable:6026 slab_unreclaimable:59455 mapped:23820 shmem:51 pagetables:610 bounce:0 free:1476320 free_pcp:503 free_cma:0 DMA free:15904kB min:160kB low:200kB high:240kB active_anon:0kB inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:0kB isolated(anon):0kB isolated(file):0kB present:15992kB managed:15904kB mlocked:0kB dirty:0kB writeback:0kB mapped:0kB shmem:0kB slab_reclaimable:0kB slab_unreclaimable:0kB kernel_stack:0kB pagetables:0kB unstable:0kB bounce:0kB free_pcp:0kB local_pcp:0kB free_cma:0kB writeback_tmp:0kB pages_scanned:0 all_unreclaimable? yes lowmem_reserve[]: 0 2911 6411 6411 DMA32 free:2676576kB min:30608kB low:38260kB high:45912kB active_anon:90816kB inactive_anon:92kB active_file:6400kB inactive_file:17052kB unevictable:0kB isolated(anon):0kB isolated(file):0kB present:3129292kB managed:2982732kB mlocked:0kB dirty:128kB writeback:0kB mapped:47264kB shmem:96kB slab_reclaimable:11172kB slab_unreclaimable:110492kB kernel_stack:2656kB pagetables:900kB unstable:0kB bounce:0kB free_pcp:800kB local_pcp:164kB free_cma:0kB writeback_tmp:0kB pages_scanned:0 all_unreclaimable? no lowmem_reserve[]: 0 0 3500 3500 Normal free:3213424kB min:36808kB low:46008kB high:55212kB active_anon:116536kB inactive_anon:84kB active_file:7716kB inactive_file:16824kB unevictable:0kB isolated(anon):0kB isolated(file):0kB present:4718592kB managed:3584660kB mlocked:0kB dirty:260kB writeback:0kB mapped:48016kB shmem:108kB slab_reclaimable:12932kB slab_unreclaimable:127148kB kernel_stack:4000kB pagetables:1540kB unstable:0kB bounce:0kB free_pcp:1200kB local_pcp:488kB free_cma:0kB writeback_tmp:0kB pages_scanned:0 all_unreclaimable? no lowmem_reserve[]: 0 0 0 0 DMA: 0*4kB 0*8kB 0*16kB 1*32kB (U) 2*64kB (U) 1*128kB (U) 1*256kB (U) 0*512kB 1*1024kB (U) 1*2048kB (M) 3*4096kB (M) = 15904kB DMA32: 193*4kB (UME) 88*8kB (UME) 102*16kB (UM) 82*32kB (UME) 35*64kB (UME) 26*128kB (UM) 17*256kB (UME) 16*512kB (UME) 28*1024kB (M) 4*2048kB (UM) 639*4096kB (M) = 2678052kB Normal: 232*4kB (UME) 118*8kB (UME) 108*16kB (UME) 104*32kB (UME) 80*64kB (UME) 27*128kB (UM) 18*256kB (M) 11*512kB (UM) 31*1024kB (ME) 3*2048kB (ME) 769*4096kB (M) = 3213456kB Node 0 hugepages_total=0 hugepages_free=0 hugepages_surp=0 hugepages_size=2048kB 12054 total pagecache pages 0 pages in swap cache Swap cache stats: add 0, delete 0, find 0/0 Free swap = 0kB Total swap = 0kB 1965969 pages RAM 0 pages HighMem/MovableOnly 320145 pages reserved netlink: 3 bytes leftover after parsing attributes in process `syz-executor2'. netlink: 3 bytes leftover after parsing attributes in process `syz-executor2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor1'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor1'. binder_alloc: binder_alloc_mmap_handler: 7553 20000000-20002000 already mapped failed -16 binder: BINDER_SET_CONTEXT_MGR already set binder: 7553:7568 ioctl 40046207 0 returned -16 binder_alloc: 7553: binder_alloc_buf, no vma binder: 7553:7577 transaction failed 29189/-3, size 0-0 line 3128 binder: 7553:7568 got reply transaction with no transaction stack binder: 7553:7568 transaction failed 29201/-71, size 0-0 line 2921 binder: undelivered TRANSACTION_ERROR: 29201 binder: undelivered TRANSACTION_ERROR: 29189 SELinux: unrecognized netlink message: protocol=0 nlmsg_type=6824 sclass=netlink_route_socket binder: undelivered TRANSACTION_COMPLETE binder: undelivered transaction 23, process died. SELinux: unrecognized netlink message: protocol=0 nlmsg_type=6824 sclass=netlink_route_socket binder: undelivered TRANSACTION_COMPLETE audit: type=1400 audit(1521786929.355:23): avc: denied { create } for pid=7719 comm="syz-executor6" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=netlink_iscsi_socket permissive=1 binder: BINDER_SET_CONTEXT_MGR already set binder: 7739:7749 ioctl 40046207 0 returned -16 binder: send failed reply for transaction 27 to 7739:7749 binder: send failed reply for transaction 28 to 7739:7763 binder: undelivered TRANSACTION_COMPLETE binder: undelivered TRANSACTION_ERROR: 29189 binder: undelivered TRANSACTION_COMPLETE binder: undelivered TRANSACTION_ERROR: 29189 binder: 7803:7806 BC_FREE_BUFFER ud57200c273e31c15 no match binder: 7821:7828 BC_CLEAR_DEATH_NOTIFICATION death notification not active binder: 7821:7828 unknown command 0 binder: 7821:7828 ioctl c0306201 2000dfd0 returned -22 binder: 7821:7840 BC_CLEAR_DEATH_NOTIFICATION death notification not active binder: 7821:7840 unknown command 0 binder: 7821:7840 ioctl c0306201 2000dfd0 returned -22 device bridge0 entered promiscuous mode binder: 7992:7993 ERROR: BC_REGISTER_LOOPER called without request binder: 7992:7998 ERROR: BC_REGISTER_LOOPER called without request netlink: 12 bytes leftover after parsing attributes in process `syz-executor6'. binder_alloc: binder_alloc_mmap_handler: 8163 20000000-20002000 already mapped failed -16 binder: BINDER_SET_CONTEXT_MGR already set binder: 8163:8169 ioctl 40046207 0 returned -16 netlink: 4 bytes leftover after parsing attributes in process `syz-executor6'. binder: release 8163:8169 transaction 34 out, still active binder: send failed reply for transaction 34, target dead netlink: 4 bytes leftover after parsing attributes in process `syz-executor6'. kasan: CONFIG_KASAN_INLINE enabled kasan: GPF could be caused by NULL-ptr deref or user memory accessgeneral protection fault: 0000 [#1] PREEMPT SMP KASAN Dumping ftrace buffer: (ftrace buffer empty) Modules linked in: CPU: 1 PID: 8346 Comm: syz-executor6 Not tainted 4.4.120-gd63fdf6 #29 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 task: ffff8801c71a9800 task.stack: ffff8800ad5c0000 RIP: 0010:[] [] sg_read_oxfer drivers/scsi/sg.c:1976 [inline] RIP: 0010:[] [] sg_read+0xd17/0x1490 drivers/scsi/sg.c:530 RSP: 0018:ffff8800ad5c7b50 EFLAGS: 00010246 RAX: dffffc0000000000 RBX: 0000000000000000 RCX: ffffffff825bab1e RDX: 0000000000000000 RSI: ffffc900032b1000 RDI: ffff8801c9578170 RBP: ffff8800ad5c7c58 R08: 0000007461747364 R09: 0000000000000000 R10: 0000000000000000 R11: 1ffff10015ab8f30 R12: 00000000000000e9 R13: 0000000000000000 R14: ffff8800aeedef60 R15: ffff8801c9578140 FS: 0000000000000000(0000) GS:ffff8801db300000(0063) knlGS:00000000f6ff6b40 CS: 0010 DS: 002b ES: 002b CR0: 0000000080050033 CR2: 00000000f6ef4db0 CR3: 00000000ad6be000 CR4: 0000000000160670 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Stack: ffff8800ad5c7bd8 ffff8801d9ba6128 0000000000000015 ffff8801c9578158 b6034513d9854f85 ffff8801c9578168 000000000000010d 0000000000000000 ffff8801d4a52000 0000000000001000 1ffff10015ab8f76 0000000020000064 Call Trace: [] __vfs_read+0x103/0x440 fs/read_write.c:432 [] vfs_read+0x123/0x3a0 fs/read_write.c:454 [] SYSC_read fs/read_write.c:569 [inline] [] SyS_read+0xd9/0x1b0 fs/read_write.c:562 [] do_syscall_32_irqs_on arch/x86/entry/common.c:392 [inline] [] do_fast_syscall_32+0x321/0x8a0 arch/x86/entry/common.c:459 [] sysenter_flags_fixed+0xd/0x17 Code: 00 00 00 00 00 fc ff df 48 c1 ea 03 80 3c 02 00 0f 85 97 06 00 00 48 b8 00 00 00 00 00 fc ff df 49 8b 5f 28 48 89 da 48 c1 ea 03 <80> 3c 02 00 0f 85 6b 06 00 00 48 8b 1b 48 85 db 0f 84 3b 03 00 RIP [] sg_read_oxfer drivers/scsi/sg.c:1976 [inline] RIP [] sg_read+0xd17/0x1490 drivers/scsi/sg.c:530 RSP ---[ end trace 00e685fec021e35d ]---