All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] net: fixup for tracepoint napi:napi_poll
@ 2016-07-15 21:55 Jesper Dangaard Brouer
  2016-07-15 22:55 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Jesper Dangaard Brouer @ 2016-07-15 21:55 UTC (permalink / raw)
  To: netdev, David S. Miller; +Cc: rostedt, Jesper Dangaard Brouer

The recent change to tracepoint napi:napi_poll changed the order of
the parameters that perf scripts sees, the printk was correct.  The
problem was that the new parameters (work and budget) were pushed
in front of dev_name.

The new parameters obviously need to be appended to keep backward
compatible.

Fixes: 1db19db7f5ff ("net: tracepoint napi:napi_poll add work and budget")
Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com>
---
 include/trace/events/napi.h |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/trace/events/napi.h b/include/trace/events/napi.h
index 118ed7767639..0b9e5136a2a3 100644
--- a/include/trace/events/napi.h
+++ b/include/trace/events/napi.h
@@ -18,16 +18,16 @@ TRACE_EVENT(napi_poll,
 
 	TP_STRUCT__entry(
 		__field(	struct napi_struct *,	napi)
+		__string(	dev_name, napi->dev ? napi->dev->name : NO_DEV)
 		__field(	int,			work)
 		__field(	int,			budget)
-		__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);
 		__entry->work = work;
 		__entry->budget = budget;
-		__assign_str(dev_name, napi->dev ? napi->dev->name : NO_DEV);
 	),
 
 	TP_printk("napi poll on napi struct %p for device %s work %d budget %d",

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] net: fixup for tracepoint napi:napi_poll
  2016-07-15 21:55 [PATCH] net: fixup for tracepoint napi:napi_poll Jesper Dangaard Brouer
@ 2016-07-15 22:55 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2016-07-15 22:55 UTC (permalink / raw)
  To: brouer; +Cc: netdev, rostedt

From: Jesper Dangaard Brouer <brouer@redhat.com>
Date: Fri, 15 Jul 2016 23:55:20 +0200

> The recent change to tracepoint napi:napi_poll changed the order of
> the parameters that perf scripts sees, the printk was correct.  The
> problem was that the new parameters (work and budget) were pushed
> in front of dev_name.
> 
> The new parameters obviously need to be appended to keep backward
> compatible.
> 
> Fixes: 1db19db7f5ff ("net: tracepoint napi:napi_poll add work and budget")
> Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com>

Applied, thanks Jesper.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-07-15 22:55 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-15 21:55 [PATCH] net: fixup for tracepoint napi:napi_poll Jesper Dangaard Brouer
2016-07-15 22:55 ` David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.