Lines Matching refs:ref
1722 struct v4l2_ctrl_ref *ref, *next_ref; in v4l2_ctrl_handler_free() local
1731 list_for_each_entry_safe(ref, next_ref, &hdl->ctrl_refs, node) { in v4l2_ctrl_handler_free()
1732 list_del(&ref->node); in v4l2_ctrl_handler_free()
1733 kfree(ref); in v4l2_ctrl_handler_free()
1759 struct v4l2_ctrl_ref *ref; in find_private_ref() local
1762 list_for_each_entry(ref, &hdl->ctrl_refs, node) { in find_private_ref()
1765 if (V4L2_CTRL_ID2CLASS(ref->ctrl->id) == V4L2_CTRL_CLASS_USER && in find_private_ref()
1766 V4L2_CTRL_DRIVER_PRIV(ref->ctrl->id)) { in find_private_ref()
1767 if (!ref->ctrl->is_int) in find_private_ref()
1770 return ref; in find_private_ref()
1780 struct v4l2_ctrl_ref *ref; in find_ref() local
1795 ref = hdl->buckets ? hdl->buckets[bucket] : NULL; in find_ref()
1796 while (ref && ref->ctrl->id != id) in find_ref()
1797 ref = ref->next; in find_ref()
1799 if (ref) in find_ref()
1800 hdl->cached = ref; /* cache it! */ in find_ref()
1801 return ref; in find_ref()
1808 struct v4l2_ctrl_ref *ref = NULL; in find_ref_lock() local
1812 ref = find_ref(hdl, id); in find_ref_lock()
1815 return ref; in find_ref_lock()
1821 struct v4l2_ctrl_ref *ref = find_ref_lock(hdl, id); in v4l2_ctrl_find() local
1823 return ref ? ref->ctrl : NULL; in v4l2_ctrl_find()
1831 struct v4l2_ctrl_ref *ref; in handler_new_ref() local
1876 list_for_each_entry(ref, &hdl->ctrl_refs, node) { in handler_new_ref()
1877 if (ref->ctrl->id < id) in handler_new_ref()
1880 if (ref->ctrl->id == id) { in handler_new_ref()
1884 list_add(&new_ref->node, ref->node.prev); in handler_new_ref()
2224 struct v4l2_ctrl_ref *ref; in v4l2_ctrl_add_handler() local
2233 list_for_each_entry(ref, &add->ctrl_refs, node) { in v4l2_ctrl_add_handler()
2234 struct v4l2_ctrl *ctrl = ref->ctrl; in v4l2_ctrl_add_handler()
2469 struct v4l2_ctrl_ref *ref; in v4l2_query_ext_ctrl() local
2478 ref = find_ref(hdl, id); in v4l2_query_ext_ctrl()
2498 ref = NULL; /* Yes, so there is no next control */ in v4l2_query_ext_ctrl()
2499 } else if (ref) { in v4l2_query_ext_ctrl()
2502 list_for_each_entry_continue(ref, &hdl->ctrl_refs, node) { in v4l2_query_ext_ctrl()
2503 is_compound = ref->ctrl->is_array || in v4l2_query_ext_ctrl()
2504 ref->ctrl->type >= V4L2_CTRL_COMPOUND_TYPES; in v4l2_query_ext_ctrl()
2505 if (id < ref->ctrl->id && in v4l2_query_ext_ctrl()
2509 if (&ref->node == &hdl->ctrl_refs) in v4l2_query_ext_ctrl()
2510 ref = NULL; in v4l2_query_ext_ctrl()
2516 list_for_each_entry(ref, &hdl->ctrl_refs, node) { in v4l2_query_ext_ctrl()
2517 is_compound = ref->ctrl->is_array || in v4l2_query_ext_ctrl()
2518 ref->ctrl->type >= V4L2_CTRL_COMPOUND_TYPES; in v4l2_query_ext_ctrl()
2519 if (id < ref->ctrl->id && in v4l2_query_ext_ctrl()
2523 if (&ref->node == &hdl->ctrl_refs) in v4l2_query_ext_ctrl()
2524 ref = NULL; in v4l2_query_ext_ctrl()
2529 if (!ref) in v4l2_query_ext_ctrl()
2532 ctrl = ref->ctrl; in v4l2_query_ext_ctrl()
2707 struct v4l2_ctrl_ref *ref; in prepare_ext_ctrls() local
2720 ref = find_ref_lock(hdl, id); in prepare_ext_ctrls()
2721 if (ref == NULL) in prepare_ext_ctrls()
2723 ctrl = ref->ctrl; in prepare_ext_ctrls()
2730 ref = find_ref_lock(hdl, ctrl->cluster[0]->id); in prepare_ext_ctrls()
2744 h->mref = ref; in prepare_ext_ctrls()