[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5450B0B8.2060804@linux.intel.com>
Date: Wed, 29 Oct 2014 11:17:44 +0200
From: Sakari Ailus <sakari.ailus@...ux.intel.com>
To: Shuah Khan <shuahkh@....samsung.com>, m.chehab@...sung.com,
akpm@...ux-foundation.org, gregkh@...uxfoundation.org,
crope@....fi, olebowle@....com, dheitmueller@...nellabs.com,
hverkuil@...all.nl, ramakrmu@...co.com,
laurent.pinchart@...asonboard.com, perex@...ex.cz, tiwai@...e.de,
prabhakar.csengg@...il.com, tim.gardner@...onical.com,
linux@...elenboom.it
CC: linux-media@...r.kernel.org, alsa-devel@...a-project.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 0/6] media token resource framework
Hi Shuah and others,
Shuah Khan wrote:
> Add media token device resource framework to allow sharing
> resources such as tuner, dma, audio etc. across media drivers
> and non-media sound drivers that control media hardware. The
> Media token resource is created at the main struct device that
> is common to all drivers that claim various pieces of the main
> media device, which allows them to find the resource using the
> main struct device. As an example, digital, analog, and
> snd-usb-audio drivers can use the media token resource API
> using the main struct device for the interface the media device
> is attached to.
>
> This patch series consists of media token resource framework
> and changes to use it in dvb-core, v4l2-core, au0828 driver,
> and snd-usb-audio driver.
>
> With these changes dvb and v4l2 can share the tuner without
> disrupting each other. Used tvtime, xawtv, kaffeine, and vlc,
> vlc audio capture option, arecord/aplay during development to
> identify v4l2 vb2 and vb1 ioctls and file operations that
> disrupt the digital stream and would require changes to check
> tuner ownership prior to changing the tuner configuration.
> vb2 changes are made in the v4l2-core and vb1 changes are made
> in the au0828 driver to encourage porting drivers to vb2 to
> advantage of the new media token resource framework with changes
> in the core.
I know this comes quite late after the first patch series has been sent,
but I'd like to ask if you have you considered a different approach:
rather than implementing something entirely new, the Media controller
can almost do this already. It models the physical layout of the device,
instead of creating special use case specific Media entity like
constructs for tuner and audio. Also the Media token framework does not
appear to be as a perfect match for the Media controller framework which
is also planned to be used by DVB already:
<URL:http://linuxtv.org/news.php?entry=2014-10-21.mchehab>; look for "3)
DVB API improvements". There have been ALSA MC patches as well but I'm
not aware of the status of those at the moment.
The tokens appear much like media entities of specific kind to me.
Currently, media entities may only be entities bound to a given
subsystem, but I don't think it has to (or perhaps even may) stay that way.
In case of the Media controller, mutual exclusion of different users is
currently performed by adding the entities to a pipeline and
incrementing the streaming count once streaming is enabled --- on
different interfaces streaming may mean a different thing.
The Media controller interface does not handle serialising potential
users that may wish to configure the device. If that's needed then we'll
need to think how to add it.
--
Kind regards,
Sakari Ailus
sakari.ailus@...ux.intel.com
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists