alsa: Allow sample spec override in mappings

This allows mappings to override some or all of the sample_spec used to
open the ALSA device. The intention, to start with, is to use this for
devices in UCM that need to be opened at a specific rate (like modem
devices). This can be extended to allow overrides in profile-sets as
well.
This commit is contained in:
Arun Raghavan 2013-08-07 18:26:26 +05:30
parent 6825df8cec
commit 6a6ee8fd22
4 changed files with 28 additions and 0 deletions

View file

@ -3368,6 +3368,7 @@ pa_alsa_mapping *pa_alsa_mapping_get(pa_alsa_profile_set *ps, const char *name)
m = pa_xnew0(pa_alsa_mapping, 1);
m->profile_set = ps;
m->name = pa_xstrdup(name);
pa_sample_spec_init(&m->sample_spec);
pa_channel_map_init(&m->channel_map);
m->proplist = pa_proplist_new();