public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
From: Hans Verkuil <hverkuil@xs4all.nl>
To: Divneil Rai WADHAWAN <divneil.wadhawan@st.com>,
	"linux-media@vger.kernel.org" <linux-media@vger.kernel.org>
Cc: "divneil@outlook.com" <divneil@outlook.com>
Subject: Re: Subdev notification for video device
Date: Tue, 24 Mar 2015 04:48:39 -0700	[thread overview]
Message-ID: <55114F17.9040206@xs4all.nl> (raw)
In-Reply-To: <C17522D12DF21D4F9DC8833224F23A8705F96EEB@EAPEX1MAIL1.st.com>

On 03/24/2015 12:49 AM, Divneil Rai WADHAWAN wrote:
> Hello,
> 
> I have a use case, where, I am using subdev configuration to setup video capture.
> The pipeline is something like this:
> 
> Subdevs: sd_display, sd_capture
> Vdev: vcapture
> 
>  (0)sd_display(1) -> (0)sd_capture(1)->(0)vcapture
> 
> sd_display informs sd_capture of video resolution change and vdev using sd_capture needs to be informed, so, that vdev capture can be stopped.
> 
> Here, subdev notification/subscription is missing to/from vdev, in my understanding.
> subdev can send notification to v4l2-dev, but not vdev.
> Can you help with that? Thanks.

This is correct. The subdev doesn't and cannot know anything about which video node(s)
need(s) to send out a source change event. The only driver that can is the top-level driver
that knows the topology and can map the event from the sd to the correct video_device.

If your driver uses the media controller, then it should be possible to write a generic
function that would use the topology to discover automatically which video_device nodes
are linked to the sd and propagate the event to those video devices.

Such a generic v4l2_dev notify function doesn't exist today though. Patches are welcome.

If the driver doesn't use the media controller, then the top-level driver should provide
this knowledge in its v4l2_dev notifier function.

Regards,

	Hans

      reply	other threads:[~2015-03-24 11:48 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-24  7:49 Subdev notification for video device Divneil Rai WADHAWAN
2015-03-24 11:48 ` Hans Verkuil [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=55114F17.9040206@xs4all.nl \
    --to=hverkuil@xs4all.nl \
    --cc=divneil.wadhawan@st.com \
    --cc=divneil@outlook.com \
    --cc=linux-media@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox