Lines Matching full:control
29 * union v4l2_ctrl_ptr - A pointer to a control value.
111 * struct v4l2_ctrl_ops - The control operations that the driver has to provide.
113 * @g_volatile_ctrl: Get a new value for this control. Generally only relevant
114 * for volatile (and usually read-only) controls such as a control
118 * @try_ctrl: Test whether the control's value is valid. Only relevant when
120 * @s_ctrl: Actually set the new control value. s_ctrl is compulsory. The
131 * struct v4l2_ctrl_type_ops - The control type operations that the driver
136 * @minimum: set the value to the minimum value of the control.
137 * @maximum: set the value to the maximum value of the control.
157 * that should be called when a control value has changed.
160 * @priv: control private data
168 * struct v4l2_ctrl - The control structure.
171 * @ev_subs: The list of control event subscriptions.
172 * @handler: The handler that owns the control.
175 * @done: Internal flag: set for each processed control.
176 * @is_new: Set when the user specified a new value for this control. It
181 * @is_private: If set, then this control is private to its handler and it
184 * @is_auto: If set, then this control selects whether the other cluster
188 * @is_int: If set, then this control has a simple integer value (i.e. it
190 * @is_string: If set, then this control has type %V4L2_CTRL_TYPE_STRING.
191 * @is_ptr: If set, then this control is an array and/or has type >=
195 * @is_array: If set, then this control contains an N-dimensional array.
196 * @is_dyn_array: If set, then this control contains a dynamically sized 1-dimensional array.
201 * control's value changes.
203 * of the auto control that determines if that control is in
204 * manual mode. So if the value of the auto control equals this
207 * @ops: The control ops.
208 * @type_ops: The control type ops.
209 * @id: The control ID.
210 * @name: The control name.
211 * @type: The control type.
212 * @minimum: The control's minimum value.
213 * @maximum: The control's maximum value.
214 * @default_value: The control's default value.
215 * @step: The control's step value for non-menu controls.
217 * @elem_size: The size in bytes of the control.
223 * @menu_skip_mask: The control's skip mask for menu controls. This makes it
238 * @flags: The control's flags.
239 * @priv: The control's private pointer. For use by the driver. It is
240 * untouched by the control framework. Note that this pointer is
241 * not freed when the control is deleted. Should this be needed
250 * @cur.val: The control's current value, if the @type is represented via
252 * @val: The control's new s32 value.
253 * @p_def: The control's default value represented via a union which
254 * provides a standard way of accessing control types
256 * @p_min: The control's minimum value represented via a union which
257 * provides a standard way of accessing control types
259 * @p_max: The control's maximum value represented via a union which
260 * provides a standard way of accessing control types
262 * @p_cur: The control's current value represented via a union which
263 * provides a standard way of accessing control types
265 * @p_new: The control's new value represented via a union which provides
266 * a standard way of accessing control types
328 * struct v4l2_ctrl_ref - The control reference.
332 * @ctrl: The actual control information.
337 * @req_done: Internal flag: if the control handler containing this control
339 * the control has been applied. This prevents applying controls
341 * control of a cluster is applied, they all are).
342 * @p_req_valid: If set, then p_req contains the control value for the request.
353 * @p_req: If the control handler containing this control reference
355 * value of the control that must be applied when the request
356 * is executed, or to the value of the control at the time
358 * then this control was never set for this request and the
359 * control will not be updated when this request is applied.
361 * Each control handler has a list of these refs. The list_head is used to
362 * keep a sorted-by-control-ID list of all controls, while the next pointer
363 * is used to link the control in the hash's bucket.
380 * struct v4l2_ctrl_handler - The control handler keeps track of all the
385 * @lock: Lock to control access to this handler and its controls.
388 * @ctrl_refs: The list of control references.
389 * @cached: The last found control reference. It is common that the same
390 * control is needed multiple times, so this is a simple
392 * @buckets: Buckets for the hashing. Allows for quick control lookup.
393 * @notify: A notify callback that is called whenever the control changes
399 * @error: The error code of the first failed control addition.
401 * @requests: List to keep track of open control handler request objects.
402 * For the parent control handler (@req_obj.ops == NULL) this
403 * is the list header. When the parent control handler is
430 * struct v4l2_ctrl_config - Control configuration structure.
432 * @ops: The control ops.
433 * @type_ops: The control type ops. Only needed for compound controls.
434 * @id: The control ID.
435 * @name: The control name.
436 * @type: The control type.
437 * @min: The control's minimum value.
438 * @max: The control's maximum value.
439 * @step: The control's step value for non-menu controls.
440 * @def: The control's default value.
441 * @p_def: The control's default value for compound controls.
442 * @p_min: The control's minimum value for compound controls.
443 * @p_max: The control's maximum value for compound controls.
445 * @elem_size: The size in bytes of the control.
446 * @flags: The control's flags.
447 * @menu_skip_mask: The control's skip mask for menu controls. This makes it
459 * @is_private: If set, then this control is private to its handler and it
485 * v4l2_ctrl_fill - Fill in the control fields based on the control ID.
487 * @id: ID of the control
488 * @name: pointer to be filled with a string with the name of the control
489 * @type: pointer for storing the type of the control
490 * @min: pointer for storing the minimum value for the control
491 * @max: pointer for storing the maximum value for the control
492 * @step: pointer for storing the control step
493 * @def: pointer for storing the default value for the control
494 * @flags: pointer for storing the flags to be used on the control
507 * control handling only. Once all drivers are converted to use the new
508 * control framework this function will no longer be exported.
515 * v4l2_ctrl_handler_init_class() - Initialize the control handler.
516 * @hdl: The control handler.
521 * are allocated) or the control lookup becomes slower (not enough
545 * @hdl: The control handler.
550 * are allocated) or the control lookup becomes slower (not enough
558 * Use this helper function to initialize a control handler.
578 * the control list.
579 * @hdl: The control handler.
587 * associated with the control.
588 * @ctrl: The control to lock.
597 * associated with the control.
598 * @ctrl: The control to unlock.
607 * to the handler to initialize the hardware to the current control values. The
608 * caller is responsible for acquiring the control handler mutex on behalf of
610 * @hdl: The control handler.
620 * to the handler to initialize the hardware to the current control values.
621 * @hdl: The control handler.
631 * @hdl: The control handler.
632 * @prefix: The prefix to use when logging the control values. If the
646 * control.
648 * @hdl: The control handler.
649 * @cfg: The control's configuration data.
650 * @priv: The control's driver-specific private data.
661 * control.
663 * @hdl: The control handler.
664 * @ops: The control ops.
665 * @id: The control ID.
666 * @min: The control's minimum value.
667 * @max: The control's maximum value.
668 * @step: The control's step value
669 * @def: The control's default value.
671 * If the &v4l2_ctrl struct could not be allocated, or the control
675 * If @id refers to a menu control, then this function will return NULL.
686 * menu control.
688 * @hdl: The control handler.
689 * @ops: The control ops.
690 * @id: The control ID.
691 * @max: The control's maximum value.
692 * @mask: The control's skip mask for menu controls. This makes it
698 * @def: The control's default value.
703 * If @id refers to a non-menu control, then this function will return NULL.
710 * v4l2_ctrl_new_std_menu_items() - Create a new standard V4L2 menu control
713 * @hdl: The control handler.
714 * @ops: The control ops.
715 * @id: The control ID.
716 * @max: The control's maximum value.
717 * @mask: The control's skip mask for menu controls. This makes it
723 * @def: The control's default value.
727 * menu of this control.
738 * compound control.
740 * @hdl: The control handler.
741 * @ops: The control ops.
742 * @id: The control ID.
743 * @p_def: The control's default value.
744 * @p_min: The control's minimum value.
745 * @p_max: The control's maximum value.
751 * value of the compound control to be all zeroes.
752 * If the compound control does not set the ``V4L2_CTRL_FLAG_HAS_WHICH_MIN_MAX``
765 * v4l2_ctrl_new_int_menu() - Create a new standard V4L2 integer menu control.
767 * @hdl: The control handler.
768 * @ops: The control ops.
769 * @id: The control ID.
770 * @max: The control's maximum value.
771 * @def: The control's default value.
772 * @qmenu_int: The control's menu entries.
777 * If @id refers to a non-integer-menu control, then this function will
787 * used when adding a control handler.
798 * @hdl: The control handler.
799 * @add: The control handler whose controls you want to add to
800 * the @hdl control handler.
819 * @ctrl: The control that is filtered.
834 * @controls: The cluster control array of size @ncontrols.
844 * @controls: The cluster control array of size @ncontrols. The first control
845 * must be the 'auto' control (e.g. autogain, autoexposure, etc.)
846 * @manual_val: The value for the first control in the cluster that equals the
848 * @set_volatile: If true, then all controls except the first auto control will
851 * Use for control groups where one control selects some automatic feature and
858 * When the autofoo control is set to automatic, then any manual controls
859 * are set to inactive and any reads will call g_volatile_ctrl (if the control
862 * When the autofoo control is set to manual, then any manual controls will
867 * on the autofoo control and %V4L2_CTRL_FLAG_INACTIVE on the foo control(s)
876 * v4l2_ctrl_find() - Find a control with the given ID.
878 * @hdl: The control handler.
879 * @id: The control ID to find.
887 * v4l2_ctrl_activate() - Make the control active or inactive.
888 * @ctrl: The control to (de)activate.
889 * @active: True if the control should become active.
896 * This function assumes that the control handler is locked.
903 * @ctrl: The control to (de)activate.
904 * @grabbed: True if the control should become grabbed.
912 * This function assumes that the control handler is locked by the caller.
917 * v4l2_ctrl_grab() - Mark the control as grabbed or not grabbed.
919 * @ctrl: The control to (de)activate.
920 * @grabbed: True if the control should become grabbed.
928 * This function assumes that the control handler is not locked and will
944 * @ctrl: The control to update.
945 * @min: The control's minimum value.
946 * @max: The control's maximum value.
947 * @step: The control's step value
948 * @def: The control's default value.
950 * Update the range of a control on the fly. This works for control types
955 * control type.
957 * The caller is responsible for acquiring the control handler mutex on behalf
964 * v4l2_ctrl_modify_range() - Update the range of a control.
966 * @ctrl: The control to update.
967 * @min: The control's minimum value.
968 * @max: The control's maximum value.
969 * @step: The control's step value
970 * @def: The control's default value.
972 * Update the range of a control on the fly. This works for control types
977 * control type.
979 * This function assumes that the control handler is not locked and will
997 * @ctrl: The control to update.
998 * @dims: The control's new dimensions.
1000 * Update the dimensions of an array control on the fly. The elements of the
1004 * An error is returned if @dims is invalid for this control.
1006 * The caller is responsible for acquiring the control handler mutex on behalf
1009 * Note: calling this function when the same control is used in pending requests
1010 * is untested. It should work (a request with the wrong size of the control
1011 * will drop that control silently), but it will be very confusing.
1017 * v4l2_ctrl_modify_dimensions() - Update the dimensions of an array control.
1019 * @ctrl: The control to update.
1020 * @dims: The control's new dimensions.
1022 * Update the dimensions of an array control on the fly. The elements of the
1026 * An error is returned if @dims is invalid for this control type.
1028 * This function assumes that the control handler is not locked and will
1031 * Note: calling this function when the same control is used in pending requests
1032 * is untested. It should work (a request with the wrong size of the control
1033 * will drop that control silently), but it will be very confusing.
1048 * v4l2_ctrl_notify() - Function to set a notify callback for a control.
1050 * @ctrl: The control.
1054 * This function sets a callback function for the control. If @ctrl is NULL,
1065 * v4l2_ctrl_get_name() - Get the name of the control
1067 * @id: The control ID.
1069 * This function returns the name of the given control ID or NULL if it isn't
1070 * a known control.
1075 * v4l2_ctrl_get_menu() - Get the menu string array of the control
1077 * @id: The control ID.
1080 * given control ID or NULL if it isn't a known menu control.
1085 * v4l2_ctrl_get_int_menu() - Get the integer menu array of the control
1087 * @id: The control ID.
1090 * This function returns the integer array of the given control ID or NULL if it
1091 * if it isn't a known integer menu control.
1096 * v4l2_ctrl_g_ctrl() - Helper function to get the control's value from
1099 * @ctrl: The control.
1101 * This returns the control's value safely by going through the control
1102 * framework. This function will lock the control's handler, so it cannot be
1112 * @ctrl: The control.
1115 * This sets the control's new value safely by going through the control
1116 * framework. This function assumes the control's handler is already locked,
1124 * v4l2_ctrl_s_ctrl() - Helper function to set the control's value from
1126 * @ctrl: The control.
1129 * This sets the control's new value safely by going through the control
1130 * framework. This function will lock the control's handler, so it cannot be
1147 * v4l2_ctrl_g_ctrl_int64() - Helper function to get a 64-bit control's value
1150 * @ctrl: The control.
1152 * This returns the control's value safely by going through the control
1153 * framework. This function will lock the control's handler, so it cannot be
1163 * @ctrl: The control.
1166 * This sets the control's new value safely by going through the control
1167 * framework. This function assumes the control's handler is already locked,
1175 * v4l2_ctrl_s_ctrl_int64() - Helper function to set a 64-bit control's value
1178 * @ctrl: The control.
1181 * This sets the control's new value safely by going through the control
1182 * framework. This function will lock the control's handler, so it cannot be
1201 * @ctrl: The control.
1204 * This sets the control's new string safely by going through the control
1205 * framework. This function assumes the control's handler is already locked,
1213 * v4l2_ctrl_s_ctrl_string() - Helper function to set a control's string value
1216 * @ctrl: The control.
1219 * This sets the control's new string safely by going through the control
1220 * framework. This function will lock the control's handler, so it cannot be
1237 * __v4l2_ctrl_s_ctrl_compound() - Unlocked variant to set a compound control
1239 * @ctrl: The control.
1243 * This sets the control's new compound payload safely by going through the
1244 * control framework. This function assumes the control's handler is already
1253 * v4l2_ctrl_s_ctrl_compound() - Helper function to set a compound control
1256 * @ctrl: The control.
1260 * This sets the control's new compound payload safely by going through the
1261 * control framework. This function will lock the control's handler, so it
1285 /* Internal helper functions that deal with control events. */
1330 * control events.
1337 * That just polls for control events.
1345 * v4l2_ctrl_request_setup - helper function to apply control values in a request
1348 * @parent: The parent control handler ('priv' in media_request_object_find())
1350 * This is a helper function to call the control handler's s_ctrl callback with
1351 * the control values contained in the request. Do note that this approach of
1352 * applying control values in a request is only applicable to memory-to-memory
1359 * v4l2_ctrl_request_complete - Complete a control handler request object
1362 * @parent: The parent control handler ('priv' in media_request_object_find())
1364 * This function is to be called on each control handler that may have had a
1365 * request object associated with it, i.e. control handlers of a driver that
1368 * The function first obtains the values of any volatile controls in the control
1376 * v4l2_ctrl_request_hdl_find - Find the control handler in the request
1379 * @parent: The parent control handler ('priv' in media_request_object_find())
1381 * This function finds the control handler in the request. It may return
1397 * v4l2_ctrl_request_hdl_put - Put the control handler
1399 * @hdl: Put this control handler
1401 * This function released the control handler previously obtained from'
1411 * v4l2_ctrl_request_hdl_ctrl_find() - Find a control with the given ID.
1413 * @hdl: The control handler from the request.
1414 * @id: The ID of the control to find.
1416 * This function returns a pointer to the control if this control is
1545 * that just subscribes control events.
1555 * v4l2_ctrl_subdev_log_status - Log all controls owned by subdev's control
1578 * Controls already registered by the caller with the @hdl control handler are
1592 * @ptr1: A v4l2 control value.
1593 * @ptr2: A v4l2 control value.
1605 * @ptr: The v4l2 control value.
1625 * @ptr: The v4l2 control value.