| /kernel/linux/linux-5.10/sound/core/ |
| D | jack.c | 3 * Jack abstraction layer 11 #include <sound/jack.h> 17 struct list_head list; /* list of controls belong to the same jack */ 35 struct snd_jack *jack = device->device_data; in snd_jack_dev_disconnect() local 37 mutex_lock(&jack->input_dev_lock); in snd_jack_dev_disconnect() 38 if (!jack->input_dev) { in snd_jack_dev_disconnect() 39 mutex_unlock(&jack->input_dev_lock); in snd_jack_dev_disconnect() 45 if (jack->registered) in snd_jack_dev_disconnect() 46 input_unregister_device(jack->input_dev); in snd_jack_dev_disconnect() 48 input_free_device(jack->input_dev); in snd_jack_dev_disconnect() [all …]
|
| /kernel/linux/linux-5.10/sound/pci/hda/ |
| D | hda_jack.c | 3 * Jack-detection handling for HD-audio 13 #include <sound/jack.h> 20 * is_jack_detectable - Check whether the given pin is jack-detectable 24 * Check whether the given pin is capable to report the jack detection. 25 * The jack detection might not work by various reasons, e.g. the jack 65 * snd_hda_jack_tbl_get_mst - query the jack-table entry for the given NID 73 struct hda_jack_tbl *jack = codec->jacktbl.list; in snd_hda_jack_tbl_get_mst() local 76 if (!nid || !jack) in snd_hda_jack_tbl_get_mst() 78 for (i = 0; i < codec->jacktbl.used; i++, jack++) in snd_hda_jack_tbl_get_mst() 79 if (jack->nid == nid && jack->dev_id == dev_id) in snd_hda_jack_tbl_get_mst() [all …]
|
| D | hda_jack.h | 3 * Jack-detection handling for HD-audio 12 #include <sound/jack.h> 26 struct hda_jack_tbl *jack; /* associated jack entry */ member 35 /* jack-detection stuff */ 37 unsigned int jack_detect:1; /* capable of jack-detection? */ 41 hda_nid_t gating_jack; /* valid when gating jack plugged */ 42 hda_nid_t gated_jack; /* gated is dependent on this jack */ 45 struct snd_jack *jack; member 57 * snd_hda_jack_tbl_get - query the jack-table entry for the given NID 83 * snd_hda_jack_detect_enable - enable the jack-detection [all …]
|
| /kernel/linux/linux-6.6/sound/pci/hda/ |
| D | hda_jack.c | 3 * Jack-detection handling for HD-audio 13 #include <sound/jack.h> 20 * is_jack_detectable - Check whether the given pin is jack-detectable 24 * Check whether the given pin is capable to report the jack detection. 25 * The jack detection might not work by various reasons, e.g. the jack 65 * snd_hda_jack_tbl_get_mst - query the jack-table entry for the given NID 73 struct hda_jack_tbl *jack = codec->jacktbl.list; in snd_hda_jack_tbl_get_mst() local 76 if (!nid || !jack) in snd_hda_jack_tbl_get_mst() 78 for (i = 0; i < codec->jacktbl.used; i++, jack++) in snd_hda_jack_tbl_get_mst() 79 if (jack->nid == nid && jack->dev_id == dev_id) in snd_hda_jack_tbl_get_mst() [all …]
|
| D | hda_jack.h | 3 * Jack-detection handling for HD-audio 12 #include <sound/jack.h> 26 struct hda_jack_tbl *jack; /* associated jack entry */ member 35 /* jack-detection stuff */ 37 unsigned int jack_detect:1; /* capable of jack-detection? */ 41 hda_nid_t gating_jack; /* valid when gating jack plugged */ 42 hda_nid_t gated_jack; /* gated is dependent on this jack */ 43 hda_nid_t key_report_jack; /* key reports to this jack */ 46 struct snd_jack *jack; member 58 * snd_hda_jack_tbl_get - query the jack-table entry for the given NID [all …]
|
| /kernel/linux/linux-6.6/sound/core/ |
| D | jack.c | 3 * Jack abstraction layer 14 #include <sound/jack.h> 20 struct list_head list; /* list of controls belong to the same jack */ 22 struct snd_jack *jack; /* pointer to struct snd_jack */ member 40 static void snd_jack_remove_debugfs(struct snd_jack *jack); 44 struct snd_jack *jack = device->device_data; in snd_jack_dev_disconnect() local 46 snd_jack_remove_debugfs(jack); in snd_jack_dev_disconnect() 49 guard(mutex)(&jack->input_dev_lock); in snd_jack_dev_disconnect() 50 if (!jack->input_dev) in snd_jack_dev_disconnect() 55 if (jack->registered) in snd_jack_dev_disconnect() [all …]
|
| /kernel/linux/linux-6.6/sound/soc/ |
| D | soc-jack.c | 3 // soc-jack.c -- ALSA SoC jack handling 9 #include <sound/jack.h> 21 * snd_soc_jack_report - Report the current status for a jack 23 * @jack: the jack 34 void snd_soc_jack_report(struct snd_soc_jack *jack, int status, int mask) in snd_soc_jack_report() argument 40 if (!jack || !jack->jack) in snd_soc_jack_report() 42 trace_snd_soc_jack_report(jack, mask, status); in snd_soc_jack_report() 44 dapm = &jack->card->dapm; in snd_soc_jack_report() 46 mutex_lock(&jack->mutex); in snd_soc_jack_report() 48 jack->status &= ~mask; in snd_soc_jack_report() [all …]
|
| D | soc-card.c | 12 #include <sound/jack.h> 66 struct snd_soc_jack *jack, bool initial_kctl) in jack_new() argument 68 mutex_init(&jack->mutex); in jack_new() 69 jack->card = card; in jack_new() 70 INIT_LIST_HEAD(&jack->pins); in jack_new() 71 INIT_LIST_HEAD(&jack->jack_zones); in jack_new() 72 BLOCKING_INIT_NOTIFIER_HEAD(&jack->notifier); in jack_new() 74 return snd_jack_new(card->snd_card, id, type, &jack->jack, initial_kctl, false); in jack_new() 78 * snd_soc_card_jack_new - Create a new jack without pins 80 * @id: an identifying string for this jack [all …]
|
| /kernel/linux/linux-5.10/sound/soc/ |
| D | soc-jack.c | 3 // soc-jack.c -- ALSA SoC jack handling 9 #include <sound/jack.h> 22 struct snd_soc_jack *jack; member 27 * snd_soc_jack_report - Report the current status for a jack 29 * @jack: the jack 40 void snd_soc_jack_report(struct snd_soc_jack *jack, int status, int mask) in snd_soc_jack_report() argument 47 if (!jack) in snd_soc_jack_report() 49 trace_snd_soc_jack_report(jack, mask, status); in snd_soc_jack_report() 51 dapm = &jack->card->dapm; in snd_soc_jack_report() 53 mutex_lock(&jack->mutex); in snd_soc_jack_report() [all …]
|
| /kernel/linux/linux-5.10/Documentation/sound/soc/ |
| D | jack.rst | 2 ASoC jack detection 6 the kernel side of which can be seen in include/sound/jack.h. ASoC 9 - It allows more than one jack detection method to work together on one 10 user visible jack. In embedded systems it is common for multiple 11 to be present on a single jack but handled by separate bits of 15 automatically based on the detected jack status (eg, turning off the 19 together: the jack itself represented by a struct snd_soc_jack, sets of 21 code providing jack reporting mechanisms. 23 For example, a system may have a stereo headset jack with two reporting 27 headphone when the headphone jack status changes. [all …]
|
| /kernel/linux/linux-6.6/Documentation/sound/soc/ |
| D | jack.rst | 2 ASoC jack detection 6 the kernel side of which can be seen in include/sound/jack.h. ASoC 9 - It allows more than one jack detection method to work together on one 10 user visible jack. In embedded systems it is common for multiple 11 to be present on a single jack but handled by separate bits of 15 automatically based on the detected jack status (eg, turning off the 19 together: the jack itself represented by a struct snd_soc_jack, sets of 21 code providing jack reporting mechanisms. 23 For example, a system may have a stereo headset jack with two reporting 27 headphone when the headphone jack status changes. [all …]
|
| /kernel/linux/linux-6.6/Documentation/sound/designs/ |
| D | jack-controls.rst | 2 ALSA Jack Controls 5 Why we need Jack kcontrols 13 The old ALSA jack code only created input devices for each registered 14 jack. These jack input devices are not readable by userspace devices 17 The new jack code creates embedded jack kcontrols for each jack that 21 intelligently based on jack insertion or removal events. 23 Jack Kcontrol Internals 26 Each jack will have a kcontrol list, so that we can create a kcontrol 27 and attach it to the jack, at jack creation stage. We can also add a 28 kcontrol to an existing jack, at anytime when required. [all …]
|
| D | jack-injection.rst | 2 ALSA Jack Software Injection 5 Simple Introduction On Jack Injection 8 Here jack injection means users could inject plugin or plugout events 14 jack or to some audio jacks, we don't need to physically access the 15 machine and plug/unplug physical devices to the audio jack. 17 In this design, an audio jack doesn't equal to a physical audio jack. 18 Sometimes a physical audio jack contains multi functions, and the 20 ``snd_jack`` represents a physical audio jack and the ``jack_kctl`` 21 represents a function, for example a physical jack has two functions: 23 for this jack. The jack injection is implemented based on the [all …]
|
| /kernel/linux/linux-5.10/Documentation/sound/designs/ |
| D | jack-controls.rst | 2 ALSA Jack Controls 5 Why we need Jack kcontrols 13 The old ALSA jack code only created input devices for each registered 14 jack. These jack input devices are not readable by userspace devices 17 The new jack code creates embedded jack kcontrols for each jack that 21 intelligently based on jack insertion or removal events. 23 Jack Kcontrol Internals 26 Each jack will have a kcontrol list, so that we can create a kcontrol 27 and attach it to the jack, at jack creation stage. We can also add a 28 kcontrol to an existing jack, at anytime when required. [all …]
|
| /kernel/linux/linux-6.6/include/sound/ |
| D | soc-jack.h | 3 * soc-jack.h 12 * struct snd_soc_jack_pin - Describes a pin to update based on jack detection 15 * @mask: bits to check for in reported jack status 27 * struct snd_soc_jack_zone - Describes voltage zones of jack detection 31 * @jack_type: type of jack that is expected for this voltage 32 * @debounce_time: debounce_time for jack, codec driver should wait for this 45 * struct snd_soc_jack_gpio - Describes a gpio pin for jack detection 53 * @report: value to report when jack detected 72 struct snd_soc_jack *jack; member 84 struct snd_jack *jack; member [all …]
|
| /kernel/linux/linux-5.10/sound/soc/pxa/ |
| D | spitz.c | 51 /* set up jack connection */ in spitz_ext_control() 54 /* enable and unmute hp jack, disable mic bias */ in spitz_ext_control() 55 snd_soc_dapm_disable_pin_unlocked(dapm, "Headset Jack"); in spitz_ext_control() 56 snd_soc_dapm_disable_pin_unlocked(dapm, "Mic Jack"); in spitz_ext_control() 57 snd_soc_dapm_disable_pin_unlocked(dapm, "Line Jack"); in spitz_ext_control() 58 snd_soc_dapm_enable_pin_unlocked(dapm, "Headphone Jack"); in spitz_ext_control() 63 /* enable mic jack and bias, mute hp */ in spitz_ext_control() 64 snd_soc_dapm_disable_pin_unlocked(dapm, "Headphone Jack"); in spitz_ext_control() 65 snd_soc_dapm_disable_pin_unlocked(dapm, "Headset Jack"); in spitz_ext_control() 66 snd_soc_dapm_disable_pin_unlocked(dapm, "Line Jack"); in spitz_ext_control() [all …]
|
| D | corgi.c | 48 /* set up jack connection */ in corgi_ext_control() 54 snd_soc_dapm_disable_pin_unlocked(dapm, "Mic Jack"); in corgi_ext_control() 55 snd_soc_dapm_disable_pin_unlocked(dapm, "Line Jack"); in corgi_ext_control() 56 snd_soc_dapm_enable_pin_unlocked(dapm, "Headphone Jack"); in corgi_ext_control() 57 snd_soc_dapm_disable_pin_unlocked(dapm, "Headset Jack"); in corgi_ext_control() 63 snd_soc_dapm_enable_pin_unlocked(dapm, "Mic Jack"); in corgi_ext_control() 64 snd_soc_dapm_disable_pin_unlocked(dapm, "Line Jack"); in corgi_ext_control() 65 snd_soc_dapm_disable_pin_unlocked(dapm, "Headphone Jack"); in corgi_ext_control() 66 snd_soc_dapm_disable_pin_unlocked(dapm, "Headset Jack"); in corgi_ext_control() 71 snd_soc_dapm_disable_pin_unlocked(dapm, "Mic Jack"); in corgi_ext_control() [all …]
|
| /kernel/linux/linux-6.6/sound/soc/pxa/ |
| D | spitz.c | 50 /* set up jack connection */ in spitz_ext_control() 53 /* enable and unmute hp jack, disable mic bias */ in spitz_ext_control() 54 snd_soc_dapm_disable_pin_unlocked(dapm, "Headset Jack"); in spitz_ext_control() 55 snd_soc_dapm_disable_pin_unlocked(dapm, "Mic Jack"); in spitz_ext_control() 56 snd_soc_dapm_disable_pin_unlocked(dapm, "Line Jack"); in spitz_ext_control() 57 snd_soc_dapm_enable_pin_unlocked(dapm, "Headphone Jack"); in spitz_ext_control() 62 /* enable mic jack and bias, mute hp */ in spitz_ext_control() 63 snd_soc_dapm_disable_pin_unlocked(dapm, "Headphone Jack"); in spitz_ext_control() 64 snd_soc_dapm_disable_pin_unlocked(dapm, "Headset Jack"); in spitz_ext_control() 65 snd_soc_dapm_disable_pin_unlocked(dapm, "Line Jack"); in spitz_ext_control() [all …]
|
| /kernel/linux/linux-5.10/Documentation/devicetree/bindings/sound/ |
| D | fsl-asoc-card.txt | 62 * Line Out Jack 63 * Line In Jack 64 * Headphone Jack 65 * Mic Jack 67 * AMIC (stands for Analog Microphone Jack) 68 * DMIC (stands for Digital Microphone Jack) 70 Note: The "Mic Jack" and "AMIC" are redundant while 96 "Line Out Jack", "AOUT1L", 97 "Line Out Jack", "AOUT1R", 98 "Line Out Jack", "AOUT2L", [all …]
|
| /kernel/linux/linux-6.6/Documentation/devicetree/bindings/sound/ |
| D | fsl-asoc-card.txt | 70 * Line Out Jack 71 * Line In Jack 72 * Headphone Jack 73 * Mic Jack 75 * AMIC (stands for Analog Microphone Jack) 76 * DMIC (stands for Digital Microphone Jack) 78 Note: The "Mic Jack" and "AMIC" are redundant while 105 "Line Out Jack", "AOUT1L", 106 "Line Out Jack", "AOUT1R", 107 "Line Out Jack", "AOUT2L", [all …]
|
| /kernel/linux/linux-6.6/sound/soc/intel/avs/boards/ |
| D | da7219.c | 11 #include <sound/jack.h> 23 SOC_DAPM_PIN_SWITCH("Headphone Jack"), 57 SND_SOC_DAPM_HP("Headphone Jack", NULL), 65 /* HP jack connectors - unknown if we have jack detection */ 66 {"Headphone Jack", NULL, "HPL"}, 67 {"Headphone Jack", NULL, "HPR"}, 71 { "Headphone Jack", NULL, "Platform Clock" }, 78 .pin = "Headphone Jack", 97 struct snd_soc_jack *jack; in avs_da7219_codec_init() local 102 jack = snd_soc_card_get_drvdata(card); in avs_da7219_codec_init() [all …]
|
| D | rt5682.c | 16 #include <sound/jack.h> 64 SOC_DAPM_PIN_SWITCH("Headphone Jack"), 69 SND_SOC_DAPM_HP("Headphone Jack", NULL), 74 /* HP jack connectors - unknown if we have jack detect */ 75 { "Headphone Jack", NULL, "HPOL" }, 76 { "Headphone Jack", NULL, "HPOR" }, 84 .pin = "Headphone Jack", 98 struct snd_soc_jack *jack; in avs_rt5682_codec_init() local 101 jack = snd_soc_card_get_drvdata(card); in avs_rt5682_codec_init() 116 ret = snd_soc_card_jack_new_pins(card, "Headset Jack", SND_JACK_HEADSET | SND_JACK_BTN_0 | in avs_rt5682_codec_init() [all …]
|
| /kernel/linux/linux-6.6/sound/soc/intel/boards/ |
| D | sof_sdw_cs42l42.c | 17 #include <sound/jack.h> 26 /* HP jack connectors - unknown if we have jack detection */ 55 struct snd_soc_jack *jack; in cs42l42_rtd_init() local 86 ret = snd_soc_card_jack_new_pins(rtd->card, "Headset Jack", in cs42l42_rtd_init() 94 dev_err(rtd->card->dev, "Headset Jack creation failed: %d\n", in cs42l42_rtd_init() 99 jack = &ctx->sdw_headset; in cs42l42_rtd_init() 101 snd_jack_set_key(jack->jack, SND_JACK_BTN_0, KEY_PLAYPAUSE); in cs42l42_rtd_init() 102 snd_jack_set_key(jack->jack, SND_JACK_BTN_1, KEY_VOLUMEUP); in cs42l42_rtd_init() 103 snd_jack_set_key(jack->jack, SND_JACK_BTN_2, KEY_VOLUMEDOWN); in cs42l42_rtd_init() 104 snd_jack_set_key(jack->jack, SND_JACK_BTN_3, KEY_VOICECOMMAND); in cs42l42_rtd_init() [all …]
|
| /kernel/linux/linux-6.6/sound/virtio/ |
| D | virtio_jack.c | 7 #include <sound/jack.h> 23 * struct virtio_jack - VirtIO jack. 24 * @jack: Kernel jack control. 26 * @features: Jack virtio feature bit map (1 << VIRTIO_SND_JACK_F_XXX). 29 * @connected: Current jack connection status. 30 * @type: Kernel jack type (SND_JACK_XXX). 33 struct snd_jack *jack; member 43 * virtsnd_jack_get_label() - Get the name string for the jack. 44 * @vjack: VirtIO jack. 46 * Returns the jack name based on the default pin configuration value (see HDA [all …]
|
| /kernel/linux/linux-5.10/sound/soc/fsl/ |
| D | wm1133-ev1.c | 14 #include <sound/jack.h> 145 SND_SOC_DAPM_MIC("Mic1 Jack", NULL), 146 SND_SOC_DAPM_MIC("Mic2 Jack", NULL), 147 SND_SOC_DAPM_LINE("Line In Jack", NULL), 148 SND_SOC_DAPM_LINE("Line Out Jack", NULL), 149 SND_SOC_DAPM_HP("Headphone Jack", NULL), 161 /* Mic 1 Jack --> IN1LN and IN1LP (with automatic bias) */ 163 { "IN1LP", NULL, "Mic1 Jack" }, 164 { "Mic Bias", NULL, "Mic1 Jack" }, 166 /* Mic 2 Jack --> IN1RN and IN1RP (with automatic bias) */ [all …]
|