• Home
  • Raw
  • Download

Lines Matching full:profile

39 …"auto_switch=<Switch between hsp and a2dp profile? (0 - never, 1 - media.role=phone, 2 - heuristic…
40 "a2dp_source=<Handle a2dp_source card profile (sink role)?> "
41 … "ag=<Handle headset_audio_gateway or handsfree_audio_gateway card profile (headset role)?> ");
92 pa_log_debug("Profile %s cannot be selected for loopback", s); in source_put_hook_callback()
131 pa_log_debug("Profile %s cannot be selected for loopback", s); in sink_put_hook_callback()
146 pa_card_profile *profile; in card_set_profile() local
149 /* Find available profile and activate it */ in card_set_profile()
150 PA_HASHMAP_FOREACH(profile, card->profiles, state) { in card_set_profile()
151 if (profile->available == PA_AVAILABLE_NO) in card_set_profile()
154 /* Check for correct profile based on revert_to_a2dp */ in card_set_profile()
156 if (!pa_streq(profile->name, "a2dp_sink")) in card_set_profile()
159 …if (!pa_streq(profile->name, "headset_head_unit") && !pa_streq(profile->name, "handsfree_head_unit… in card_set_profile()
163 pa_log_debug("Setting card '%s' to profile '%s'", card->name, profile->name); in card_set_profile()
165 if (pa_card_set_profile(card, profile, false) != 0) { in card_set_profile()
166 pa_log_warn("Could not set profile '%s'", profile->name); in card_set_profile()
178 /* Switch profile for one card */
193 /* Skip card if does not have active headset profile */ in switch_profile()
197 /* Skip card if already has active a2dp profile */ in switch_profile()
201 /* Skip card if does not have active a2dp profile */ in switch_profile()
205 /* Skip card if already has active headset profile */ in switch_profile()
255 /* Switch profile for all cards */
264 /* When a source output is created, switch profile a2dp to profile hsp */
276 /* When all source outputs are unlinked, switch profile hsp back back to profile a2dp */
307 /* Ignore card if has already set other initial profile than a2dp */ in card_init_profile_hook_callback()
312 /* Set initial profile to hsp */ in card_init_profile_hook_callback()
329 pa_card_profile *profile; in find_best_profile() local
332 PA_HASHMAP_FOREACH(profile, card->profiles, state) { in find_best_profile()
333 if (profile->available == PA_AVAILABLE_NO) in find_best_profile()
337 (profile->available == PA_AVAILABLE_YES && result->available == PA_AVAILABLE_UNKNOWN) || in find_best_profile()
338 (profile->available == result->available && profile->priority > result->priority)) in find_best_profile()
339 result = profile; in find_best_profile()
345 static pa_hook_result_t profile_available_hook_callback(pa_core *c, pa_card_profile *profile, void … in profile_available_hook_callback() argument
352 pa_assert(profile); in profile_available_hook_callback()
353 pa_assert_se((card = profile->card)); in profile_available_hook_callback()
361 if (pa_streq(profile->name, "a2dp_sink") || in profile_available_hook_callback()
362 pa_streq(profile->name, "headset_head_unit") || in profile_available_hook_callback()
363 pa_streq(profile->name, "handsfree_head_unit")) in profile_available_hook_callback()
366 is_active_profile = card->active_profile == profile; in profile_available_hook_callback()
368 if (profile->available == PA_AVAILABLE_YES) { in profile_available_hook_callback()
372 …tive_profile->available == PA_AVAILABLE_YES && card->active_profile->priority >= profile->priority) in profile_available_hook_callback()
375 selected_profile = profile; in profile_available_hook_callback()
386 pa_log_debug("Setting card '%s' to profile '%s'", card->name, selected_profile->name); in profile_available_hook_callback()
389 pa_log_warn("Could not set profile '%s'", selected_profile->name); in profile_available_hook_callback()
399 pa_card_profile *profile; in handle_all_profiles() local
402 PA_HASHMAP_FOREACH(profile, card->profiles, state2) in handle_all_profiles()
403 profile_available_hook_callback(core, profile, NULL); in handle_all_profiles()