linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] [media] v4l2: export videobuf2 trace points
@ 2015-07-28  7:55 Philipp Zabel
  2015-07-28  8:02 ` Hans Verkuil
  0 siblings, 1 reply; 3+ messages in thread
From: Philipp Zabel @ 2015-07-28  7:55 UTC (permalink / raw)
  To: Hans Verkuil
  Cc: Mauro Carvalho Chehab, Kamil Debski, Sylwester Nawrocki,
	Pawel Osciak, Marek Szyprowski, Kyungmin Park, Steven Rostedt,
	linux-media, kernel, Philipp Zabel

If videobuf2-core is built as a module, the vb2 trace points must be
exported from videodev.o to avoid errors when linking videobuf2-core.

Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
---
 drivers/media/v4l2-core/v4l2-ioctl.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/media/v4l2-core/v4l2-ioctl.c b/drivers/media/v4l2-core/v4l2-ioctl.c
index 85de455..e8b78ae 100644
--- a/drivers/media/v4l2-core/v4l2-ioctl.c
+++ b/drivers/media/v4l2-core/v4l2-ioctl.c
@@ -2784,3 +2784,8 @@ long video_ioctl2(struct file *file,
 	return video_usercopy(file, cmd, arg, __video_do_ioctl);
 }
 EXPORT_SYMBOL(video_ioctl2);
+
+EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_buf_done);
+EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_buf_queue);
+EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_dqbuf);
+EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_qbuf);
-- 
2.4.6


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

* Re: [PATCH] [media] v4l2: export videobuf2 trace points
  2015-07-28  7:55 [PATCH] [media] v4l2: export videobuf2 trace points Philipp Zabel
@ 2015-07-28  8:02 ` Hans Verkuil
  2015-07-28  8:15   ` Philipp Zabel
  0 siblings, 1 reply; 3+ messages in thread
From: Hans Verkuil @ 2015-07-28  8:02 UTC (permalink / raw)
  To: Philipp Zabel, Hans Verkuil
  Cc: Mauro Carvalho Chehab, Kamil Debski, Sylwester Nawrocki,
	Pawel Osciak, Marek Szyprowski, Kyungmin Park, Steven Rostedt,
	linux-media, kernel

On 07/28/2015 09:55 AM, Philipp Zabel wrote:
> If videobuf2-core is built as a module, the vb2 trace points must be
> exported from videodev.o to avoid errors when linking videobuf2-core.

I'm no tracepoint expert, so I'll just ask: if the tracepoint functionality
is disabled in the kernel, will this still compile OK?

That is, will the EXPORT_TRACEPOINT_SYMBOL_GPL() code disappear in that
case or will it point to absent code/data?

Regards,

	Hans

> 
> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
> ---
>  drivers/media/v4l2-core/v4l2-ioctl.c | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/drivers/media/v4l2-core/v4l2-ioctl.c b/drivers/media/v4l2-core/v4l2-ioctl.c
> index 85de455..e8b78ae 100644
> --- a/drivers/media/v4l2-core/v4l2-ioctl.c
> +++ b/drivers/media/v4l2-core/v4l2-ioctl.c
> @@ -2784,3 +2784,8 @@ long video_ioctl2(struct file *file,
>  	return video_usercopy(file, cmd, arg, __video_do_ioctl);
>  }
>  EXPORT_SYMBOL(video_ioctl2);
> +
> +EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_buf_done);
> +EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_buf_queue);
> +EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_dqbuf);
> +EXPORT_TRACEPOINT_SYMBOL_GPL(vb2_qbuf);
> 


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

* Re: [PATCH] [media] v4l2: export videobuf2 trace points
  2015-07-28  8:02 ` Hans Verkuil
@ 2015-07-28  8:15   ` Philipp Zabel
  0 siblings, 0 replies; 3+ messages in thread
From: Philipp Zabel @ 2015-07-28  8:15 UTC (permalink / raw)
  To: Hans Verkuil
  Cc: Hans Verkuil, Mauro Carvalho Chehab, Kamil Debski,
	Sylwester Nawrocki, Pawel Osciak, Marek Szyprowski,
	Kyungmin Park, Steven Rostedt, linux-media, kernel

Am Dienstag, den 28.07.2015, 10:02 +0200 schrieb Hans Verkuil:
> On 07/28/2015 09:55 AM, Philipp Zabel wrote:
> > If videobuf2-core is built as a module, the vb2 trace points must be
> > exported from videodev.o to avoid errors when linking videobuf2-core.
> 
> I'm no tracepoint expert, so I'll just ask: if the tracepoint functionality
> is disabled in the kernel, will this still compile OK?
> 
> That is, will the EXPORT_TRACEPOINT_SYMBOL_GPL() code disappear in that
> case or will it point to absent code/data?

No traces left if CONFIG_TRACEPOINTS not set. include/linux/tracepoint.h
contains:

#ifdef CONFIG_TRACEPOINTS
#define EXPORT_TRACEPOINT_SYMBOL_GPL(name)         \
        EXPORT_SYMBOL_GPL(__tracepoint_##name)
#else /* !CONFIG_TRACEPOINTS */
#define EXPORT_TRACEPOINT_SYMBOL_GPL(name)
#endif

regards
Philipp


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

end of thread, other threads:[~2015-07-28  8:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-07-28  7:55 [PATCH] [media] v4l2: export videobuf2 trace points Philipp Zabel
2015-07-28  8:02 ` Hans Verkuil
2015-07-28  8:15   ` Philipp Zabel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).