From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752081AbdBJIIX (ORCPT ); Fri, 10 Feb 2017 03:08:23 -0500 Received: from mail-wm0-f68.google.com ([74.125.82.68]:32819 "EHLO mail-wm0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751362AbdBJIIV (ORCPT ); Fri, 10 Feb 2017 03:08:21 -0500 Date: Fri, 10 Feb 2017 09:07:56 +0100 From: Ingo Molnar To: Alexander Shishkin Cc: Peter Zijlstra , Ingo Molnar , linux-kernel@vger.kernel.org, vince@deater.net, eranian@google.com, Arnaldo Carvalho de Melo , Will Deacon , Mark Rutland , Mathieu Poirier Subject: Re: [PATCH 3/3] perf: Allow kernel filters on cpu events Message-ID: <20170210080756.GA1977@gmail.com> References: <20170126094057.13805-1-alexander.shishkin@linux.intel.com> <20170126094057.13805-4-alexander.shishkin@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170126094057.13805-4-alexander.shishkin@linux.intel.com> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Alexander Shishkin wrote: > While supporting file-based address filters for cpu events requires some > extra context switch handling, kernel address filters are easy, since the > kernel mapping is preserved across address spaces. It is also useful as > it permits tracing scheduling paths of the kernel. > > This patch allows setting up kernel filters for cpu events. > > Signed-off-by: Alexander Shishkin > Cc: Mathieu Poirier > --- > include/linux/perf_event.h | 2 ++ > kernel/events/core.c | 42 ++++++++++++++++++++++++++++-------------- > 2 files changed, 30 insertions(+), 14 deletions(-) > > diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h > index fcb37c81ca..f4ea0600b2 100644 > --- a/include/linux/perf_event.h > +++ b/include/linux/perf_event.h > @@ -486,6 +486,7 @@ struct perf_addr_filter { > * @list: list of filters for this event > * @lock: spinlock that serializes accesses to the @list and event's > * (and its children's) filter generations. > + * @nr_file_filters: number of file-based filters I've applied the patch, but please for heaven's sake, when you add such a long, long argument name, at minimum re-tabulate the documentation section to look good again ... Thanks, Ingo