[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CABPqkBTOUc-aB=hp7pu37z50+QHRHRXWP3wdLtePScqic7P1Dg@mail.gmail.com>
Date: Fri, 27 Mar 2015 16:07:01 -0700
From: Stephane Eranian <eranian@...gle.com>
To: Arnaldo Carvalho de Melo <acme@...hat.com>
Cc: David Ahern <dsahern@...il.com>,
Peter Zijlstra <peterz@...radead.org>,
Thomas Gleixner <tglx@...utronix.de>,
Jiri Olsa <jolsa@...hat.com>,
Linus Torvalds <torvalds@...ux-foundation.org>,
LKML <linux-kernel@...r.kernel.org>,
John Stultz <john.stultz@...aro.org>,
"H. Peter Anvin" <hpa@...or.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Ingo Molnar <mingo@...nel.org>
Subject: Re: [PATCH] perf, record: Add clockid parameter
On Fri, Mar 27, 2015 at 1:15 PM, Arnaldo Carvalho de Melo
<acme@...hat.com> wrote:
> Em Fri, Mar 27, 2015 at 11:35:25AM -0600, David Ahern escreveu:
>> On 3/27/15 11:20 AM, Peter Zijlstra wrote:
>> >>This is a new feature which means use_clockid on older kernels will fail. So
>> >>need to catch that and throw an error -- perhaps yet another probe function.
>
>> >How does that work? What do I grep to find an example? I figured if the
>> >kernel didn't support the syscall will fail and we'll terminate
>> >someplace.
>
>> Look at __perf_evsel__open(). In this case you probably do not want
>> to fallback but tell the user the clock id option is not supported.
>> The problem is deciphering the failure is due to the clock id versus
>> all the other failure reasons.
>
> I.e. we're back to the sys_perf_event_open() error reporting suckz rockz
> thing, this time with PeterZ trying to find a way to avoid getting back
> to that discussion... /me runz... ;-P
>
Why not have the kernel advertise the perf capabilities (in procfs or
sysfs) instead this
guessing game with the return values?
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists