mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* tracing, dma-buf: Remove unused trace event dma_fence_annotate_wait_on
@ 2017-10-13 14:06 Steven Rostedt
  2017-10-13 15:27 ` Christian König
  0 siblings, 1 reply; 6+ messages in thread
From: Steven Rostedt @ 2017-10-13 14:06 UTC (permalink / raw)
  To: LKML; +Cc: Chris Wilson, dri-devel, Daniel Vetter, Andrew Morton

From: Steven Rostedt (VMware) <rostedt@goodmis.org>

Commit e941759c74 ("fence: dma-buf cross-device synchronization") added
trace event fence_annotate_wait_on, but never used it. It was renamed
to dma_fence_annotate_wait_on by commit f54d186700 ("dma-buf: Rename
struct fence to dma_fence") but still not used. As defined trace events
have data structures and functions created for them, it is a waste of
memory if they are not used. Remove the unused trace event.

Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
---
Index: linux-trace.git/drivers/dma-buf/dma-fence.c
===================================================================
--- linux-trace.git.orig/drivers/dma-buf/dma-fence.c
+++ linux-trace.git/drivers/dma-buf/dma-fence.c
@@ -27,7 +27,6 @@
 #define CREATE_TRACE_POINTS
 #include <trace/events/dma_fence.h>
 
-EXPORT_TRACEPOINT_SYMBOL(dma_fence_annotate_wait_on);
 EXPORT_TRACEPOINT_SYMBOL(dma_fence_emit);
 EXPORT_TRACEPOINT_SYMBOL(dma_fence_enable_signal);
 
Index: linux-trace.git/include/trace/events/dma_fence.h
===================================================================
--- linux-trace.git.orig/include/trace/events/dma_fence.h
+++ linux-trace.git/include/trace/events/dma_fence.h
@@ -8,46 +8,6 @@
 
 struct dma_fence;
 
-TRACE_EVENT(dma_fence_annotate_wait_on,
-
-	/* fence: the fence waiting on f1, f1: the fence to be waited on. */
-	TP_PROTO(struct dma_fence *fence, struct dma_fence *f1),
-
-	TP_ARGS(fence, f1),
-
-	TP_STRUCT__entry(
-		__string(driver, fence->ops->get_driver_name(fence))
-		__string(timeline, fence->ops->get_timeline_name(fence))
-		__field(unsigned int, context)
-		__field(unsigned int, seqno)
-
-		__string(waiting_driver, f1->ops->get_driver_name(f1))
-		__string(waiting_timeline, f1->ops->get_timeline_name(f1))
-		__field(unsigned int, waiting_context)
-		__field(unsigned int, waiting_seqno)
-	),
-
-	TP_fast_assign(
-		__assign_str(driver, fence->ops->get_driver_name(fence))
-		__assign_str(timeline, fence->ops->get_timeline_name(fence))
-		__entry->context = fence->context;
-		__entry->seqno = fence->seqno;
-
-		__assign_str(waiting_driver, f1->ops->get_driver_name(f1))
-		__assign_str(waiting_timeline, f1->ops->get_timeline_name(f1))
-		__entry->waiting_context = f1->context;
-		__entry->waiting_seqno = f1->seqno;
-
-	),
-
-	TP_printk("driver=%s timeline=%s context=%u seqno=%u "	\
-		  "waits on driver=%s timeline=%s context=%u seqno=%u",
-		  __get_str(driver), __get_str(timeline), __entry->context,
-		  __entry->seqno,
-		  __get_str(waiting_driver), __get_str(waiting_timeline),
-		  __entry->waiting_context, __entry->waiting_seqno)
-);
-
 DECLARE_EVENT_CLASS(dma_fence,
 
 	TP_PROTO(struct dma_fence *fence),

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

* Re: tracing, dma-buf: Remove unused trace event dma_fence_annotate_wait_on
  2017-10-13 14:06 tracing, dma-buf: Remove unused trace event dma_fence_annotate_wait_on Steven Rostedt
@ 2017-10-13 15:27 ` Christian König
  2017-10-16  9:15   ` Daniel Vetter
  0 siblings, 1 reply; 6+ messages in thread
From: Christian König @ 2017-10-13 15:27 UTC (permalink / raw)
  To: Steven Rostedt, LKML; +Cc: Daniel Vetter, Andrew Morton, dri-devel

Am 13.10.2017 um 16:06 schrieb Steven Rostedt:
> From: Steven Rostedt (VMware) <rostedt@goodmis.org>
>
> Commit e941759c74 ("fence: dma-buf cross-device synchronization") added
> trace event fence_annotate_wait_on, but never used it. It was renamed
> to dma_fence_annotate_wait_on by commit f54d186700 ("dma-buf: Rename
> struct fence to dma_fence") but still not used. As defined trace events
> have data structures and functions created for them, it is a waste of
> memory if they are not used. Remove the unused trace event.
>
> Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>

Reviewed-by: Christian König <christian.koenig@amd.com>

> ---
> Index: linux-trace.git/drivers/dma-buf/dma-fence.c
> ===================================================================
> --- linux-trace.git.orig/drivers/dma-buf/dma-fence.c
> +++ linux-trace.git/drivers/dma-buf/dma-fence.c
> @@ -27,7 +27,6 @@
>   #define CREATE_TRACE_POINTS
>   #include <trace/events/dma_fence.h>
>   
> -EXPORT_TRACEPOINT_SYMBOL(dma_fence_annotate_wait_on);
>   EXPORT_TRACEPOINT_SYMBOL(dma_fence_emit);
>   EXPORT_TRACEPOINT_SYMBOL(dma_fence_enable_signal);
>   
> Index: linux-trace.git/include/trace/events/dma_fence.h
> ===================================================================
> --- linux-trace.git.orig/include/trace/events/dma_fence.h
> +++ linux-trace.git/include/trace/events/dma_fence.h
> @@ -8,46 +8,6 @@
>   
>   struct dma_fence;
>   
> -TRACE_EVENT(dma_fence_annotate_wait_on,
> -
> -	/* fence: the fence waiting on f1, f1: the fence to be waited on. */
> -	TP_PROTO(struct dma_fence *fence, struct dma_fence *f1),
> -
> -	TP_ARGS(fence, f1),
> -
> -	TP_STRUCT__entry(
> -		__string(driver, fence->ops->get_driver_name(fence))
> -		__string(timeline, fence->ops->get_timeline_name(fence))
> -		__field(unsigned int, context)
> -		__field(unsigned int, seqno)
> -
> -		__string(waiting_driver, f1->ops->get_driver_name(f1))
> -		__string(waiting_timeline, f1->ops->get_timeline_name(f1))
> -		__field(unsigned int, waiting_context)
> -		__field(unsigned int, waiting_seqno)
> -	),
> -
> -	TP_fast_assign(
> -		__assign_str(driver, fence->ops->get_driver_name(fence))
> -		__assign_str(timeline, fence->ops->get_timeline_name(fence))
> -		__entry->context = fence->context;
> -		__entry->seqno = fence->seqno;
> -
> -		__assign_str(waiting_driver, f1->ops->get_driver_name(f1))
> -		__assign_str(waiting_timeline, f1->ops->get_timeline_name(f1))
> -		__entry->waiting_context = f1->context;
> -		__entry->waiting_seqno = f1->seqno;
> -
> -	),
> -
> -	TP_printk("driver=%s timeline=%s context=%u seqno=%u "	\
> -		  "waits on driver=%s timeline=%s context=%u seqno=%u",
> -		  __get_str(driver), __get_str(timeline), __entry->context,
> -		  __entry->seqno,
> -		  __get_str(waiting_driver), __get_str(waiting_timeline),
> -		  __entry->waiting_context, __entry->waiting_seqno)
> -);
> -
>   DECLARE_EVENT_CLASS(dma_fence,
>   
>   	TP_PROTO(struct dma_fence *fence),
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* Re: tracing, dma-buf: Remove unused trace event dma_fence_annotate_wait_on
  2017-10-13 15:27 ` Christian König
@ 2017-10-16  9:15   ` Daniel Vetter
  2017-10-16 14:37     ` Steven Rostedt
  0 siblings, 1 reply; 6+ messages in thread
From: Daniel Vetter @ 2017-10-16  9:15 UTC (permalink / raw)
  To: christian.koenig
  Cc: Steven Rostedt, LKML, Daniel Vetter, Andrew Morton, dri-devel

On Fri, Oct 13, 2017 at 05:27:59PM +0200, Christian König wrote:
> Am 13.10.2017 um 16:06 schrieb Steven Rostedt:
> > From: Steven Rostedt (VMware) <rostedt@goodmis.org>
> > 
> > Commit e941759c74 ("fence: dma-buf cross-device synchronization") added
> > trace event fence_annotate_wait_on, but never used it. It was renamed
> > to dma_fence_annotate_wait_on by commit f54d186700 ("dma-buf: Rename
> > struct fence to dma_fence") but still not used. As defined trace events
> > have data structures and functions created for them, it is a waste of
> > memory if they are not used. Remove the unused trace event.
> > 
> > Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
> 
> Reviewed-by: Christian König <christian.koenig@amd.com>

Since you have commit rights to drm-misc I assume you'll push this too.

Thanks, Daniel
> 
> > ---
> > Index: linux-trace.git/drivers/dma-buf/dma-fence.c
> > ===================================================================
> > --- linux-trace.git.orig/drivers/dma-buf/dma-fence.c
> > +++ linux-trace.git/drivers/dma-buf/dma-fence.c
> > @@ -27,7 +27,6 @@
> >   #define CREATE_TRACE_POINTS
> >   #include <trace/events/dma_fence.h>
> > -EXPORT_TRACEPOINT_SYMBOL(dma_fence_annotate_wait_on);
> >   EXPORT_TRACEPOINT_SYMBOL(dma_fence_emit);
> >   EXPORT_TRACEPOINT_SYMBOL(dma_fence_enable_signal);
> > Index: linux-trace.git/include/trace/events/dma_fence.h
> > ===================================================================
> > --- linux-trace.git.orig/include/trace/events/dma_fence.h
> > +++ linux-trace.git/include/trace/events/dma_fence.h
> > @@ -8,46 +8,6 @@
> >   struct dma_fence;
> > -TRACE_EVENT(dma_fence_annotate_wait_on,
> > -
> > -	/* fence: the fence waiting on f1, f1: the fence to be waited on. */
> > -	TP_PROTO(struct dma_fence *fence, struct dma_fence *f1),
> > -
> > -	TP_ARGS(fence, f1),
> > -
> > -	TP_STRUCT__entry(
> > -		__string(driver, fence->ops->get_driver_name(fence))
> > -		__string(timeline, fence->ops->get_timeline_name(fence))
> > -		__field(unsigned int, context)
> > -		__field(unsigned int, seqno)
> > -
> > -		__string(waiting_driver, f1->ops->get_driver_name(f1))
> > -		__string(waiting_timeline, f1->ops->get_timeline_name(f1))
> > -		__field(unsigned int, waiting_context)
> > -		__field(unsigned int, waiting_seqno)
> > -	),
> > -
> > -	TP_fast_assign(
> > -		__assign_str(driver, fence->ops->get_driver_name(fence))
> > -		__assign_str(timeline, fence->ops->get_timeline_name(fence))
> > -		__entry->context = fence->context;
> > -		__entry->seqno = fence->seqno;
> > -
> > -		__assign_str(waiting_driver, f1->ops->get_driver_name(f1))
> > -		__assign_str(waiting_timeline, f1->ops->get_timeline_name(f1))
> > -		__entry->waiting_context = f1->context;
> > -		__entry->waiting_seqno = f1->seqno;
> > -
> > -	),
> > -
> > -	TP_printk("driver=%s timeline=%s context=%u seqno=%u "	\
> > -		  "waits on driver=%s timeline=%s context=%u seqno=%u",
> > -		  __get_str(driver), __get_str(timeline), __entry->context,
> > -		  __entry->seqno,
> > -		  __get_str(waiting_driver), __get_str(waiting_timeline),
> > -		  __entry->waiting_context, __entry->waiting_seqno)
> > -);
> > -
> >   DECLARE_EVENT_CLASS(dma_fence,
> >   	TP_PROTO(struct dma_fence *fence),
> > _______________________________________________
> > dri-devel mailing list
> > dri-devel@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/dri-devel
> 
> 

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

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

* Re: tracing, dma-buf: Remove unused trace event dma_fence_annotate_wait_on
  2017-10-16  9:15   ` Daniel Vetter
@ 2017-10-16 14:37     ` Steven Rostedt
  2017-10-16 15:19       ` Sumit Semwal
  0 siblings, 1 reply; 6+ messages in thread
From: Steven Rostedt @ 2017-10-16 14:37 UTC (permalink / raw)
  To: Daniel Vetter
  Cc: christian.koenig, LKML, Daniel Vetter, Andrew Morton, dri-devel

On Mon, 16 Oct 2017 11:15:45 +0200
Daniel Vetter <daniel@ffwll.ch> wrote:

> On Fri, Oct 13, 2017 at 05:27:59PM +0200, Christian König wrote:
> > Am 13.10.2017 um 16:06 schrieb Steven Rostedt:  
> > > From: Steven Rostedt (VMware) <rostedt@goodmis.org>
> > > 
> > > Commit e941759c74 ("fence: dma-buf cross-device synchronization") added
> > > trace event fence_annotate_wait_on, but never used it. It was renamed
> > > to dma_fence_annotate_wait_on by commit f54d186700 ("dma-buf: Rename
> > > struct fence to dma_fence") but still not used. As defined trace events
> > > have data structures and functions created for them, it is a waste of
> > > memory if they are not used. Remove the unused trace event.
> > > 
> > > Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>  
> > 
> > Reviewed-by: Christian König <christian.koenig@amd.com>  
> 
> Since you have commit rights to drm-misc I assume you'll push this too.
> 

Will it cause conflict if I pull it through my tree? It's just removing
unused traecpoints. I added it to my tree already (but haven't pushed
it to linux-next yet), with the Reviewed by from Christian. Is that OK?
It shouldn't cause any merge conflicts that Linus can't handle.

-- Steve

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

* Re: tracing, dma-buf: Remove unused trace event dma_fence_annotate_wait_on
  2017-10-16 14:37     ` Steven Rostedt
@ 2017-10-16 15:19       ` Sumit Semwal
  2017-10-16 21:16         ` Steven Rostedt
  0 siblings, 1 reply; 6+ messages in thread
From: Sumit Semwal @ 2017-10-16 15:19 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: Daniel Vetter, Daniel Vetter, Andrew Morton, Christian Koenig,
	DRI mailing list, LKML

Hi Steven,

On 16 October 2017 at 20:07, Steven Rostedt <rostedt@goodmis.org> wrote:
> On Mon, 16 Oct 2017 11:15:45 +0200
> Daniel Vetter <daniel@ffwll.ch> wrote:
>
>> On Fri, Oct 13, 2017 at 05:27:59PM +0200, Christian König wrote:
>> > Am 13.10.2017 um 16:06 schrieb Steven Rostedt:
>> > > From: Steven Rostedt (VMware) <rostedt@goodmis.org>
>> > >
>> > > Commit e941759c74 ("fence: dma-buf cross-device synchronization") added
>> > > trace event fence_annotate_wait_on, but never used it. It was renamed
>> > > to dma_fence_annotate_wait_on by commit f54d186700 ("dma-buf: Rename
>> > > struct fence to dma_fence") but still not used. As defined trace events
>> > > have data structures and functions created for them, it is a waste of
>> > > memory if they are not used. Remove the unused trace event.
>> > >
>> > > Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
>> >
>> > Reviewed-by: Christian König <christian.koenig@amd.com>
>>
>> Since you have commit rights to drm-misc I assume you'll push this too.
>>
>
> Will it cause conflict if I pull it through my tree? It's just removing
> unused traecpoints. I added it to my tree already (but haven't pushed
> it to linux-next yet), with the Reviewed by from Christian. Is that OK?
> It shouldn't cause any merge conflicts that Linus can't handle.

I suspect it should be ok; please do feel free to add my
Acked-by: Sumit Semwal <sumit.semwal@linaro.org>
if you wish :)
>
> -- Steve
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

Best,
Sumit.

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

* Re: tracing, dma-buf: Remove unused trace event dma_fence_annotate_wait_on
  2017-10-16 15:19       ` Sumit Semwal
@ 2017-10-16 21:16         ` Steven Rostedt
  0 siblings, 0 replies; 6+ messages in thread
From: Steven Rostedt @ 2017-10-16 21:16 UTC (permalink / raw)
  To: Sumit Semwal
  Cc: Daniel Vetter, Daniel Vetter, Andrew Morton, Christian Koenig,
	DRI mailing list, LKML

On Mon, 16 Oct 2017 20:49:11 +0530
Sumit Semwal <sumit.semwal@linaro.org> wrote:

> I suspect it should be ok; please do feel free to add my
> Acked-by: Sumit Semwal <sumit.semwal@linaro.org>
> if you wish :)

Done. Thanks!

-- Steve

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

end of thread, other threads:[~2017-10-16 21:17 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-10-13 14:06 tracing, dma-buf: Remove unused trace event dma_fence_annotate_wait_on Steven Rostedt
2017-10-13 15:27 ` Christian König
2017-10-16  9:15   ` Daniel Vetter
2017-10-16 14:37     ` Steven Rostedt
2017-10-16 15:19       ` Sumit Semwal
2017-10-16 21:16         ` Steven Rostedt

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®