From: Stephane Eranian <eranian@google.com>
To: Cyrill Gorcunov <gorcunov@gmail.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>,
Don Zickus <dzickus@redhat.com>, Ingo Molnar <mingo@elte.hu>,
Lin Ming <ming.m.lin@intel.com>,
Arnaldo Carvalho de Melo <acme@redhat.com>,
Frederic Weisbecker <fweisbec@gmail.com>,
Vince Weaver <vweaver1@eecs.utk.edu>,
lkml <linux-kernel@vger.kernel.org>
Subject: Re: [RFC -tip] perf, x86: Add PERF_COUNT_HW_NMI_WATCHDOG event v2
Date: Tue, 21 Jun 2011 20:06:54 +0200 [thread overview]
Message-ID: <BANLkTim8OdhTdaayHZAKSXWhmN0anEhieQ@mail.gmail.com> (raw)
In-Reply-To: <20110621175421.GF21641@sun>
On Tue, Jun 21, 2011 at 7:54 PM, Cyrill Gorcunov <gorcunov@gmail.com> wrote:
> On Tue, Jun 21, 2011 at 07:26:16PM +0200, Stephane Eranian wrote:
> ...
>> >
>> > It doesn't change things much. Of course I can put some specifics into
>> > .config but where is the guarantee some new generic event would not ever
>> > intersect with it. I know (for example) we could reserve -1ULL for this
>> > event but again where is the guarantee that it will never ever be used
>> > system wide in future for some different event?
>> >
>> I am not talking about a new generic PMU event. I am talking about
>> you hardcoding a raw event in the callback: type = PERF_TYPE_RAW,
>> config=0x003c.
>>
>
> watchdog.c is system-wide and even if it's not used by archs other
> than x86 doesn't mean it'll not in future ;) So we could encode
> this watchdog event as you mention (and I would check for this
> values and map it internally to bits I need, this btw will require me
> to check if this bits do not intersect with some already valid bits
> combination but it's a different problem) but than we _must_ be sure it
> never bring problems as new arch or consumer appear. So, no, I don't
> like this approach, it's fragile. But gimme some time -- I'll re-check
> all bits, probably there is some workaround.
>
I don't understand what possible conflict bits you're talking about
If in arch/x86/kernel/cpu/perf_event.c I add a callback which
checks:
if (netburst_host) {
attr.type = PERF_TYPE_RAW
attr.config = 0x3c
} else {
attr.type = PERF_TYPE_HARDWARE
attr.config = PERF_COUNT_HW__CPU_CYCLES
}
I simply don't think PERF_COUNT_HW_NMI_WATCHDOG should
ever be exposed to users.
> Cyrill
>
next prev parent reply other threads:[~2011-06-21 18:06 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-28 15:37 Cyrill Gorcunov
2011-06-21 15:23 ` Don Zickus
2011-06-21 15:40 ` Cyrill Gorcunov
2011-06-21 15:58 ` Peter Zijlstra
2011-06-21 16:13 ` Cyrill Gorcunov
2011-06-21 16:20 ` Stephane Eranian
2011-06-21 16:48 ` Cyrill Gorcunov
2011-06-21 17:02 ` Cyrill Gorcunov
2011-06-21 17:10 ` Stephane Eranian
2011-06-21 17:23 ` Cyrill Gorcunov
2011-06-21 17:26 ` Stephane Eranian
2011-06-21 17:54 ` Cyrill Gorcunov
2011-06-21 18:06 ` Stephane Eranian [this message]
2011-06-21 18:32 ` Cyrill Gorcunov
2011-06-22 8:27 ` Cyrill Gorcunov
2011-06-22 9:21 ` Cyrill Gorcunov
2011-06-23 6:48 ` Cyrill Gorcunov
2011-06-23 9:40 ` Stephane Eranian
2011-06-23 9:54 ` Cyrill Gorcunov
2011-06-23 11:07 ` Cyrill Gorcunov
2011-06-23 11:40 ` Don Zickus
2011-06-23 11:44 ` Stephane Eranian
2011-06-23 11:53 ` Cyrill Gorcunov
2011-06-23 12:03 ` Stephane Eranian
2011-06-23 12:07 ` Cyrill Gorcunov
2011-06-23 12:26 ` Cyrill Gorcunov
2011-06-23 12:31 ` Stephane Eranian
2011-06-23 12:34 ` Cyrill Gorcunov
2011-06-23 11:51 ` Cyrill Gorcunov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=BANLkTim8OdhTdaayHZAKSXWhmN0anEhieQ@mail.gmail.com \
--to=eranian@google.com \
--cc=a.p.zijlstra@chello.nl \
--cc=acme@redhat.com \
--cc=dzickus@redhat.com \
--cc=fweisbec@gmail.com \
--cc=gorcunov@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=ming.m.lin@intel.com \
--cc=mingo@elte.hu \
--cc=vweaver1@eecs.utk.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®