Lines Matching refs:opts
146 struct f_uvc_opts *opts; \
154 opts = to_f_uvc_opts(opts_item); \
156 mutex_lock(&opts->lock); \
158 mutex_unlock(&opts->lock); \
169 struct f_uvc_opts *opts; \
178 opts = to_f_uvc_opts(opts_item); \
180 mutex_lock(&opts->lock); \
181 if (ch->linked || opts->refcnt) { \
197 mutex_unlock(&opts->lock); \
264 struct f_uvc_opts *opts; \
273 opts = to_f_uvc_opts(opts_item); \
274 pd = &opts->uvc_processing; \
276 mutex_lock(&opts->lock); \
278 mutex_unlock(&opts->lock); \
297 struct f_uvc_opts *opts; in uvcg_default_processing_bm_controls_show() local
307 opts = to_f_uvc_opts(opts_item); in uvcg_default_processing_bm_controls_show()
308 pd = &opts->uvc_processing; in uvcg_default_processing_bm_controls_show()
310 mutex_lock(&opts->lock); in uvcg_default_processing_bm_controls_show()
315 mutex_unlock(&opts->lock); in uvcg_default_processing_bm_controls_show()
367 struct f_uvc_opts *opts; \
377 opts = to_f_uvc_opts(opts_item); \
378 cd = &opts->uvc_camera_terminal; \
380 mutex_lock(&opts->lock); \
382 mutex_unlock(&opts->lock); \
408 struct f_uvc_opts *opts; in uvcg_default_camera_bm_controls_show() local
419 opts = to_f_uvc_opts(opts_item); in uvcg_default_camera_bm_controls_show()
420 cd = &opts->uvc_camera_terminal; in uvcg_default_camera_bm_controls_show()
422 mutex_lock(&opts->lock); in uvcg_default_camera_bm_controls_show()
427 mutex_unlock(&opts->lock); in uvcg_default_camera_bm_controls_show()
481 struct f_uvc_opts *opts; \
491 opts = to_f_uvc_opts(opts_item); \
492 cd = &opts->uvc_output_terminal; \
494 mutex_lock(&opts->lock); \
496 mutex_unlock(&opts->lock); \
593 struct f_uvc_opts *opts; in uvcg_control_class_allow_link() local
606 opts = to_f_uvc_opts(control->ci_parent); in uvcg_control_class_allow_link()
608 mutex_lock(&opts->lock); in uvcg_control_class_allow_link()
610 class_array = uvcg_get_ctl_class_arr(src, opts); in uvcg_control_class_allow_link()
613 if (opts->refcnt || class_array[0]) { in uvcg_control_class_allow_link()
624 mutex_unlock(&opts->lock); in uvcg_control_class_allow_link()
635 struct f_uvc_opts *opts; in uvcg_control_class_drop_link() local
647 opts = to_f_uvc_opts(control->ci_parent); in uvcg_control_class_drop_link()
649 mutex_lock(&opts->lock); in uvcg_control_class_drop_link()
651 class_array = uvcg_get_ctl_class_arr(src, opts); in uvcg_control_class_drop_link()
652 if (!class_array || opts->refcnt) in uvcg_control_class_drop_link()
660 mutex_unlock(&opts->lock); in uvcg_control_class_drop_link()
722 struct f_uvc_opts *opts; in uvcg_default_control_b_interface_number_show() local
728 opts = to_f_uvc_opts(opts_item); in uvcg_default_control_b_interface_number_show()
730 mutex_lock(&opts->lock); in uvcg_default_control_b_interface_number_show()
731 result += sprintf(page, "%u\n", opts->control_interface); in uvcg_default_control_b_interface_number_show()
732 mutex_unlock(&opts->lock); in uvcg_default_control_b_interface_number_show()
792 struct f_uvc_opts *opts; in uvcg_format_bma_controls_show() local
801 opts = to_f_uvc_opts(opts_item); in uvcg_format_bma_controls_show()
803 mutex_lock(&opts->lock); in uvcg_format_bma_controls_show()
810 mutex_unlock(&opts->lock); in uvcg_format_bma_controls_show()
819 struct f_uvc_opts *opts; in uvcg_format_bma_controls_store() local
827 opts = to_f_uvc_opts(opts_item); in uvcg_format_bma_controls_store()
829 mutex_lock(&opts->lock); in uvcg_format_bma_controls_store()
830 if (ch->linked || opts->refcnt) { in uvcg_format_bma_controls_store()
843 mutex_unlock(&opts->lock); in uvcg_format_bma_controls_store()
878 struct f_uvc_opts *opts; in uvcg_streaming_header_allow_link() local
888 opts = to_f_uvc_opts(opts_item); in uvcg_streaming_header_allow_link()
890 mutex_lock(&opts->lock); in uvcg_streaming_header_allow_link()
934 mutex_unlock(&opts->lock); in uvcg_streaming_header_allow_link()
944 struct f_uvc_opts *opts; in uvcg_streaming_header_drop_link() local
953 opts = to_f_uvc_opts(opts_item); in uvcg_streaming_header_drop_link()
955 mutex_lock(&opts->lock); in uvcg_streaming_header_drop_link()
972 mutex_unlock(&opts->lock); in uvcg_streaming_header_drop_link()
987 struct f_uvc_opts *opts; \
995 opts = to_f_uvc_opts(opts_item); \
997 mutex_lock(&opts->lock); \
999 mutex_unlock(&opts->lock); \
1096 struct f_uvc_opts *opts; \
1104 opts = to_f_uvc_opts(opts_item); \
1106 mutex_lock(&opts->lock); \
1108 mutex_unlock(&opts->lock); \
1118 struct f_uvc_opts *opts; \
1132 opts = to_f_uvc_opts(opts_item); \
1135 mutex_lock(&opts->lock); \
1136 if (fmt->linked || opts->refcnt) { \
1144 mutex_unlock(&opts->lock); \
1156 struct f_uvc_opts *opts; in uvcg_frame_b_frame_index_show() local
1173 opts = to_f_uvc_opts(opts_item); in uvcg_frame_b_frame_index_show()
1175 mutex_lock(&opts->lock); in uvcg_frame_b_frame_index_show()
1177 mutex_unlock(&opts->lock); in uvcg_frame_b_frame_index_show()
1200 struct f_uvc_opts *opts; in uvcg_frame_dw_frame_interval_show() local
1209 opts = to_f_uvc_opts(opts_item); in uvcg_frame_dw_frame_interval_show()
1211 mutex_lock(&opts->lock); in uvcg_frame_dw_frame_interval_show()
1216 mutex_unlock(&opts->lock); in uvcg_frame_dw_frame_interval_show()
1277 struct f_uvc_opts *opts; in uvcg_frame_dw_frame_interval_store() local
1287 opts = to_f_uvc_opts(opts_item); in uvcg_frame_dw_frame_interval_store()
1290 mutex_lock(&opts->lock); in uvcg_frame_dw_frame_interval_store()
1291 if (fmt->linked || opts->refcnt) { in uvcg_frame_dw_frame_interval_store()
1320 mutex_unlock(&opts->lock); in uvcg_frame_dw_frame_interval_store()
1351 struct f_uvc_opts *opts; in uvcg_frame_make() local
1368 opts = to_f_uvc_opts(opts_item); in uvcg_frame_make()
1370 mutex_lock(&opts->lock); in uvcg_frame_make()
1379 mutex_unlock(&opts->lock); in uvcg_frame_make()
1384 mutex_unlock(&opts->lock); in uvcg_frame_make()
1394 struct f_uvc_opts *opts; in uvcg_frame_drop() local
1398 opts = to_f_uvc_opts(opts_item); in uvcg_frame_drop()
1400 mutex_lock(&opts->lock); in uvcg_frame_drop()
1403 mutex_unlock(&opts->lock); in uvcg_frame_drop()
1449 struct f_uvc_opts *opts; in uvcg_uncompressed_guid_format_show() local
1456 opts = to_f_uvc_opts(opts_item); in uvcg_uncompressed_guid_format_show()
1458 mutex_lock(&opts->lock); in uvcg_uncompressed_guid_format_show()
1460 mutex_unlock(&opts->lock); in uvcg_uncompressed_guid_format_show()
1471 struct f_uvc_opts *opts; in uvcg_uncompressed_guid_format_store() local
1479 opts = to_f_uvc_opts(opts_item); in uvcg_uncompressed_guid_format_store()
1481 mutex_lock(&opts->lock); in uvcg_uncompressed_guid_format_store()
1482 if (ch->fmt.linked || opts->refcnt) { in uvcg_uncompressed_guid_format_store()
1492 mutex_unlock(&opts->lock); in uvcg_uncompressed_guid_format_store()
1504 struct f_uvc_opts *opts; \
1512 opts = to_f_uvc_opts(opts_item); \
1514 mutex_lock(&opts->lock); \
1516 mutex_unlock(&opts->lock); \
1529 struct f_uvc_opts *opts; \
1537 opts = to_f_uvc_opts(opts_item); \
1539 mutex_lock(&opts->lock); \
1541 mutex_unlock(&opts->lock); \
1552 struct f_uvc_opts *opts; \
1561 opts = to_f_uvc_opts(opts_item); \
1563 mutex_lock(&opts->lock); \
1564 if (u->fmt.linked || opts->refcnt) { \
1576 mutex_unlock(&opts->lock); \
1698 struct f_uvc_opts *opts; \
1706 opts = to_f_uvc_opts(opts_item); \
1708 mutex_lock(&opts->lock); \
1710 mutex_unlock(&opts->lock); \
1722 struct f_uvc_opts *opts; \
1730 opts = to_f_uvc_opts(opts_item); \
1732 mutex_lock(&opts->lock); \
1734 mutex_unlock(&opts->lock); \
1745 struct f_uvc_opts *opts; \
1754 opts = to_f_uvc_opts(opts_item); \
1756 mutex_lock(&opts->lock); \
1757 if (u->fmt.linked || opts->refcnt) { \
1769 mutex_unlock(&opts->lock); \
1868 struct f_uvc_opts *opts; \
1877 opts = to_f_uvc_opts(opts_item); \
1878 cd = &opts->uvc_color_matching; \
1880 mutex_lock(&opts->lock); \
1882 mutex_unlock(&opts->lock); \
2159 struct f_uvc_opts *opts; in uvcg_streaming_class_allow_link() local
2174 opts = to_f_uvc_opts(streaming->ci_parent); in uvcg_streaming_class_allow_link()
2176 mutex_lock(&opts->lock); in uvcg_streaming_class_allow_link()
2178 class_array = __uvcg_get_stream_class_arr(src, opts); in uvcg_streaming_class_allow_link()
2179 if (!class_array || *class_array || opts->refcnt) { in uvcg_streaming_class_allow_link()
2216 *cl_arr = (struct uvc_descriptor_header *)&opts->uvc_color_matching; in uvcg_streaming_class_allow_link()
2222 mutex_unlock(&opts->lock); in uvcg_streaming_class_allow_link()
2233 struct f_uvc_opts *opts; in uvcg_streaming_class_drop_link() local
2245 opts = to_f_uvc_opts(streaming->ci_parent); in uvcg_streaming_class_drop_link()
2247 mutex_lock(&opts->lock); in uvcg_streaming_class_drop_link()
2249 class_array = __uvcg_get_stream_class_arr(src, opts); in uvcg_streaming_class_drop_link()
2253 if (opts->refcnt) in uvcg_streaming_class_drop_link()
2263 mutex_unlock(&opts->lock); in uvcg_streaming_class_drop_link()
2325 struct f_uvc_opts *opts; in uvcg_default_streaming_b_interface_number_show() local
2331 opts = to_f_uvc_opts(opts_item); in uvcg_default_streaming_b_interface_number_show()
2333 mutex_lock(&opts->lock); in uvcg_default_streaming_b_interface_number_show()
2334 result += sprintf(page, "%u\n", opts->streaming_interface); in uvcg_default_streaming_b_interface_number_show()
2335 mutex_unlock(&opts->lock); in uvcg_default_streaming_b_interface_number_show()
2372 struct f_uvc_opts *opts = to_f_uvc_opts(item); in uvc_func_item_release() local
2375 usb_put_function_instance(&opts->func_inst); in uvc_func_item_release()
2386 struct f_uvc_opts *opts = to_f_uvc_opts(item); \
2389 mutex_lock(&opts->lock); \
2390 result = sprintf(page, "%u\n", opts->cname); \
2391 mutex_unlock(&opts->lock); \
2400 struct f_uvc_opts *opts = to_f_uvc_opts(item); \
2404 mutex_lock(&opts->lock); \
2405 if (opts->refcnt) { \
2418 opts->cname = num; \
2421 mutex_unlock(&opts->lock); \
2454 int uvcg_attach_configfs(struct f_uvc_opts *opts) in uvcg_attach_configfs() argument
2458 config_group_init_type_name(&opts->func_inst.group, uvc_func_type.name, in uvcg_attach_configfs()
2461 ret = uvcg_config_create_children(&opts->func_inst.group, in uvcg_attach_configfs()
2464 config_group_put(&opts->func_inst.group); in uvcg_attach_configfs()