[....] Starting enhanced syslogd: rsyslogd[ 13.550943] audit: type=1400 audit(1513153132.399:5): avc: denied { syslog } for pid=2994 comm="rsyslogd" capability=34 scontext=system_u:system_r:kernel_t:s0 tcontext=system_u:system_r:kernel_t:s0 tclass=capability2 permissive=1 [?25l[?1c7[ ok 8[?25h[?0c. [....] Starting periodic command scheduler: cron[?25l[?1c7[ ok 8[?25h[?0c. Starting mcstransd: [....] Starting file context maintaining daemon: restorecond[?25l[?1c7[ ok 8[?25h[?0c. [....] Starting OpenBSD Secure Shell server: sshd[?25l[?1c7[ ok 8[?25h[?0c. Debian GNU/Linux 7 syzkaller ttyS0 syzkaller login: [ 19.179939] audit: type=1400 audit(1513153138.028:6): avc: denied { map } for pid=3136 comm="bash" path="/bin/bash" dev="sda1" ino=1457 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:file_t:s0 tclass=file permissive=1 Warning: Permanently added 'ci-upstream-kasan-gce-1,10.128.15.202' (ECDSA) to the list of known hosts. [ 25.418425] audit: type=1400 audit(1513153144.267:7): avc: denied { map } for pid=3150 comm="syz-execprog" path="/root/syz-execprog" dev="sda1" ino=16479 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:user_home_t:s0 tclass=file permissive=1 2017/12/13 08:19:04 parsed 1 programs 2017/12/13 08:19:04 executed programs: 0 [ 25.920884] audit: type=1400 audit(1513153144.768:8): avc: denied { map } for pid=3150 comm="syz-execprog" path="/root/syzkaller-shm878895248" dev="sda1" ino=16482 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:object_r:file_t:s0 tclass=file permissive=1 [ 26.833737] [ 26.835381] ====================================================== [ 26.841662] WARNING: possible circular locking dependency detected [ 26.847950] 4.15.0-rc3+ #219 Not tainted [ 26.851973] ------------------------------------------------------ [ 26.858254] syz-executor0/3221 is trying to acquire lock: [ 26.863753] (event_mutex){+.+.}, at: [<0000000096562459>] perf_trace_destroy+0x28/0x100 [ 26.871953] [ 26.871953] but task is already holding lock: [ 26.877886] (&mm->mmap_sem){++++}, at: [<00000000bdbdb48d>] vm_mmap_pgoff+0x198/0x280 [ 26.885914] [ 26.885914] which lock already depends on the new lock. [ 26.885914] [ 26.894199] [ 26.894199] the existing dependency chain (in reverse order) is: [ 26.901783] [ 26.901783] -> #7 (&mm->mmap_sem){++++}: [ 26.907294] lock_acquire+0x1d5/0x580 [ 26.911580] __might_fault+0x13a/0x1d0 [ 26.915956] _copy_to_user+0x2c/0xc0 [ 26.920157] filldir+0x1a7/0x320 [ 26.924015] dcache_readdir+0x12d/0x5e0 [ 26.928477] iterate_dir+0x1ca/0x540 [ 26.932677] SyS_getdents+0x225/0x450 [ 26.936964] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 26.942200] [ 26.942200] -> #6 (&sb->s_type->i_mutex_key#5){++++}: [ 26.948844] cache_grow_end.part.37+0x3a/0x180 [ 26.953912] kmem_cache_alloc+0x433/0x760 [ 26.958631] getname_kernel+0x54/0x340 [ 26.963004] kern_path_create+0x23/0x40 [ 26.967466] handle_create+0xc0/0x760 [ 26.971748] [ 26.971748] -> #5 ((completion)&req.done){+.+.}: [ 26.977952] lock_acquire+0x1d5/0x580 [ 26.982244] wait_for_completion+0xcb/0x7b0 [ 26.987063] devtmpfs_create_node+0x32b/0x4a0 [ 26.992044] device_add+0x120f/0x1640 [ 26.996332] device_create_groups_vargs+0x1f3/0x250 [ 27.001836] device_create+0xda/0x110 [ 27.006125] msr_device_create+0x26/0x40 [ 27.010671] cpuhp_invoke_callback+0x2ea/0x1d20 [ 27.015831] cpuhp_thread_fun+0x48e/0x7e0 [ 27.020480] smpboot_thread_fn+0x450/0x7c0 [ 27.025201] kthread+0x37a/0x440 [ 27.029053] ret_from_fork+0x24/0x30 [ 27.033260] [ 27.033260] -> #4 (cpuhp_state-up){+.+.}: [ 27.038855] lock_acquire+0x1d5/0x580 [ 27.043148] cpuhp_issue_call+0x1e5/0x520 [ 27.047795] __cpuhp_setup_state_cpuslocked+0x282/0x600 [ 27.053644] __cpuhp_setup_state+0xb0/0x140 [ 27.058454] page_writeback_init+0x4d/0x71 [ 27.063183] pagecache_init+0x48/0x4f [ 27.067471] start_kernel+0x6bc/0x74f [ 27.071764] x86_64_start_reservations+0x2a/0x2c [ 27.077006] x86_64_start_kernel+0x77/0x7a [ 27.081726] secondary_startup_64+0xa5/0xb0 [ 27.086531] [ 27.086531] -> #3 (cpuhp_state_mutex){+.+.}: [ 27.092389] lock_acquire+0x1d5/0x580 [ 27.096687] __mutex_lock+0x16f/0x1a80 [ 27.101061] mutex_lock_nested+0x16/0x20 [ 27.105610] __cpuhp_setup_state_cpuslocked+0x5b/0x600 [ 27.111371] __cpuhp_setup_state+0xb0/0x140 [ 27.116185] kvm_guest_init+0x1f3/0x20f [ 27.120654] setup_arch+0x17e8/0x1a02 [ 27.124939] start_kernel+0xa5/0x74f [ 27.129141] x86_64_start_reservations+0x2a/0x2c [ 27.134382] x86_64_start_kernel+0x77/0x7a [ 27.139114] secondary_startup_64+0xa5/0xb0 [ 27.143917] [ 27.143917] -> #2 (cpu_hotplug_lock.rw_sem){++++}: [ 27.150300] lock_acquire+0x1d5/0x580 [ 27.154595] cpus_read_lock+0x42/0x90 [ 27.158882] static_key_slow_inc+0x9d/0x3c0 [ 27.163690] tracepoint_probe_register_prio+0x80d/0x9a0 [ 27.169537] tracepoint_probe_register+0x2a/0x40 [ 27.174779] trace_event_reg+0x167/0x320 [ 27.179327] perf_trace_init+0x4ef/0xab0 [ 27.183874] perf_tp_event_init+0x7d/0xf0 [ 27.188508] perf_try_init_event+0xc9/0x1f0 [ 27.193315] perf_event_alloc+0x1cc6/0x2b00 [ 27.198122] SYSC_perf_event_open+0x842/0x2f10 [ 27.203188] SyS_perf_event_open+0x39/0x50 [ 27.207909] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 27.213166] [ 27.213166] -> #1 (tracepoints_mutex){+.+.}: [ 27.219031] lock_acquire+0x1d5/0x580 [ 27.223319] __mutex_lock+0x16f/0x1a80 [ 27.227693] mutex_lock_nested+0x16/0x20 [ 27.232241] tracepoint_probe_register_prio+0xa0/0x9a0 [ 27.238001] tracepoint_probe_register+0x2a/0x40 [ 27.243249] trace_event_reg+0x167/0x320 [ 27.247795] perf_trace_init+0x4ef/0xab0 [ 27.252346] perf_tp_event_init+0x7d/0xf0 [ 27.256978] perf_try_init_event+0xc9/0x1f0 [ 27.261784] perf_event_alloc+0x1cc6/0x2b00 [ 27.266593] SYSC_perf_event_open+0x842/0x2f10 [ 27.271661] SyS_perf_event_open+0x39/0x50 [ 27.276381] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 27.281617] [ 27.281617] -> #0 (event_mutex){+.+.}: [ 27.286953] __lock_acquire+0x3498/0x47f0 [ 27.291587] lock_acquire+0x1d5/0x580 [ 27.295872] __mutex_lock+0x16f/0x1a80 [ 27.300245] mutex_lock_nested+0x16/0x20 [ 27.304796] perf_trace_destroy+0x28/0x100 [ 27.309517] tp_perf_event_destroy+0x15/0x20 [ 27.314412] _free_event+0x3bd/0x10f0 [ 27.318697] put_event+0x24/0x30 [ 27.322547] perf_mmap_close+0x60d/0x1010 [ 27.327182] remove_vma+0xb4/0x1b0 [ 27.331208] do_munmap+0x82a/0xdf0 [ 27.335234] mmap_region+0x59e/0x15a0 [ 27.339518] do_mmap+0x6c6/0xe10 [ 27.343368] vm_mmap_pgoff+0x1de/0x280 [ 27.347750] SyS_mmap_pgoff+0x23b/0x5f0 [ 27.352209] SyS_mmap+0x16/0x20 [ 27.355973] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 27.361212] [ 27.361212] other info that might help us debug this: [ 27.361212] [ 27.369314] Chain exists of: [ 27.369314] event_mutex --> &sb->s_type->i_mutex_key#5 --> &mm->mmap_sem [ 27.369314] [ 27.380639] Possible unsafe locking scenario: [ 27.380639] [ 27.386658] CPU0 CPU1 [ 27.391285] ---- ---- [ 27.395913] lock(&mm->mmap_sem); [ 27.399417] lock(&sb->s_type->i_mutex_key#5); [ 27.406567] lock(&mm->mmap_sem); [ 27.412587] lock(event_mutex); [ 27.415915] [ 27.415915] *** DEADLOCK *** [ 27.415915] [ 27.421945] 1 lock held by syz-executor0/3221: [ 27.426495] #0: (&mm->mmap_sem){++++}, at: [<00000000bdbdb48d>] vm_mmap_pgoff+0x198/0x280 [ 27.434953] [ 27.434953] stack backtrace: [ 27.439423] CPU: 1 PID: 3221 Comm: syz-executor0 Not tainted 4.15.0-rc3+ #219 [ 27.446658] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 27.455981] Call Trace: [ 27.458543] dump_stack+0x194/0x257 [ 27.462136] ? arch_local_irq_restore+0x53/0x53 [ 27.466772] print_circular_bug+0x42d/0x610 [ 27.471471] ? save_stack_trace+0x1a/0x20 [ 27.475587] check_prev_add+0x666/0x15f0 [ 27.479612] ? __save_stack_trace+0x61/0xd0 [ 27.483896] ? copy_trace+0x150/0x150 [ 27.487662] ? check_usage+0xb60/0xb60 [ 27.491515] ? save_stack_trace+0x1a/0x20 [ 27.495625] ? __lock_acquire+0x324e/0x47f0 [ 27.499913] __lock_acquire+0x3498/0x47f0 [ 27.504026] ? __lock_acquire+0x3498/0x47f0 [ 27.508316] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 27.513470] ? do_munmap+0x82a/0xdf0 [ 27.517150] ? __unwind_start+0x169/0x330 [ 27.521263] ? __kernel_text_address+0xd/0x40 [ 27.525724] ? unwind_next_frame.part.6+0x1a6/0xb40 [ 27.530705] ? unwind_next_frame.part.6+0x1a6/0xb40 [ 27.535685] ? unwind_dump+0x4d0/0x4d0 [ 27.539537] ? check_noncircular+0x20/0x20 [ 27.543734] ? unwind_dump+0x4d0/0x4d0 [ 27.547587] ? __read_once_size_nocheck.constprop.8+0x10/0x10 [ 27.553433] ? find_held_lock+0x39/0x1d0 [ 27.557458] ? do_mmap+0x6c6/0xe10 [ 27.560963] ? check_noncircular+0x20/0x20 [ 27.565164] ? perf_event_detach_bpf_prog+0x92/0x3d0 [ 27.570235] lock_acquire+0x1d5/0x580 [ 27.574000] ? perf_trace_destroy+0x28/0x100 [ 27.578379] ? lock_release+0xda0/0xda0 [ 27.582317] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 27.588165] ? perf_event_detach_bpf_prog+0x92/0x3d0 [ 27.593232] ? debug_check_no_locks_freed+0x3d0/0x3d0 [ 27.598386] ? rcu_note_context_switch+0x710/0x710 [ 27.603279] ? __might_sleep+0x95/0x190 [ 27.607218] ? perf_trace_destroy+0x28/0x100 [ 27.611594] __mutex_lock+0x16f/0x1a80 [ 27.615445] ? perf_trace_destroy+0x28/0x100 [ 27.619815] ? find_held_lock+0x39/0x1d0 [ 27.623842] ? perf_trace_destroy+0x28/0x100 [ 27.628216] ? mutex_lock_io_nested+0x1900/0x1900 [ 27.633026] ? lock_downgrade+0x980/0x980 [ 27.637150] ? lock_acquire+0x1d5/0x580 [ 27.641095] ? perf_mmap_close+0x5cb/0x1010 [ 27.645385] ? lock_release+0xda0/0xda0 [ 27.649323] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 27.655172] ? perf_mmap_close+0x33f/0x1010 [ 27.659458] ? find_held_lock+0x39/0x1d0 [ 27.663496] ? __mutex_unlock_slowpath+0xe9/0xac0 [ 27.668314] ? print_usage_bug+0x3f0/0x3f0 [ 27.672514] ? wait_for_completion+0x7b0/0x7b0 [ 27.677062] ? __wake_up_common_lock+0x190/0x310 [ 27.681785] ? check_noncircular+0x20/0x20 [ 27.685985] ? find_held_lock+0x39/0x1d0 [ 27.690013] ? perf_addr_filters_splice+0x18f/0x810 [ 27.694999] ? free_filters_list+0x2f0/0x2f0 [ 27.699385] ? mutex_unlock+0xd/0x10 [ 27.703079] ? __lock_is_held+0xbc/0x140 [ 27.707111] mutex_lock_nested+0x16/0x20 [ 27.711140] ? mutex_lock_nested+0x16/0x20 [ 27.715341] perf_trace_destroy+0x28/0x100 [ 27.719540] ? perf_tp_event_init+0xf0/0xf0 [ 27.723828] tp_perf_event_destroy+0x15/0x20 [ 27.728204] _free_event+0x3bd/0x10f0 [ 27.731970] ? ring_buffer_attach+0x830/0x830 [ 27.736428] ? wait_for_completion+0x7b0/0x7b0 [ 27.740975] ? ring_buffer_put+0x140/0x140 [ 27.745174] ? lock_release+0xda0/0xda0 [ 27.749114] ? atomic_dec_and_mutex_lock+0x112/0x150 [ 27.754180] ? atomic_dec_and_mutex_lock+0x112/0x150 [ 27.759249] put_event+0x24/0x30 [ 27.762580] perf_mmap_close+0x60d/0x1010 [ 27.766704] ? perf_compat_ioctl+0x70/0x70 [ 27.770907] ? save_stack+0x43/0xd0 [ 27.774517] ? check_noncircular+0x20/0x20 [ 27.778716] ? do_munmap+0x82a/0xdf0 [ 27.782402] ? mmap_region+0x59e/0x15a0 [ 27.786340] ? do_mmap+0x6c6/0xe10 [ 27.789844] ? SyS_mmap_pgoff+0x23b/0x5f0 [ 27.793957] ? SyS_mmap+0x16/0x20 [ 27.797377] ? entry_SYSCALL_64_fastpath+0x1f/0x96 [ 27.802269] ? unmap_region+0x35c/0x4f0 [ 27.806205] ? up_read+0x40/0x40 [ 27.809536] ? check_noncircular+0x20/0x20 [ 27.813740] ? mark_held_locks+0xb2/0x100 [ 27.817859] ? reusable_anon_vma+0x560/0x560 [ 27.822236] ? __lock_is_held+0xbc/0x140 [ 27.826271] ? trace_event_raw_event_sched_switch+0x800/0x800 [ 27.832123] ? rcu_note_context_switch+0x710/0x710 [ 27.837021] ? __might_sleep+0x95/0x190 [ 27.840963] ? perf_compat_ioctl+0x70/0x70 [ 27.845169] remove_vma+0xb4/0x1b0 [ 27.848675] do_munmap+0x82a/0xdf0 [ 27.852181] mmap_region+0x59e/0x15a0 [ 27.855949] ? SyS_brk+0x6f0/0x6f0 [ 27.859456] ? arch_get_unmapped_area_topdown+0xba/0x7d0 [ 27.864871] ? arch_get_unmapped_area+0x750/0x750 [ 27.869677] ? lock_acquire+0x1d5/0x580 [ 27.873616] ? vm_mmap_pgoff+0x198/0x280 [ 27.877645] ? filp_close+0x1a1/0x240 [ 27.881411] ? selinux_mmap_addr+0x1f/0xf0 [ 27.885618] ? security_mmap_addr+0x79/0xa0 [ 27.889904] ? get_unmapped_area+0x265/0x300 [ 27.894277] do_mmap+0x6c6/0xe10 [ 27.897608] ? mmap_region+0x15a0/0x15a0 [ 27.901633] ? vm_mmap_pgoff+0x198/0x280 [ 27.905660] ? down_read_killable+0x180/0x180 [ 27.910119] ? security_mmap_file+0x143/0x180 [ 27.914579] vm_mmap_pgoff+0x1de/0x280 [ 27.918433] ? vma_is_stack_for_current+0xa0/0xa0 [ 27.923241] ? _raw_spin_unlock_irq+0x27/0x70 [ 27.927713] ? SyS_futex+0x269/0x390 [ 27.931392] SyS_mmap_pgoff+0x23b/0x5f0 [ 27.935333] ? find_mergeable_anon_vma+0xd0/0xd0 [ 27.940056] ? trace_hardirqs_on_caller+0x421/0x5c0 [ 27.945037] ? trace_hardirqs_on_thunk+0x1a/0x1c [ 27.949757] SyS_mmap+0x16/0x20 [ 27.953001] entry_SYSCALL_64_fastpath+0x1f/0x96 [ 27.957724] RIP: 0033:0x452a39 [ 27.960880] RSP: 002b:00007fc779244c58 EFLAGS: 00000212 ORIG_RAX: 0000000000000009 [ 27.968550] RAX: ffffffffffffffda RBX: 00007fc779245700 RCX: 0000000000452a39 [ 27.975784] RDX: 0000000000000003 RSI: 0000000000292000 RDI: 0000000020000000 [ 27.983022] RBP: 00007ffc2e760ea0 R08: ffffffffffffffff R09: 0000000000000000 [ 27.990257] R10: 0000000000000032 R11: 0000000000000212 R12: 0000000000000000 [ 27.997492] R13: 00007ffc2e760e1f R14: 00007fc7792459c0 R15: 0000000000000007 2017/12/13 08:19:09 executed programs: 77 2017/12/13 08:19:14 executed programs: 180