public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
* Subdev notification for video device
@ 2015-03-24  7:49 Divneil Rai WADHAWAN
  2015-03-24 11:48 ` Hans Verkuil
  0 siblings, 1 reply; 2+ messages in thread
From: Divneil Rai WADHAWAN @ 2015-03-24  7:49 UTC (permalink / raw)
  To: linux-media@vger.kernel.org; +Cc: divneil@outlook.com

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.

Regards,
Divneil 

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

* Re: Subdev notification for video device
  2015-03-24  7:49 Subdev notification for video device Divneil Rai WADHAWAN
@ 2015-03-24 11:48 ` Hans Verkuil
  0 siblings, 0 replies; 2+ messages in thread
From: Hans Verkuil @ 2015-03-24 11:48 UTC (permalink / raw)
  To: Divneil Rai WADHAWAN, linux-media@vger.kernel.org; +Cc: divneil@outlook.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

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

end of thread, other threads:[~2015-03-24 11:48 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-24  7:49 Subdev notification for video device Divneil Rai WADHAWAN
2015-03-24 11:48 ` Hans Verkuil

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox