[alsa-devel] AK4671 pin sharing
mlopez at sta.samsung.com
Wed Nov 25 18:44:47 CET 2009
I'm interested in adding some functionalities to ak4671 codec driver
(currently hosted in for-2.6.33 branch). The driver has support for
single ended inputs/outputs only, but the actual hardware supports
full-differential mode as well. However, the chip doesn't have separate
pins for the differential input/outputs, but instead the same pins
used in single-ended mode can be reconfigured and reused.
For example: LIN1 and RIN1 inputs (single-ended) can become IN1+/-
(differential input), LIN2/RIN2 -> IN2+/-, etc. Similarly for outputs,
LOUT1 and ROUT1 (single-ended) can become Mono Receiver RCP/RCN
(BTL output), LOUT3/ROUT3 can become Mono Line Output LOP/LON
(full-differential). Changing the function of a pin also modifies the
- Mic Amp Left Mux allow to choose between LIN1, LIN2, LIN3 and LIN4,
when pins are configured as single-ended inputs. However, if they
are as differential inputs, then the options of Mic Amp Left Mux
becomes only IN1+/- and IN3+/-. Similarly for Mic Amp Right Mux:
IN2+/- and IN4+/-.
- For outputs, single-ended stereo outputs LOUT1/ROUT1, LOUT2/ROUT2
and LOUT3/ROUT3 have separate analog mixers for each channel. But
when the output pins work as RCP/RCN or LOP/LON, the output is mono
and then each output has a single analog mixer.
My concerns are:
- When inputs/outputs are single-ended, then they have its own widgets,
But when they are switched to full-differential mode, they cannot have
a separate widget anymore but a single widget instead:
Then, it makes me think that input/output widgets cannot be reused in
above case. I guess that having the three widgets at the same time is
not a safe choice either.
- Audio map changes depending on the mode of inputs or outputs, I don't
know how the SoC codec driver could handle that.
Any suggestion on what to do in above scenarios?
More information about the Alsa-devel