About Kernel Documentation Linux Kernel Contact Linux Resources Linux Blog

Documentation / sound / alsa / HD-Audio-DP-MST-audio.txt


Based on kernel version 4.9. Page generated on 2016-12-21 14:37 EST.

1	To support DP MST audio, HD Audio hdmi codec driver introduces virtual pin
2	and dynamic pcm assignment.
3	
4	Virtual pin is an extension of per_pin. The most difference of DP MST
5	from legacy is that DP MST introduces device entry. Each pin can contain
6	several device entries. Each device entry behaves as a pin.
7	
8	As each pin may contain several device entries and each codec may contain
9	several pins, if we use one pcm per per_pin, there will be many PCMs.
10	The new solution is to create a few PCMs and to dynamically bind pcm to
11	per_pin. Driver uses spec->dyn_pcm_assign flag to indicate whether to use
12	the new solution.
13	
14	PCM
15	===
16	To be added
17	
18	
19	Jack
20	====
21	
22	Presume:
23	 - MST must be dyn_pcm_assign, and it is acomp (for Intel scenario);
24	 - NON-MST may or may not be dyn_pcm_assign, it can be acomp or !acomp;
25	
26	So there are the following scenarios:
27	 a. MST (&& dyn_pcm_assign && acomp)
28	 b. NON-MST && dyn_pcm_assign && acomp
29	 c. NON-MST && !dyn_pcm_assign && !acomp
30	
31	Below discussion will ignore MST and NON-MST difference as it doesn't
32	impact on jack handling too much.
33	
34	Driver uses struct hdmi_pcm pcm[] array in hdmi_spec and snd_jack is
35	a member of hdmi_pcm. Each pin has one struct hdmi_pcm * pcm pointer.
36	
37	For !dyn_pcm_assign, per_pin->pcm will assigned to spec->pcm[n] statically.
38	
39	For dyn_pcm_assign, per_pin->pcm will assigned to spec->pcm[n]
40	when monitor is hotplugged.
41	
42	
43	Build Jack
44	----------
45	
46	- dyn_pcm_assign
47	Will not use hda_jack but use snd_jack in spec->pcm_rec[pcm_idx].jack directly.
48	
49	- !dyn_pcm_assign
50	Use hda_jack and assign spec->pcm_rec[pcm_idx].jack = jack->jack statically.
51	
52	
53	Unsolicited Event Enabling
54	--------------------------
55	Enable unsolicited event if !acomp.
56	
57	
58	Monitor Hotplug Event Handling
59	------------------------------
60	- acomp
61	pin_eld_notify() -> check_presence_and_report() -> hdmi_present_sense() ->
62	sync_eld_via_acomp().
63	Use directly snd_jack_report() on spec->pcm_rec[pcm_idx].jack for
64	both dyn_pcm_assign and !dyn_pcm_assign
65	
66	- !acomp
67	Hdmi_unsol_event() -> hdmi_intrinsic_event() -> check_presence_and_report() ->
68	hdmi_present_sense() -> hdmi_prepsent_sense_via_verbs()
69	Use directly snd_jack_report() on spec->pcm_rec[pcm_idx].jack for dyn_pcm_assign.
70	Use hda_jack mechanism to handle jack events.
71	
72	
73	Others to be added later
74	========================
Hide Line Numbers


About Kernel Documentation Linux Kernel Contact Linux Resources Linux Blog