From: Sylwester Nawrocki <sylvester.nawrocki@gmail.com>
To: Hans Verkuil <hverkuil@xs4all.nl>
Cc: linux-media@vger.kernel.org, m.chehab@samsung.com,
laurent.pinchart@ideasonboard.com, t.stanislaws@samsung.com,
Hans Verkuil <hans.verkuil@cisco.com>
Subject: Re: [RFCv2 PATCH 05/21] videodev2.h: add struct v4l2_query_ext_ctrl and VIDIOC_QUERY_EXT_CTRL.
Date: Thu, 23 Jan 2014 00:02:03 +0100 [thread overview]
Message-ID: <52E04DEB.2000800@gmail.com> (raw)
In-Reply-To: <1390221974-28194-6-git-send-email-hverkuil@xs4all.nl>
On 01/20/2014 01:45 PM, Hans Verkuil wrote:
> From: Hans Verkuil<hans.verkuil@cisco.com>
>
> Add a new struct and ioctl to extend the amount of information you can
> get for a control.
>
> It gives back a unit string, the range is now a s64 type, and the matrix
> and element size can be reported through cols/rows/elem_size.
>
> Signed-off-by: Hans Verkuil<hans.verkuil@cisco.com>
> ---
> include/uapi/linux/videodev2.h | 30 ++++++++++++++++++++++++++++++
> 1 file changed, 30 insertions(+)
>
> diff --git a/include/uapi/linux/videodev2.h b/include/uapi/linux/videodev2.h
> index 4d7782a..9e5b7d4 100644
> --- a/include/uapi/linux/videodev2.h
> +++ b/include/uapi/linux/videodev2.h
> @@ -1272,6 +1272,34 @@ struct v4l2_queryctrl {
> __u32 reserved[2];
> };
>
> +/* Used in the VIDIOC_QUERY_EXT_CTRL ioctl for querying extended controls */
> +struct v4l2_query_ext_ctrl {
> + __u32 id;
> + __u32 type;
> + char name[32];
> + char unit[32];
> + union {
> + __s64 val;
> + __u32 reserved[4];
> + } min;
> + union {
> + __s64 val;
> + __u32 reserved[4];
> + } max;
> + union {
> + __u64 val;
> + __u32 reserved[4];
> + } step;
> + union {
> + __s64 val;
> + __u32 reserved[4];
> + } def;
Are these reserved[] arrays of any use ?
> + __u32 flags;
> + __u32 cols, rows;
nit: I would put them on separate lines and use full words.
> + __u32 elem_size;
> + __u32 reserved[17];
> +};
> +
> /* Used in the VIDIOC_QUERYMENU ioctl for querying menu items */
> struct v4l2_querymenu {
> __u32 id;
> @@ -1965,6 +1993,8 @@ struct v4l2_create_buffers {
> Never use these in applications! */
> #define VIDIOC_DBG_G_CHIP_INFO _IOWR('V', 102, struct v4l2_dbg_chip_info)
>
> +#define VIDIOC_QUERY_EXT_CTRL _IOWR('V', 103, struct v4l2_query_ext_ctrl)
> +
> /* Reminder: when adding new ioctls please add support for them to
> drivers/media/video/v4l2-compat-ioctl32.c as well! */
--
Regards,
Sylwester
next prev parent reply other threads:[~2014-01-22 23:02 UTC|newest]
Thread overview: 56+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-20 12:45 [RFCv2 PATCH 00/21] Add support for complex controls Hans Verkuil
2014-01-20 12:45 ` [RFCv2 PATCH 01/21] v4l2-ctrls: increase internal min/max/step/def to 64 bit Hans Verkuil
2014-01-22 22:45 ` Sylwester Nawrocki
2014-01-20 12:45 ` [RFCv2 PATCH 02/21] v4l2-ctrls: add unit string Hans Verkuil
2014-01-22 22:47 ` Sylwester Nawrocki
2014-01-24 10:35 ` Sakari Ailus
2014-01-24 11:19 ` Hans Verkuil
2014-01-24 15:54 ` Sakari Ailus
2014-01-25 9:00 ` Hans Verkuil
2014-01-20 12:45 ` [RFCv2 PATCH 03/21] v4l2-ctrls: use pr_info/cont instead of printk Hans Verkuil
2014-01-22 22:48 ` Sylwester Nawrocki
2014-01-20 12:45 ` [RFCv2 PATCH 04/21] videodev2.h: add initial support for complex controls Hans Verkuil
2014-01-22 22:55 ` Sylwester Nawrocki
2014-01-20 12:45 ` [RFCv2 PATCH 05/21] videodev2.h: add struct v4l2_query_ext_ctrl and VIDIOC_QUERY_EXT_CTRL Hans Verkuil
2014-01-22 23:02 ` Sylwester Nawrocki [this message]
2014-01-23 14:23 ` Hans Verkuil
2014-01-23 15:05 ` Sylwester Nawrocki
2014-01-24 11:28 ` Sakari Ailus
2014-01-24 11:58 ` Hans Verkuil
2014-01-20 12:45 ` [RFCv2 PATCH 06/21] v4l2-ctrls: add support for complex types Hans Verkuil
2014-01-23 11:44 ` Sylwester Nawrocki
2014-01-24 15:44 ` Sakari Ailus
2014-01-25 8:50 ` Hans Verkuil
2014-01-20 12:46 ` [RFCv2 PATCH 07/21] v4l2: integrate support for VIDIOC_QUERY_EXT_CTRL Hans Verkuil
2014-01-23 11:44 ` Sylwester Nawrocki
2014-01-20 12:46 ` [RFCv2 PATCH 08/21] v4l2-ctrls: create type_ops Hans Verkuil
2014-01-23 14:23 ` Sylwester Nawrocki
2014-01-24 15:46 ` Sakari Ailus
2014-01-25 8:54 ` Hans Verkuil
2014-01-20 12:46 ` [RFCv2 PATCH 09/21] v4l2-ctrls: rewrite copy routines to operate on union v4l2_ctrl_ptr Hans Verkuil
2014-01-24 12:31 ` Sakari Ailus
2014-01-24 12:44 ` Hans Verkuil
2014-01-20 12:46 ` [RFCv2 PATCH 10/21] v4l2-ctrls: compare values only once Hans Verkuil
2014-01-23 14:30 ` Sylwester Nawrocki
2014-01-20 12:46 ` [RFCv2 PATCH 11/21] v4l2-ctrls: prepare for matrix support: add cols & rows fields Hans Verkuil
2014-01-23 13:46 ` Sylwester Nawrocki
2014-01-20 12:46 ` [RFCv2 PATCH 12/21] v4l2-ctrls: replace cur by a union v4l2_ctrl_ptr Hans Verkuil
2014-01-23 15:47 ` Sylwester Nawrocki
2014-01-20 12:46 ` [RFCv2 PATCH 13/21] v4l2-ctrls: use 'new' to access pointer controls Hans Verkuil
2014-01-23 17:06 ` Sylwester Nawrocki
2014-01-20 12:46 ` [RFCv2 PATCH 14/21] v4l2-ctrls: prepare for matrix support Hans Verkuil
2014-01-20 12:46 ` [RFCv2 PATCH 15/21] v4l2-ctrls: type_ops can handle matrix elements Hans Verkuil
2014-01-20 12:46 ` [RFCv2 PATCH 16/21] v4l2-ctrls: add matrix support Hans Verkuil
2014-01-20 12:46 ` [RFCv2 PATCH 17/21] v4l2-ctrls.c: return elem_size instead of strlen Hans Verkuil
2014-01-23 13:46 ` Sylwester Nawrocki
2014-01-20 12:46 ` [RFCv2 PATCH 18/21] DocBook media: document VIDIOC_QUERY_EXT_CTRL Hans Verkuil
2014-01-23 17:24 ` Sylwester Nawrocki
2014-01-20 12:46 ` [RFCv2 PATCH 19/21] DocBook media: update VIDIOC_G/S/TRY_EXT_CTRLS Hans Verkuil
2014-01-23 13:46 ` Sylwester Nawrocki
2014-01-23 14:16 ` Hans Verkuil
2014-01-20 12:46 ` [RFCv2 PATCH 20/21] DocBook media: update control section Hans Verkuil
2014-01-23 15:34 ` Sylwester Nawrocki
2014-01-20 12:46 ` [RFCv2 PATCH 21/21] v4l2-controls.txt: update to the new way of accessing controls Hans Verkuil
2014-01-23 15:50 ` Sylwester Nawrocki
2014-01-22 22:44 ` [RFCv2 PATCH 00/21] Add support for complex controls Sylwester Nawrocki
2014-01-23 11:49 ` Hans Verkuil
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=52E04DEB.2000800@gmail.com \
--to=sylvester.nawrocki@gmail.com \
--cc=hans.verkuil@cisco.com \
--cc=hverkuil@xs4all.nl \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-media@vger.kernel.org \
--cc=m.chehab@samsung.com \
--cc=t.stanislaws@samsung.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.