Use names instead of integer indexes for mux inputs 17/72117/2 accepted/tizen_3.0.m2_mobile accepted/tizen_3.0.m2_tv accepted/tizen_3.0.m2_wearable accepted/tizen_3.0_common accepted/tizen_3.0_ivi accepted/tizen_3.0_mobile accepted/tizen_3.0_tv accepted/tizen_3.0_wearable accepted/tizen_common accepted/tizen_ivi accepted/tizen_mobile accepted/tizen_tv accepted/tizen_wearable tizen_3.0 tizen_3.0.m2 tizen_3.0_tv accepted/tizen/3.0.m2/mobile/20170104.100303 accepted/tizen/3.0.m2/tv/20170104.100433 accepted/tizen/3.0.m2/wearable/20170104.101043 accepted/tizen/3.0/common/20161114.105103 accepted/tizen/3.0/ivi/20161011.053613 accepted/tizen/3.0/mobile/20161015.032429 accepted/tizen/3.0/tv/20161016.003627 accepted/tizen/3.0/wearable/20161015.080433 accepted/tizen/4.0/unified/20170816.010926 accepted/tizen/common/20160608.160340 accepted/tizen/ivi/20160608.084507 accepted/tizen/mobile/20160608.084523 accepted/tizen/tv/20160608.084448 accepted/tizen/unified/20170309.031217 accepted/tizen/wearable/20160608.084458 submit/tizen/20160608.060707 submit/tizen_3.0.m2/20170104.093748 submit/tizen_3.0_common/20161104.104000 submit/tizen_3.0_ivi/20161010.000000 submit/tizen_3.0_ivi/20161010.000010 submit/tizen_3.0_mobile/20161015.000000 submit/tizen_3.0_tv/20161015.000000 submit/tizen_3.0_wearable/20161015.000000 submit/tizen_4.0/20170811.094300 submit/tizen_unified/20170308.100403 tizen_4.0.m1_release
authorSylwester Nawrocki <s.nawrocki@samsung.com>
Mon, 30 May 2016 15:43:29 +0000 (17:43 +0200)
committerSylwester Nawrocki <s.nawrocki@samsung.com>
Mon, 30 May 2016 15:43:29 +0000 (17:43 +0200)
commit1cb80bd4abe5a4b518d8e82f88b0be438981f343
treec03021df9101cc27adec20fa3a5563cc8c046f50
parent05f803c66eb4067cf4c202545894c1a1dee03863
Use names instead of integer indexes for mux inputs

During codec drivers development in mainline there were some
updates which changed meaning of ASoC mux control indexes
of arizona class codecs, e.g. of the wm5110 codec which is
used on Draco board.

Since in the alsaucm files, found in /usr/share/alsa/ucm/wm511/
directory, hard coded indexes are used these files required
an update after moving to a more recent kernel version.

For example, in 'HPOUT2L Input 1' control the input indexes
and the corresponding names look like this:

root@localhost:~# amixer cget iface=MIXER,name='HPOUT2L Input 1'
numid=591,iface=MIXER,name='HPOUT2L Input 1'
  ; type=ENUMERATED,access=rw------,values=1,items=104
  ; Item #0 'None'
  ; Item #1 'Tone Generator 1'
  ; Item #2 'Tone Generator 2'
  ; Item #3 'Haptics'
  ; Item #4 'AEC'
  ; Item #5 'AEC2'
  ; Item #6 'Mic Mute Mixer'
  ; Item #7 'Noise Generator'
  ; Item #8 'IN1L'
  ; Item #9 'IN1R'
  ; Item #10 'IN2L'
  ; Item #11 'IN2R'
  ; Item #12 'IN3L'
  ; Item #13 'IN3R'
  ; Item #14 'IN4L'
  ; Item #15 'IN4R'
  ; Item #16 'AIF1RX1'
  ; Item #17 'AIF1RX2'
  ; Item #18 'AIF1RX3'
  ; Item #19 'AIF1RX4'
...

In commit 6ebbce0a6e15fd52 "ASoC: wm8998: Initial WM8998 codec
driver" "AEC2" entry was added, which caused shift of indexes
for all subsequent inputs starting from 'Mic Mute Mixer'. And
this made alsaucm configuration files for Draco board invalid.

In order to make common configuration files independent of the
kernel version use names instead of indices for the mux inputs.

Change-Id: Ib85e8e0619d99e227358433d1eb81bf5de8a3322
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
wm5110/hifi
wm5110/inactive
wm5110/voicecall