[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20110623115327.GG10238@sun>
Date: Thu, 23 Jun 2011 15:53:27 +0400
From: Cyrill Gorcunov <gorcunov@...il.com>
To: Stephane Eranian <eranian@...gle.com>
Cc: Don Zickus <dzickus@...hat.com>,
Peter Zijlstra <a.p.zijlstra@...llo.nl>,
Ingo Molnar <mingo@...e.hu>, Lin Ming <ming.m.lin@...el.com>,
Arnaldo Carvalho de Melo <acme@...hat.com>,
Frederic Weisbecker <fweisbec@...il.com>,
Vince Weaver <vweaver1@...s.utk.edu>,
lkml <linux-kernel@...r.kernel.org>
Subject: Re: [RFC -tip] perf, x86: Add PERF_COUNT_HW_NMI_WATCHDOG event v2
On Thu, Jun 23, 2011 at 01:44:36PM +0200, Stephane Eranian wrote:
> On Thu, Jun 23, 2011 at 1:40 PM, Don Zickus <dzickus@...hat.com> wrote:
> > On Thu, Jun 23, 2011 at 03:07:06PM +0400, Cyrill Gorcunov wrote:
> >> On Thu, Jun 23, 2011 at 01:54:39PM +0400, Cyrill Gorcunov wrote:
> >> ...
> >> > >
> >> > > No new hidden event, just a x86_pmu + a per-arch callbacks.
> >> >
> >> > Looks quite good for me, Don? (i'll cook some draft patch for review meanwhile).
> >> >
> >> > Cyrill
> >>
> >> Since we are going to make __weak linking anyway maybe something like below
> >> fit even beter? (untested)
> >
> > I don't think the compiler knows what platform you are running on and may
> > just blindly link your new p4 function for all x86s, which is probably not
> > what you want.
> >
> Don, is right. You need the level of indirection I had in my outline patch.
>
> You also don't need the:
> + if (wd_attr->type != PERF_TYPE_HARDWARE ||
> + wd_attr->attr.config != PERF_COUNT_HW_CPU_CYCLES)
> + return;
>
> In the p4 callback given you know your coming in for the watchdog.
>
Yes, that is why in __weak implementation I dropped it. So guys,
what we stick with -- __weak with second level indirection?
Cyrill
--
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