Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751298AbaAPRbZ (ORCPT ); Thu, 16 Jan 2014 12:31:25 -0500 Received: from merlin.infradead.org ([205.233.59.134]:43234 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750749AbaAPRbX (ORCPT ); Thu, 16 Jan 2014 12:31:23 -0500 Date: Thu, 16 Jan 2014 18:31:10 +0100 From: Peter Zijlstra To: Vince Weaver Cc: Will Deacon , Chad Paradis , "linux-kernel@vger.kernel.org" , Paul Mackerras , Ingo Molnar , Arnaldo Carvalho de Melo , Stephane Eranian Subject: Re: [patch/rfc] perf on raspberry-pi without overflow interrupt Message-ID: <20140116173110.GA9655@laptop.programming.kicks-ass.net> References: <20140108225315.GG31570@twins.programming.kicks-ass.net> <20140109101921.GA26435@mudshark.cambridge.arm.com> <20140110094056.GK31570@twins.programming.kicks-ass.net> <20140114105721.GU7572@laptop.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2012-12-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 16, 2014 at 12:13:10PM -0500, Vince Weaver wrote: > On Tue, 14 Jan 2014, Peter Zijlstra wrote: > > > On Mon, Jan 13, 2014 at 11:55:17PM -0500, Vince Weaver wrote: > > > > I don't see an existing pmu capabilities struct... or do you mean > > > coming up with one? > > > > Yeah, adding one. > > So would it be a struct, or just an integer with flags? I hadn't really considered that; per the below proposed names I suppose I was thinking of 'unsigned long flags' with #define PMU_HAS_flags. But a named struct would work too I suppose. > > > Would it only hold an "overflow_interrupt_available" flag, or are > > > there other generic capabilities it would be handy to know about? > > > > Possible (other) flags could be: > > > > PMU_HAS_INT -- would allow sampling events > > PMU_HAS_PRECISE -- would allow any ::precise value > > PMU_HAS_FILTER -- would allow all os/user/etc. flags > > should we export these to userspace somehow? > > It would be handy to be able to tell you're getting EOPNOTSUP because > PMU_HAS_INT is not set for your pmu, rather than trying to guess why > things are failing. Yeah I suppose we could do something like that. Maybe something like: # cat /sys/bus/event_source/devices/cpu/flags int precise filter ? -- 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/