summaryrefslogtreecommitdiff
path: root/include/media/v4l2-ctrls.h
diff options
context:
space:
mode:
authorHans Verkuil <hans.verkuil@cisco.com>2014-06-10 07:55:00 -0300
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-07-17 11:57:18 -0300
commit998e7659150760c0f4871ee20de2ef2276e3f80a (patch)
tree3f46982463b3ea8e68ac9d74b7f32cfd2aa068d5 /include/media/v4l2-ctrls.h
parent20d88eef66a86989ea3cffe2a4e0d16cbf2d4563 (diff)
[media] v4l2-ctrls: prepare for array support
Add core support for N-dimensional arrays. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'include/media/v4l2-ctrls.h')
-rw-r--r--include/media/v4l2-ctrls.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/include/media/v4l2-ctrls.h b/include/media/v4l2-ctrls.h
index d30da09b7b69..7915b1125bb5 100644
--- a/include/media/v4l2-ctrls.h
+++ b/include/media/v4l2-ctrls.h
@@ -74,13 +74,13 @@ struct v4l2_ctrl_ops {
* @validate: validate the value. Return 0 on success and a negative value otherwise.
*/
struct v4l2_ctrl_type_ops {
- bool (*equal)(const struct v4l2_ctrl *ctrl,
+ bool (*equal)(const struct v4l2_ctrl *ctrl, u32 idx,
union v4l2_ctrl_ptr ptr1,
union v4l2_ctrl_ptr ptr2);
- void (*init)(const struct v4l2_ctrl *ctrl,
+ void (*init)(const struct v4l2_ctrl *ctrl, u32 idx,
union v4l2_ctrl_ptr ptr);
void (*log)(const struct v4l2_ctrl *ctrl);
- int (*validate)(const struct v4l2_ctrl *ctrl,
+ int (*validate)(const struct v4l2_ctrl *ctrl, u32 idx,
union v4l2_ctrl_ptr ptr);
};
@@ -111,6 +111,7 @@ typedef void (*v4l2_ctrl_notify_fnc)(struct v4l2_ctrl *ctrl, void *priv);
* @is_ptr: If set, then this control is an array and/or has type >= V4L2_CTRL_COMPOUND_TYPES
* and/or has type V4L2_CTRL_TYPE_STRING. In other words, struct
* v4l2_ext_control uses field p to point to the data.
+ * @is_array: If set, then this control contains an N-dimensional array.
* @has_volatiles: If set, then one or more members of the cluster are volatile.
* Drivers should never touch this flag.
* @call_notify: If set, then call the handler's notify function whenever the
@@ -169,6 +170,7 @@ struct v4l2_ctrl {
unsigned int is_int:1;
unsigned int is_string:1;
unsigned int is_ptr:1;
+ unsigned int is_array:1;
unsigned int has_volatiles:1;
unsigned int call_notify:1;
unsigned int manual_mode_value:8;