From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Sakari Ailus <sakari.ailus@iki.fi>
Cc: Jacek Anaszewski <j.anaszewski@samsung.com>,
linux-media@vger.kernel.org, s.nawrocki@samsung.com,
b.zolnierkie@samsung.com, kyungmin.park@samsung.com,
Mauro Carvalho Chehab <mchehab@osg.samsung.com>,
Hans Verkuil <hans.verkuil@cisco.com>
Subject: Re: [PATCH/RFC v2 2/4] Add media device related data structures and API.
Date: Wed, 22 Oct 2014 21:45:47 +0300 [thread overview]
Message-ID: <18631516.oW73vIsC5r@avalon> (raw)
In-Reply-To: <20141022100301.GH15257@valkosipuli.retiisi.org.uk>
Hi Sakari,
On Wednesday 22 October 2014 13:03:02 Sakari Ailus wrote:
> On Fri, Oct 17, 2014 at 04:54:40PM +0200, Jacek Anaszewski wrote:
> ...
>
> > +/*
> > + * struct media_entity - media device entity data
> > + * @id: media entity id within media controller
> > + * @name: media entity name
> > + * @node_name: media entity related device node name
> > + * @pads: array of media_entity pads
> > + * @num_pads: number of elements in the pads array
> > + * @links: array of media_entity links
> > + * @num_links: number of elements in the links array
> > + * @subdev_fmt: related sub-device format
> > + * @fd: related sub-device node file descriptor
> > + * @src_pad_id: source pad id when entity is linked
> > + * @sink_pad_id: sink pad id when entity is linked
> > + * @next: pointer to the next data structure in the list
> > + */
> > +struct media_entity {
> > + int id;
> > + char name[32];
> > + char node_name[32];
> > + struct media_pad_desc *pads;
> > + int num_pads;
> > + struct media_link_desc *links;
> > + int num_links;
> > + struct v4l2_subdev_format subdev_fmt;
> > + int fd;
> > + int src_pad_id;
> > + int sink_pad_id;
> > + struct media_entity *next;
> > +};
>
> Could you use libmediactl and libv4l2subdev instead here as well? They do
> actually implement much of what you do here. Feel free to comment on the
> API. The libraries have a little bit different background than this one.
> Obviously there's functionality in this library what's not in the two; some
> of this might belong to either of the two libraries.
>
> I think we'll need V4L2 sub-device related information stored next to the
> media entities as well, so that's something to be added.
I generic mechanism to attach subsystem-specific data to entities sounds good
to me. The fd field could then be moved out of struct media_entity.
--
Regards,
Laurent Pinchart
next prev parent reply other threads:[~2014-10-22 20:17 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-17 14:54 [PATCH/RFC v2 0/4] Libv4l: Add a plugin for the Exynos4 camera Jacek Anaszewski
2014-10-17 14:54 ` [PATCH/RFC v2 1/4] Add a media device configuration file parser Jacek Anaszewski
2014-10-20 21:44 ` Sakari Ailus
2014-10-21 7:17 ` Jacek Anaszewski
2014-10-21 9:26 ` Sakari Ailus
2014-10-21 10:11 ` Jacek Anaszewski
2014-10-17 14:54 ` [PATCH/RFC v2 2/4] Add media device related data structures and API Jacek Anaszewski
2014-10-22 10:03 ` Sakari Ailus
2014-10-22 18:45 ` Laurent Pinchart [this message]
2014-10-17 14:54 ` [PATCH/RFC v2 3/4] Add wrappers for media device related ioctl calls Jacek Anaszewski
2014-10-17 14:54 ` [PATCH/RFC v2 4/4] Add a libv4l plugin for Exynos4 camera Jacek Anaszewski
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=18631516.oW73vIsC5r@avalon \
--to=laurent.pinchart@ideasonboard.com \
--cc=b.zolnierkie@samsung.com \
--cc=hans.verkuil@cisco.com \
--cc=j.anaszewski@samsung.com \
--cc=kyungmin.park@samsung.com \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@osg.samsung.com \
--cc=s.nawrocki@samsung.com \
--cc=sakari.ailus@iki.fi \
/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;
as well as URLs for NNTP newsgroup(s).