[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20100721112453.GC21259@hmsreliant.think-freely.org>
Date: Wed, 21 Jul 2010 07:24:53 -0400
From: Neil Horman <nhorman@...driver.com>
To: Koki Sanagi <sanagi.koki@...fujitsu.com>
Cc: netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
davem@...emloft.net, kaneshige.kenji@...fujitsu.com,
izumi.taku@...fujitsu.com, kosaki.motohiro@...fujitsu.com,
laijs@...fujitsu.com, scott.a.mcmillan@...el.com,
rostedt@...dmis.org, eric.dumazet@...il.com, fweisbec@...il.com,
mathieu.desnoyers@...ymtl.ca
Subject: Re: [RFC PATCH v3 2/5] napi: convert trace_napi_poll to TRACE_EVENT
On Wed, Jul 21, 2010 at 04:00:15PM +0900, Koki Sanagi wrote:
> (2010/07/20 20:09), Neil Horman wrote:
> > On Tue, Jul 20, 2010 at 09:46:51AM +0900, Koki Sanagi wrote:
> >> From: Neil Horman <nhorman@...driver.com>
> >>
> >> This patch converts trace_napi_poll from DECLARE_EVENT to TRACE_EVENT to improve
> >> the usability of napi_poll tracepoint.
> >>
> >> <idle>-0 [001] 241302.750777: napi_poll: napi poll on napi struct f6acc480 for device eth3
> >> <idle>-0 [000] 241302.852389: napi_poll: napi poll on napi struct f5d0d70c for device eth1
> >>
> >> An original patch is below.
> >> http://marc.info/?l=linux-kernel&m=126021713809450&w=2
> >> Signed-off-by: Neil Horman <nhorman@...driver.com>
> >>
> >> And add a fix by Steven Rostedt.
> >> http://marc.info/?l=linux-kernel&m=126150506519173&w=2
> >>
> >> Signed-off-by: Koki Sanagi <sanagi.koki@...fujitsu.com>
> >> ---
> >> include/trace/events/napi.h | 25 +++++++++++++++++++++++--
> >> 1 files changed, 23 insertions(+), 2 deletions(-)
> >>
> >> diff --git a/include/trace/events/napi.h b/include/trace/events/napi.h
> >> index 188deca..8fe1e93 100644
> >> --- a/include/trace/events/napi.h
> >> +++ b/include/trace/events/napi.h
> >> @@ -6,10 +6,31 @@
> >>
> >> #include <linux/netdevice.h>
> >> #include <linux/tracepoint.h>
> >> +#include <linux/ftrace.h>
> >> +
> >> +#define NO_DEV "(no_device)"
> >> +
> >> +TRACE_EVENT(napi_poll,
> >>
> >> -DECLARE_TRACE(napi_poll,
> >> TP_PROTO(struct napi_struct *napi),
> >> - TP_ARGS(napi));
> >> +
> >> + TP_ARGS(napi),
> >> +
> >> + TP_STRUCT__entry(
> >> + __field( struct napi_struct *, napi)
> >> + __string( dev_name, napi->dev ? napi->dev->name : NO_DEV)
> >> + ),
> >> +
> >> + TP_fast_assign(
> >> + __entry->napi = napi;
> >> + __assign_str(dev_name, napi->dev ? napi->dev->name : NO_DEV);
> >> + ),
> >> +
> >> + TP_printk("napi poll on napi struct %p for device %s",
> >> + __entry->napi, __get_str(dev_name))
> >> +);
> >> +
> >> +#undef NO_DEV
> >>
> >> #endif /* _TRACE_NAPI_H_ */
> >>
> >>
> > NAK, This change will create a build break in the drop monitor code. You'll
> > need to fix that up if you want to make this change.
> > Neil
> >
> I built a kernel with CONFIG_NET_DROP_MONITOR=y.
> But build break did not occur.
>
My fault, sorry. I misunderstood what the macro change was doing here. It
should be fine.
Thanks
Neil
> Thanks,
> Koki Sanagi.
>
> > --
> > To unsubscribe from this list: send the line "unsubscribe netdev" in
> > the body of a message to majordomo@...r.kernel.org
> > More majordomo info at http://vger.kernel.org/majordomo-info.html
> >
> >
>
>
>
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists