Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755501AbbGFVU4 (ORCPT ); Mon, 6 Jul 2015 17:20:56 -0400 Received: from mail-ie0-f180.google.com ([209.85.223.180]:35356 "EHLO mail-ie0-f180.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753368AbbGFVUq (ORCPT ); Mon, 6 Jul 2015 17:20:46 -0400 From: Vince Weaver X-Google-Original-From: Vince Weaver Date: Mon, 6 Jul 2015 17:27:04 -0400 (EDT) To: linux-kernel@vger.kernel.org cc: Ananth N Mavinakayanahalli , Anil S Keshavamurthy , "David S. Miller" , Masami Hiramatsu , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Steven Rostedt Subject: perf, kprobes: fuzzer generates huge number of WARNings Message-ID: User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 7895 Lines: 134 Hello I've been working on trying to get the perf_fuzzer to start fuzzing the PERF_EVENT_IOC_SET_BPF so I've added some really hackish kprobe support. However before I can get to the BPF testing the kprobe code generates a constant stream of WARNINGS which make the machine more or less useless until I stop it. I've included a small selection here. Is this expected? Vince [ 3521.350839] ftrace: Failed on adding breakpoints (6056): [ 3521.357877] ------------[ cut here ]------------ [ 3521.363007] WARNING: CPU: 1 PID: 5080 at kernel/trace/ftrace.c:1951 ftrace_bug+0x245/0x320() [ 3521.449830] CPU: 1 PID: 5080 Comm: perf_fuzzer Not tainted 4.2.0-rc1+ #168 [ 3521.457543] Hardware name: LENOVO 10AM000AUS/SHARKBAY, BIOS FBKT72AUS 01/26/2014 [ 3521.465820] ffffffff81a28cf6 ffff8800cd9f7b48 ffffffff816a10a3 0000000000000000 [ 3521.474274] 0000000000000000 ffff8800cd9f7b88 ffffffff8106ec8a ffff8800cd9f7b68 [ 3521.482680] ffff880119bd7a80 ffffffff81196730 ffff880119bd7a80 00000000000017a8 [ 3521.491143] Call Trace: [ 3521.494128] [] dump_stack+0x45/0x57 [ 3521.500016] [] warn_slowpath_common+0x8a/0xc0 [ 3521.506810] [] ? vm_insert_mixed+0x40/0x40 [ 3521.513389] [] warn_slowpath_null+0x1a/0x20 [ 3521.520025] [] ftrace_bug+0x245/0x320 [ 3521.526147] [] ftrace_replace_code+0x24c/0x360 [ 3521.533102] [] ftrace_modify_all_code+0x9c/0x120 [ 3521.540241] [] arch_ftrace_update_code+0x10/0x20 [ 3521.547396] [] ftrace_run_update_code+0x20/0x80 [ 3521.554425] [] ftrace_startup_enable+0x2f/0x40 [ 3521.561376] [] ftrace_startup+0xd6/0x230 [ 3521.567772] [] register_ftrace_function+0x54/0x70 [ 3521.575025] [] perf_ftrace_event_register+0x47/0x140 [ 3521.582537] [] perf_trace_init+0xc4/0x2c0 [ 3521.589050] [] perf_tp_event_init+0x2a/0x50 [ 3521.595771] [] perf_try_init_event+0x8b/0xa0 [ 3521.602572] [] perf_init_event+0x133/0x160 [ 3521.609181] [] ? perf_bp_event+0x90/0x90 [ 3521.615647] [] perf_event_alloc+0x42a/0x680 [ 3521.622388] [] SYSC_perf_event_open+0x3c7/0xd20 [ 3521.629487] [] ? __do_page_fault+0x1ab/0x3f0 [ 3521.636320] [] SyS_perf_event_open+0x9/0x10 [ 3521.643087] [] entry_SYSCALL_64_fastpath+0x16/0x7a [ 3521.650521] ---[ end trace a413501925547ed5 ]--- [ 3521.655960] ftrace failed to modify [] handle_mm_fault+0x0/0x1750 [ 3521.664767] actual: e8:cb:18:ef:1e [ 3521.669202] ftrace record flags: ec000002 [ 3521.673993] (2) R tramp: 0xffffffffa0090000 expected tramp: ffffffffa0090000 [ 3521.834024] ------------[ cut here ]------------ [ 3521.839442] WARNING: CPU: 2 PID: 5177 at kernel/kprobes.c:955 disarm_kprobe+0xf8/0x100() [ 3521.848577] Failed to init kprobe-ftrace (-19) [ 3521.931384] CPU: 2 PID: 5177 Comm: perf_fuzzer Tainted: G W 4.2.0-rc1+ #168 [ 3521.940498] Hardware name: LENOVO 10AM000AUS/SHARKBAY, BIOS FBKT72AUS 01/26/2014 [ 3521.948854] ffffffff81a28976 ffff8800bf6d7a48 ffffffff816a10a3 0000000000000000 [ 3521.957335] ffff8800bf6d7a98 ffff8800bf6d7a88 ffffffff8106ec8a ffffffff81124f6a [ 3521.965839] ffff8800cd4e2010 ffff8800cd4e2010 ffff8800cd4e2000 ffff8800cd28a000 [ 3521.974275] Call Trace: [ 3521.977335] [] dump_stack+0x45/0x57 [ 3521.983302] [] warn_slowpath_common+0x8a/0xc0 [ 3521.990170] [] ? unregister_ftrace_function+0x1a/0x50 [ 3521.997784] [] warn_slowpath_fmt+0x46/0x50 [ 3522.004418] [] ? mutex_unlock+0xe/0x10 [ 3522.010640] [] disarm_kprobe+0xf8/0x100 [ 3522.016972] [] __disable_kprobe+0x99/0xc0 [ 3522.023491] [] disable_kprobe+0x27/0x50 [ 3522.029827] [] disable_trace_kprobe+0xc3/0xf0 [ 3522.036708] [] kprobe_register+0x2d/0xe0 [ 3522.043102] [] perf_trace_event_unreg.isra.1+0x33/0x90 [ 3522.050808] [] perf_trace_destroy+0x3c/0x50 [ 3522.057482] [] tp_perf_event_destroy+0x9/0x10 [ 3522.064354] [] _free_event+0xc1/0x250 [ 3522.070474] [] ? put_event+0x2b/0x150 [ 3522.076625] [] free_event+0x1f/0x50 [ 3522.082531] [] perf_event_exit_task+0x245/0x300 [ 3522.089575] [] do_exit+0x3b2/0xa90 [ 3522.095444] [] ? get_signal+0xe2/0x720 [ 3522.101659] [] do_group_exit+0x54/0xe0 [ 3522.107892] [] get_signal+0x280/0x720 [ 3522.114046] [] do_signal+0x28/0xb50 [ 3522.119984] [] ? __lock_acquire.isra.31+0x3a6/0xf90 [ 3522.127411] [] ? sys_getppid+0x5/0x80 [ 3522.133563] [] do_notify_resume+0x62/0x70 [ 3522.140084] [] retint_signal+0x44/0x86 [ 3522.146349] ---[ end trace a413501925547ed6 ]--- [ 3522.157157] WARNING: CPU: 2 PID: 5177 at kernel/kprobes.c:959 disarm_kprobe+0xca/0x100() [ 3522.166266] Failed to disarm kprobe-ftrace at ffffffff81196730 (-19) [ 3522.251364] CPU: 2 PID: 5177 Comm: perf_fuzzer Tainted: G W 4.2.0-rc1+ #168 [ 3522.260488] Hardware name: LENOVO 10AM000AUS/SHARKBAY, BIOS FBKT72AUS 01/26/2014 [ 3522.268953] ffffffff81a28976 ffff8800bf6d7a48 ffffffff816a10a3 0000000000000000 [ 3522.277482] ffff8800bf6d7a98 ffff8800bf6d7a88 ffffffff8106ec8a ffffffff81124f6a [ 3522.285993] ffff8800cd4e2010 ffff8800cd4e2010 ffff8800cd4e2000 ffff8800cd28a000 [ 3522.294520] Call Trace: [ 3522.297594] [] dump_stack+0x45/0x57 [ 3522.303535] [] warn_slowpath_common+0x8a/0xc0 [ 3522.310379] [] ? unregister_ftrace_function+0x1a/0x50 [ 3522.318026] [] warn_slowpath_fmt+0x46/0x50 [ 3522.324637] [] ? mutex_unlock+0xe/0x10 [ 3522.330859] [] ? vm_insert_mixed+0x40/0x40 [ 3522.337459] [] disarm_kprobe+0xca/0x100 [ 3522.343792] [] __disable_kprobe+0x99/0xc0 [ 3522.350304] [] disable_kprobe+0x27/0x50 [ 3522.356692] [] disable_trace_kprobe+0xc3/0xf0 [ 3522.363510] [] kprobe_register+0x2d/0xe0 [ 3522.369907] [] perf_trace_event_unreg.isra.1+0x33/0x90 [ 3522.377620] [] perf_trace_destroy+0x3c/0x50 [ 3522.384337] [] tp_perf_event_destroy+0x9/0x10 [ 3522.391215] [] _free_event+0xc1/0x250 [ 3522.397348] [] ? put_event+0x2b/0x150 [ 3522.403478] [] free_event+0x1f/0x50 [ 3522.409443] [] perf_event_exit_task+0x245/0x300 [ 3522.416466] [] do_exit+0x3b2/0xa90 [ 3522.422351] [] ? get_signal+0xe2/0x720 [ 3522.428555] [] do_group_exit+0x54/0xe0 [ 3522.434803] [] get_signal+0x280/0x720 [ 3522.440974] [] do_signal+0x28/0xb50 [ 3522.446949] [] ? __lock_acquire.isra.31+0x3a6/0xf90 [ 3522.454420] [] ? sys_getppid+0x5/0x80 [ 3522.460592] [] do_notify_resume+0x62/0x70 [ 3522.467079] [] retint_signal+0x44/0x86 [ 3522.473343] ---[ end trace a413501925547ed7 ]--- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/