On 09/18/2013 07:41 PM, Felipe Tonello wrote: > Hi David, > > On Wed, Sep 18, 2013 at 7:01 AM, David Henningsson > <david.henningsson at canonical.com> wrote: >> In case of UCM, it usually targets a very specific hardware. The >> person writing the UCM file for that hardware knows what (s)he is >> doing, hopefully. >> >> Does it harm to probe all verbs at startup? Yes, because it can >> cause longer startup time, clicks, or other side effects. >> >> (This is a difference to the normal probing mechanism, where we try >> to make one profile set file fit many different sound cards, hence >> we need probing there. But not here.) >> >> Signed-off-by: David Henningsson <david.henningsson at canonical.com> >> --- >> src/modules/alsa/alsa-ucm.c | 4 +++- >> 1 file changed, 3 insertions(+), 1 deletion(-) >> >> diff --git a/src/modules/alsa/alsa-ucm.c b/src/modules/alsa/alsa-ucm.c >> index 81d0aeb..ab23259 100644 >> --- a/src/modules/alsa/alsa-ucm.c >> +++ b/src/modules/alsa/alsa-ucm.c >> @@ -1367,6 +1367,7 @@ static int ucm_create_profile( >> return 0; >> } >> >> +#if 0 >> static snd_pcm_t* mapping_open_pcm(pa_alsa_ucm_config *ucm, pa_alsa_mapping *m, int mode) { >> snd_pcm_t* pcm; >> pa_sample_spec try_ss = ucm->core->default_sample_spec; >> @@ -1514,6 +1515,7 @@ static void ucm_probe_profile_set(pa_alsa_ucm_config *ucm, pa_alsa_profile_set * >> >> pa_alsa_profile_set_drop_unsupported(ps); >> } >> +#endif >> >> pa_alsa_profile_set* pa_alsa_ucm_add_profile_set(pa_alsa_ucm_config *ucm, pa_channel_map *default_channel_map) { >> pa_alsa_ucm_verb *verb; >> @@ -1539,7 +1541,7 @@ pa_alsa_profile_set* pa_alsa_ucm_add_profile_set(pa_alsa_ucm_config *ucm, pa_cha >> ucm_create_profile(ucm, ps, verb, verb_name, verb_desc); >> } >> >> - ucm_probe_profile_set(ucm, ps); >> +/* ucm_probe_profile_set(ucm, ps); */ >> ps->probed = true; >> >> return ps; > > Why not just remove the code? This is just the first draft. We might end up with some way of configuring whether to probe or not (suggestions welcome). -- David Henningsson, Canonical Ltd. https://launchpad.net/~diwic