On Wed, 23 Sep 2015 18:34:34 +0200, Raymond Yau wrote:
add sense_nid to __snd_hda_jack_add_kctl for pin sense
update slave pin sense when master pin sense change
enable unsolicited event when widcap support UNSOL
Again, please describe at first the reason you need this change. Then start explaining about the implementation details. For example, what's the difference from the existing gated_jack.
I don't understand how gated jack work, but those headset mic in alc668 dell-headset-multi does not use its own pin sense and won't need to enable unsol event of the headset mic node.
As pulseaudio don't expect jack kctl can be repesent the state of headphone and mic
This force the driver to create a headset mic kctl which is just a copy of the headphone jack kctl
See what you wrote now in the above? It's a nice introduction of the things you're trying to solve. This kind of information is exactly what I asked for. Please rephrase and put it in the changelog at the next time.
About gated_jack: this was introduced for Chromebook for a headset. This should work similarly like your case. The behavior of gated / gating jacks are:
- When a jack A has gating_jack = B: the presence of jack A depends on gating_jack B. Namely, if gating_jack B is unplugged, jack A is treated as unplugged.
- When a jack B has gated_jack = A: jack B doesn't give an unsol event by itself, but it's triggered together with gated_jack A when jack A is plugged/unplugged. The plug status of jack B can be read from B itself.
For Chromebook, A (gated) is mic pin and B (gating) is HP pin. That is, a headset mic is detected only when the HP pin is detected.
Takashi