aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/hda
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2014-10-29 10:06:01 -0400
committerTakashi Iwai <tiwai@suse.de>2014-10-29 10:06:54 -0400
commita11e9b168646cfc5d3b8d605d430d7e4ff267d72 (patch)
treebbed7c9e517862dbd6821970f53f0c3e214751b7 /sound/pci/hda
parent00dad6cfd25b75cc9cc24b8abfc263177e581ae2 (diff)
ALSA: hda - Correct kerneldoc comments
Complete the missing parameters and fix anything wrong there. Just comment changes. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/hda')
-rw-r--r--sound/pci/hda/hda_auto_parser.c15
-rw-r--r--sound/pci/hda/hda_codec.c114
-rw-r--r--sound/pci/hda/hda_eld.c2
-rw-r--r--sound/pci/hda/hda_jack.c21
4 files changed, 146 insertions, 6 deletions
diff --git a/sound/pci/hda/hda_auto_parser.c b/sound/pci/hda/hda_auto_parser.c
index fcc5e478c9a1..7388958b01af 100644
--- a/sound/pci/hda/hda_auto_parser.c
+++ b/sound/pci/hda/hda_auto_parser.c
@@ -464,8 +464,12 @@ EXPORT_SYMBOL_GPL(snd_hda_get_input_pin_attr);
464 464
465/** 465/**
466 * hda_get_input_pin_label - Give a label for the given input pin 466 * hda_get_input_pin_label - Give a label for the given input pin
467 * @codec: the HDA codec
468 * @item: ping config item to refer
469 * @pin: the pin NID
470 * @check_location: flag to add the jack location prefix
467 * 471 *
468 * When check_location is true, the function checks the pin location 472 * When @check_location is true, the function checks the pin location
469 * for mic and line-in pins, and set an appropriate prefix like "Front", 473 * for mic and line-in pins, and set an appropriate prefix like "Front",
470 * "Rear", "Internal". 474 * "Rear", "Internal".
471 */ 475 */
@@ -550,6 +554,9 @@ static int check_mic_location_need(struct hda_codec *codec,
550 554
551/** 555/**
552 * hda_get_autocfg_input_label - Get a label for the given input 556 * hda_get_autocfg_input_label - Get a label for the given input
557 * @codec: the HDA codec
558 * @cfg: the parsed pin configuration
559 * @input: the input index number
553 * 560 *
554 * Get a label for the given input pin defined by the autocfg item. 561 * Get a label for the given input pin defined by the autocfg item.
555 * Unlike hda_get_input_pin_label(), this function checks all inputs 562 * Unlike hda_get_input_pin_label(), this function checks all inputs
@@ -677,6 +684,12 @@ static int fill_audio_out_name(struct hda_codec *codec, hda_nid_t nid,
677 684
678/** 685/**
679 * snd_hda_get_pin_label - Get a label for the given I/O pin 686 * snd_hda_get_pin_label - Get a label for the given I/O pin
687 * @codec: the HDA codec
688 * @nid: pin NID
689 * @cfg: the parsed pin configuration
690 * @label: the string buffer to store
691 * @maxlen: the max length of string buffer (including termination)
692 * @indexp: the pointer to return the index number (for multiple ctls)
680 * 693 *
681 * Get a label for the given pin. This function works for both input and 694 * Get a label for the given pin. This function works for both input and
682 * output pins. When @cfg is given as non-NULL, the function tries to get 695 * output pins. When @cfg is given as non-NULL, the function tries to get
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
index 0025bf4c2f44..e15254204c72 100644
--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -416,7 +416,6 @@ static int read_and_add_raw_conns(struct hda_codec *codec, hda_nid_t nid)
416 * snd_hda_get_conn_list - get connection list 416 * snd_hda_get_conn_list - get connection list
417 * @codec: the HDA codec 417 * @codec: the HDA codec
418 * @nid: NID to parse 418 * @nid: NID to parse
419 * @len: number of connection list entries
420 * @listp: the pointer to store NID list 419 * @listp: the pointer to store NID list
421 * 420 *
422 * Parses the connection list of the given widget and stores the pointer 421 * Parses the connection list of the given widget and stores the pointer
@@ -2004,6 +2003,7 @@ EXPORT_SYMBOL_GPL(query_amp_caps);
2004 * @codec: the HD-audio codec 2003 * @codec: the HD-audio codec
2005 * @nid: the NID to query 2004 * @nid: the NID to query
2006 * @dir: either #HDA_INPUT or #HDA_OUTPUT 2005 * @dir: either #HDA_INPUT or #HDA_OUTPUT
2006 * @bits: bit mask to check the result
2007 * 2007 *
2008 * Check whether the widget has the given amp capability for the direction. 2008 * Check whether the widget has the given amp capability for the direction.
2009 */ 2009 */
@@ -2023,7 +2023,7 @@ EXPORT_SYMBOL_GPL(snd_hda_check_amp_caps);
2023 * snd_hda_override_amp_caps - Override the AMP capabilities 2023 * snd_hda_override_amp_caps - Override the AMP capabilities
2024 * @codec: the CODEC to clean up 2024 * @codec: the CODEC to clean up
2025 * @nid: the NID to clean up 2025 * @nid: the NID to clean up
2026 * @direction: either #HDA_INPUT or #HDA_OUTPUT 2026 * @dir: either #HDA_INPUT or #HDA_OUTPUT
2027 * @caps: the capability bits to set 2027 * @caps: the capability bits to set
2028 * 2028 *
2029 * Override the cached AMP caps bits value by the given one. 2029 * Override the cached AMP caps bits value by the given one.
@@ -2320,6 +2320,8 @@ static u32 get_amp_max_value(struct hda_codec *codec, hda_nid_t nid, int dir,
2320 2320
2321/** 2321/**
2322 * snd_hda_mixer_amp_volume_info - Info callback for a standard AMP mixer 2322 * snd_hda_mixer_amp_volume_info - Info callback for a standard AMP mixer
2323 * @kcontrol: referred ctl element
2324 * @uinfo: pointer to get/store the data
2323 * 2325 *
2324 * The control element is supposed to have the private_value field 2326 * The control element is supposed to have the private_value field
2325 * set up via HDA_COMPOSE_AMP_VAL*() or related macros. 2327 * set up via HDA_COMPOSE_AMP_VAL*() or related macros.
@@ -2381,6 +2383,8 @@ update_amp_value(struct hda_codec *codec, hda_nid_t nid,
2381 2383
2382/** 2384/**
2383 * snd_hda_mixer_amp_volume_get - Get callback for a standard AMP mixer volume 2385 * snd_hda_mixer_amp_volume_get - Get callback for a standard AMP mixer volume
2386 * @kcontrol: ctl element
2387 * @ucontrol: pointer to get/store the data
2384 * 2388 *
2385 * The control element is supposed to have the private_value field 2389 * The control element is supposed to have the private_value field
2386 * set up via HDA_COMPOSE_AMP_VAL*() or related macros. 2390 * set up via HDA_COMPOSE_AMP_VAL*() or related macros.
@@ -2406,6 +2410,8 @@ EXPORT_SYMBOL_GPL(snd_hda_mixer_amp_volume_get);
2406 2410
2407/** 2411/**
2408 * snd_hda_mixer_amp_volume_put - Put callback for a standard AMP mixer volume 2412 * snd_hda_mixer_amp_volume_put - Put callback for a standard AMP mixer volume
2413 * @kcontrol: ctl element
2414 * @ucontrol: pointer to get/store the data
2409 * 2415 *
2410 * The control element is supposed to have the private_value field 2416 * The control element is supposed to have the private_value field
2411 * set up via HDA_COMPOSE_AMP_VAL*() or related macros. 2417 * set up via HDA_COMPOSE_AMP_VAL*() or related macros.
@@ -2436,6 +2442,10 @@ EXPORT_SYMBOL_GPL(snd_hda_mixer_amp_volume_put);
2436 2442
2437/** 2443/**
2438 * snd_hda_mixer_amp_volume_put - TLV callback for a standard AMP mixer volume 2444 * snd_hda_mixer_amp_volume_put - TLV callback for a standard AMP mixer volume
2445 * @kcontrol: ctl element
2446 * @op_flag: operation flag
2447 * @size: byte size of input TLV
2448 * @_tlv: TLV data
2439 * 2449 *
2440 * The control element is supposed to have the private_value field 2450 * The control element is supposed to have the private_value field
2441 * set up via HDA_COMPOSE_AMP_VAL*() or related macros. 2451 * set up via HDA_COMPOSE_AMP_VAL*() or related macros.
@@ -3012,6 +3022,8 @@ EXPORT_SYMBOL_GPL(snd_hda_sync_vmaster_hook);
3012 3022
3013/** 3023/**
3014 * snd_hda_mixer_amp_switch_info - Info callback for a standard AMP mixer switch 3024 * snd_hda_mixer_amp_switch_info - Info callback for a standard AMP mixer switch
3025 * @kcontrol: referred ctl element
3026 * @uinfo: pointer to get/store the data
3015 * 3027 *
3016 * The control element is supposed to have the private_value field 3028 * The control element is supposed to have the private_value field
3017 * set up via HDA_COMPOSE_AMP_VAL*() or related macros. 3029 * set up via HDA_COMPOSE_AMP_VAL*() or related macros.
@@ -3031,6 +3043,8 @@ EXPORT_SYMBOL_GPL(snd_hda_mixer_amp_switch_info);
3031 3043
3032/** 3044/**
3033 * snd_hda_mixer_amp_switch_get - Get callback for a standard AMP mixer switch 3045 * snd_hda_mixer_amp_switch_get - Get callback for a standard AMP mixer switch
3046 * @kcontrol: ctl element
3047 * @ucontrol: pointer to get/store the data
3034 * 3048 *
3035 * The control element is supposed to have the private_value field 3049 * The control element is supposed to have the private_value field
3036 * set up via HDA_COMPOSE_AMP_VAL*() or related macros. 3050 * set up via HDA_COMPOSE_AMP_VAL*() or related macros.
@@ -3057,6 +3071,8 @@ EXPORT_SYMBOL_GPL(snd_hda_mixer_amp_switch_get);
3057 3071
3058/** 3072/**
3059 * snd_hda_mixer_amp_switch_put - Put callback for a standard AMP mixer switch 3073 * snd_hda_mixer_amp_switch_put - Put callback for a standard AMP mixer switch
3074 * @kcontrol: ctl element
3075 * @ucontrol: pointer to get/store the data
3060 * 3076 *
3061 * The control element is supposed to have the private_value field 3077 * The control element is supposed to have the private_value field
3062 * set up via HDA_COMPOSE_AMP_VAL*() or related macros. 3078 * set up via HDA_COMPOSE_AMP_VAL*() or related macros.
@@ -3100,6 +3116,8 @@ EXPORT_SYMBOL_GPL(snd_hda_mixer_amp_switch_put);
3100 3116
3101/** 3117/**
3102 * snd_hda_mixer_bind_switch_get - Get callback for a bound volume control 3118 * snd_hda_mixer_bind_switch_get - Get callback for a bound volume control
3119 * @kcontrol: ctl element
3120 * @ucontrol: pointer to get/store the data
3103 * 3121 *
3104 * The control element is supposed to have the private_value field 3122 * The control element is supposed to have the private_value field
3105 * set up via HDA_BIND_MUTE*() macros. 3123 * set up via HDA_BIND_MUTE*() macros.
@@ -3123,6 +3141,8 @@ EXPORT_SYMBOL_GPL(snd_hda_mixer_bind_switch_get);
3123 3141
3124/** 3142/**
3125 * snd_hda_mixer_bind_switch_put - Put callback for a bound volume control 3143 * snd_hda_mixer_bind_switch_put - Put callback for a bound volume control
3144 * @kcontrol: ctl element
3145 * @ucontrol: pointer to get/store the data
3126 * 3146 *
3127 * The control element is supposed to have the private_value field 3147 * The control element is supposed to have the private_value field
3128 * set up via HDA_BIND_MUTE*() macros. 3148 * set up via HDA_BIND_MUTE*() macros.
@@ -3153,6 +3173,8 @@ EXPORT_SYMBOL_GPL(snd_hda_mixer_bind_switch_put);
3153 3173
3154/** 3174/**
3155 * snd_hda_mixer_bind_ctls_info - Info callback for a generic bound control 3175 * snd_hda_mixer_bind_ctls_info - Info callback for a generic bound control
3176 * @kcontrol: referred ctl element
3177 * @uinfo: pointer to get/store the data
3156 * 3178 *
3157 * The control element is supposed to have the private_value field 3179 * The control element is supposed to have the private_value field
3158 * set up via HDA_BIND_VOL() or HDA_BIND_SW() macros. 3180 * set up via HDA_BIND_VOL() or HDA_BIND_SW() macros.
@@ -3176,6 +3198,8 @@ EXPORT_SYMBOL_GPL(snd_hda_mixer_bind_ctls_info);
3176 3198
3177/** 3199/**
3178 * snd_hda_mixer_bind_ctls_get - Get callback for a generic bound control 3200 * snd_hda_mixer_bind_ctls_get - Get callback for a generic bound control
3201 * @kcontrol: ctl element
3202 * @ucontrol: pointer to get/store the data
3179 * 3203 *
3180 * The control element is supposed to have the private_value field 3204 * The control element is supposed to have the private_value field
3181 * set up via HDA_BIND_VOL() or HDA_BIND_SW() macros. 3205 * set up via HDA_BIND_VOL() or HDA_BIND_SW() macros.
@@ -3199,6 +3223,8 @@ EXPORT_SYMBOL_GPL(snd_hda_mixer_bind_ctls_get);
3199 3223
3200/** 3224/**
3201 * snd_hda_mixer_bind_ctls_put - Put callback for a generic bound control 3225 * snd_hda_mixer_bind_ctls_put - Put callback for a generic bound control
3226 * @kcontrol: ctl element
3227 * @ucontrol: pointer to get/store the data
3202 * 3228 *
3203 * The control element is supposed to have the private_value field 3229 * The control element is supposed to have the private_value field
3204 * set up via HDA_BIND_VOL() or HDA_BIND_SW() macros. 3230 * set up via HDA_BIND_VOL() or HDA_BIND_SW() macros.
@@ -3228,6 +3254,10 @@ EXPORT_SYMBOL_GPL(snd_hda_mixer_bind_ctls_put);
3228 3254
3229/** 3255/**
3230 * snd_hda_mixer_bind_tlv - TLV callback for a generic bound control 3256 * snd_hda_mixer_bind_tlv - TLV callback for a generic bound control
3257 * @kcontrol: ctl element
3258 * @op_flag: operation flag
3259 * @size: byte size of input TLV
3260 * @tlv: TLV data
3231 * 3261 *
3232 * The control element is supposed to have the private_value field 3262 * The control element is supposed to have the private_value field
3233 * set up via HDA_BIND_VOL() macro. 3263 * set up via HDA_BIND_VOL() macro.
@@ -4305,6 +4335,7 @@ static struct hda_rate_tbl rate_bits[] = {
4305 * @channels: the number of channels 4335 * @channels: the number of channels
4306 * @format: the PCM format (SNDRV_PCM_FORMAT_XXX) 4336 * @format: the PCM format (SNDRV_PCM_FORMAT_XXX)
4307 * @maxbps: the max. bps 4337 * @maxbps: the max. bps
4338 * @spdif_ctls: HD-audio SPDIF status bits (0 if irrelevant)
4308 * 4339 *
4309 * Calculate the format bitset from the given rate, channels and th PCM format. 4340 * Calculate the format bitset from the given rate, channels and th PCM format.
4310 * 4341 *
@@ -4980,6 +5011,7 @@ static void __snd_hda_power_down(struct hda_codec *codec)
4980 * snd_hda_power_save - Power-up/down/sync the codec 5011 * snd_hda_power_save - Power-up/down/sync the codec
4981 * @codec: HD-audio codec 5012 * @codec: HD-audio codec
4982 * @delta: the counter delta to change 5013 * @delta: the counter delta to change
5014 * @d3wait: sync for D3 transition complete
4983 * 5015 *
4984 * Change the power-up counter via @delta, and power up or down the hardware 5016 * Change the power-up counter via @delta, and power up or down the hardware
4985 * appropriately. For the power-down, queue to the delayed action. 5017 * appropriately. For the power-down, queue to the delayed action.
@@ -5055,6 +5087,10 @@ EXPORT_SYMBOL_GPL(snd_hda_check_amp_list_power);
5055 5087
5056/** 5088/**
5057 * snd_hda_ch_mode_info - Info callback helper for the channel mode enum 5089 * snd_hda_ch_mode_info - Info callback helper for the channel mode enum
5090 * @codec: the HDA codec
5091 * @uinfo: pointer to get/store the data
5092 * @chmode: channel mode array
5093 * @num_chmodes: channel mode array size
5058 */ 5094 */
5059int snd_hda_ch_mode_info(struct hda_codec *codec, 5095int snd_hda_ch_mode_info(struct hda_codec *codec,
5060 struct snd_ctl_elem_info *uinfo, 5096 struct snd_ctl_elem_info *uinfo,
@@ -5074,6 +5110,11 @@ EXPORT_SYMBOL_GPL(snd_hda_ch_mode_info);
5074 5110
5075/** 5111/**
5076 * snd_hda_ch_mode_get - Get callback helper for the channel mode enum 5112 * snd_hda_ch_mode_get - Get callback helper for the channel mode enum
5113 * @codec: the HDA codec
5114 * @ucontrol: pointer to get/store the data
5115 * @chmode: channel mode array
5116 * @num_chmodes: channel mode array size
5117 * @max_channels: max number of channels
5077 */ 5118 */
5078int snd_hda_ch_mode_get(struct hda_codec *codec, 5119int snd_hda_ch_mode_get(struct hda_codec *codec,
5079 struct snd_ctl_elem_value *ucontrol, 5120 struct snd_ctl_elem_value *ucontrol,
@@ -5095,6 +5136,11 @@ EXPORT_SYMBOL_GPL(snd_hda_ch_mode_get);
5095 5136
5096/** 5137/**
5097 * snd_hda_ch_mode_put - Put callback helper for the channel mode enum 5138 * snd_hda_ch_mode_put - Put callback helper for the channel mode enum
5139 * @codec: the HDA codec
5140 * @ucontrol: pointer to get/store the data
5141 * @chmode: channel mode array
5142 * @num_chmodes: channel mode array size
5143 * @max_channelsp: pointer to store the max channels
5098 */ 5144 */
5099int snd_hda_ch_mode_put(struct hda_codec *codec, 5145int snd_hda_ch_mode_put(struct hda_codec *codec,
5100 struct snd_ctl_elem_value *ucontrol, 5146 struct snd_ctl_elem_value *ucontrol,
@@ -5123,6 +5169,8 @@ EXPORT_SYMBOL_GPL(snd_hda_ch_mode_put);
5123 5169
5124/** 5170/**
5125 * snd_hda_input_mux_info_info - Info callback helper for the input-mux enum 5171 * snd_hda_input_mux_info_info - Info callback helper for the input-mux enum
5172 * @imux: imux helper object
5173 * @uinfo: pointer to get/store the data
5126 */ 5174 */
5127int snd_hda_input_mux_info(const struct hda_input_mux *imux, 5175int snd_hda_input_mux_info(const struct hda_input_mux *imux,
5128 struct snd_ctl_elem_info *uinfo) 5176 struct snd_ctl_elem_info *uinfo)
@@ -5144,6 +5192,11 @@ EXPORT_SYMBOL_GPL(snd_hda_input_mux_info);
5144 5192
5145/** 5193/**
5146 * snd_hda_input_mux_info_put - Put callback helper for the input-mux enum 5194 * snd_hda_input_mux_info_put - Put callback helper for the input-mux enum
5195 * @codec: the HDA codec
5196 * @imux: imux helper object
5197 * @ucontrol: pointer to get/store the data
5198 * @nid: input mux NID
5199 * @cur_val: pointer to get/store the current imux value
5147 */ 5200 */
5148int snd_hda_input_mux_put(struct hda_codec *codec, 5201int snd_hda_input_mux_put(struct hda_codec *codec,
5149 const struct hda_input_mux *imux, 5202 const struct hda_input_mux *imux,
@@ -5168,7 +5221,13 @@ int snd_hda_input_mux_put(struct hda_codec *codec,
5168EXPORT_SYMBOL_GPL(snd_hda_input_mux_put); 5221EXPORT_SYMBOL_GPL(snd_hda_input_mux_put);
5169 5222
5170 5223
5171/* 5224/**
5225 * snd_hda_enum_helper_info - Helper for simple enum ctls
5226 * @kcontrol: ctl element
5227 * @uinfo: pointer to get/store the data
5228 * @num_items: number of enum items
5229 * @texts: enum item string array
5230 *
5172 * process kcontrol info callback of a simple string enum array 5231 * process kcontrol info callback of a simple string enum array
5173 * when @num_items is 0 or @texts is NULL, assume a boolean enum array 5232 * when @num_items is 0 or @texts is NULL, assume a boolean enum array
5174 */ 5233 */
@@ -5257,6 +5316,8 @@ EXPORT_SYMBOL_GPL(snd_hda_bus_reboot_notify);
5257 5316
5258/** 5317/**
5259 * snd_hda_multi_out_dig_open - open the digital out in the exclusive mode 5318 * snd_hda_multi_out_dig_open - open the digital out in the exclusive mode
5319 * @codec: the HDA codec
5320 * @mout: hda_multi_out object
5260 */ 5321 */
5261int snd_hda_multi_out_dig_open(struct hda_codec *codec, 5322int snd_hda_multi_out_dig_open(struct hda_codec *codec,
5262 struct hda_multi_out *mout) 5323 struct hda_multi_out *mout)
@@ -5273,6 +5334,11 @@ EXPORT_SYMBOL_GPL(snd_hda_multi_out_dig_open);
5273 5334
5274/** 5335/**
5275 * snd_hda_multi_out_dig_prepare - prepare the digital out stream 5336 * snd_hda_multi_out_dig_prepare - prepare the digital out stream
5337 * @codec: the HDA codec
5338 * @mout: hda_multi_out object
5339 * @stream_tag: stream tag to assign
5340 * @format: format id to assign
5341 * @substream: PCM substream to assign
5276 */ 5342 */
5277int snd_hda_multi_out_dig_prepare(struct hda_codec *codec, 5343int snd_hda_multi_out_dig_prepare(struct hda_codec *codec,
5278 struct hda_multi_out *mout, 5344 struct hda_multi_out *mout,
@@ -5289,6 +5355,8 @@ EXPORT_SYMBOL_GPL(snd_hda_multi_out_dig_prepare);
5289 5355
5290/** 5356/**
5291 * snd_hda_multi_out_dig_cleanup - clean-up the digital out stream 5357 * snd_hda_multi_out_dig_cleanup - clean-up the digital out stream
5358 * @codec: the HDA codec
5359 * @mout: hda_multi_out object
5292 */ 5360 */
5293int snd_hda_multi_out_dig_cleanup(struct hda_codec *codec, 5361int snd_hda_multi_out_dig_cleanup(struct hda_codec *codec,
5294 struct hda_multi_out *mout) 5362 struct hda_multi_out *mout)
@@ -5302,6 +5370,8 @@ EXPORT_SYMBOL_GPL(snd_hda_multi_out_dig_cleanup);
5302 5370
5303/** 5371/**
5304 * snd_hda_multi_out_dig_close - release the digital out stream 5372 * snd_hda_multi_out_dig_close - release the digital out stream
5373 * @codec: the HDA codec
5374 * @mout: hda_multi_out object
5305 */ 5375 */
5306int snd_hda_multi_out_dig_close(struct hda_codec *codec, 5376int snd_hda_multi_out_dig_close(struct hda_codec *codec,
5307 struct hda_multi_out *mout) 5377 struct hda_multi_out *mout)
@@ -5315,6 +5385,10 @@ EXPORT_SYMBOL_GPL(snd_hda_multi_out_dig_close);
5315 5385
5316/** 5386/**
5317 * snd_hda_multi_out_analog_open - open analog outputs 5387 * snd_hda_multi_out_analog_open - open analog outputs
5388 * @codec: the HDA codec
5389 * @mout: hda_multi_out object
5390 * @substream: PCM substream to assign
5391 * @hinfo: PCM information to assign
5318 * 5392 *
5319 * Open analog outputs and set up the hw-constraints. 5393 * Open analog outputs and set up the hw-constraints.
5320 * If the digital outputs can be opened as slave, open the digital 5394 * If the digital outputs can be opened as slave, open the digital
@@ -5365,6 +5439,11 @@ EXPORT_SYMBOL_GPL(snd_hda_multi_out_analog_open);
5365 5439
5366/** 5440/**
5367 * snd_hda_multi_out_analog_prepare - Preapre the analog outputs. 5441 * snd_hda_multi_out_analog_prepare - Preapre the analog outputs.
5442 * @codec: the HDA codec
5443 * @mout: hda_multi_out object
5444 * @stream_tag: stream tag to assign
5445 * @format: format id to assign
5446 * @substream: PCM substream to assign
5368 * 5447 *
5369 * Set up the i/o for analog out. 5448 * Set up the i/o for analog out.
5370 * When the digital out is available, copy the front out to digital out, too. 5449 * When the digital out is available, copy the front out to digital out, too.
@@ -5442,6 +5521,8 @@ EXPORT_SYMBOL_GPL(snd_hda_multi_out_analog_prepare);
5442 5521
5443/** 5522/**
5444 * snd_hda_multi_out_analog_cleanup - clean up the setting for analog out 5523 * snd_hda_multi_out_analog_cleanup - clean up the setting for analog out
5524 * @codec: the HDA codec
5525 * @mout: hda_multi_out object
5445 */ 5526 */
5446int snd_hda_multi_out_analog_cleanup(struct hda_codec *codec, 5527int snd_hda_multi_out_analog_cleanup(struct hda_codec *codec,
5447 struct hda_multi_out *mout) 5528 struct hda_multi_out *mout)
@@ -5473,6 +5554,8 @@ EXPORT_SYMBOL_GPL(snd_hda_multi_out_analog_cleanup);
5473 5554
5474/** 5555/**
5475 * snd_hda_get_default_vref - Get the default (mic) VREF pin bits 5556 * snd_hda_get_default_vref - Get the default (mic) VREF pin bits
5557 * @codec: the HDA codec
5558 * @pin: referred pin NID
5476 * 5559 *
5477 * Guess the suitable VREF pin bits to be set as the pin-control value. 5560 * Guess the suitable VREF pin bits to be set as the pin-control value.
5478 * Note: the function doesn't set the AC_PINCTL_IN_EN bit. 5561 * Note: the function doesn't set the AC_PINCTL_IN_EN bit.
@@ -5498,7 +5581,12 @@ unsigned int snd_hda_get_default_vref(struct hda_codec *codec, hda_nid_t pin)
5498} 5581}
5499EXPORT_SYMBOL_GPL(snd_hda_get_default_vref); 5582EXPORT_SYMBOL_GPL(snd_hda_get_default_vref);
5500 5583
5501/* correct the pin ctl value for matching with the pin cap */ 5584/**
5585 * snd_hda_correct_pin_ctl - correct the pin ctl value for matching with the pin cap
5586 * @codec: the HDA codec
5587 * @pin: referred pin NID
5588 * @val: pin ctl value to audit
5589 */
5502unsigned int snd_hda_correct_pin_ctl(struct hda_codec *codec, 5590unsigned int snd_hda_correct_pin_ctl(struct hda_codec *codec,
5503 hda_nid_t pin, unsigned int val) 5591 hda_nid_t pin, unsigned int val)
5504{ 5592{
@@ -5549,6 +5637,19 @@ unsigned int snd_hda_correct_pin_ctl(struct hda_codec *codec,
5549} 5637}
5550EXPORT_SYMBOL_GPL(snd_hda_correct_pin_ctl); 5638EXPORT_SYMBOL_GPL(snd_hda_correct_pin_ctl);
5551 5639
5640/**
5641 * _snd_hda_pin_ctl - Helper to set pin ctl value
5642 * @codec: the HDA codec
5643 * @pin: referred pin NID
5644 * @val: pin control value to set
5645 * @cached: access over codec pinctl cache or direct write
5646 *
5647 * This function is a helper to set a pin ctl value more safely.
5648 * It corrects the pin ctl value via snd_hda_correct_pin_ctl(), stores the
5649 * value in pin target array via snd_hda_codec_set_pin_target(), then
5650 * actually writes the value via either snd_hda_codec_update_cache() or
5651 * snd_hda_codec_write() depending on @cached flag.
5652 */
5552int _snd_hda_set_pin_ctl(struct hda_codec *codec, hda_nid_t pin, 5653int _snd_hda_set_pin_ctl(struct hda_codec *codec, hda_nid_t pin,
5553 unsigned int val, bool cached) 5654 unsigned int val, bool cached)
5554{ 5655{
@@ -5565,6 +5666,11 @@ EXPORT_SYMBOL_GPL(_snd_hda_set_pin_ctl);
5565 5666
5566/** 5667/**
5567 * snd_hda_add_imux_item - Add an item to input_mux 5668 * snd_hda_add_imux_item - Add an item to input_mux
5669 * @codec: the HDA codec
5670 * @imux: imux helper object
5671 * @label: the name of imux item to assign
5672 * @index: index number of imux item to assign
5673 * @type_idx: pointer to store the resultant label index
5568 * 5674 *
5569 * When the same label is used already in the existing items, the number 5675 * When the same label is used already in the existing items, the number
5570 * suffix is appended to the label. This label index number is stored 5676 * suffix is appended to the label. This label index number is stored
diff --git a/sound/pci/hda/hda_eld.c b/sound/pci/hda/hda_eld.c
index e1cd34d9011d..0e6d7534f491 100644
--- a/sound/pci/hda/hda_eld.c
+++ b/sound/pci/hda/hda_eld.c
@@ -371,7 +371,7 @@ error:
371 return ret; 371 return ret;
372} 372}
373 373
374/** 374/*
375 * SNDRV_PCM_RATE_* and AC_PAR_PCM values don't match, print correct rates with 375 * SNDRV_PCM_RATE_* and AC_PAR_PCM values don't match, print correct rates with
376 * hdmi-specific routine. 376 * hdmi-specific routine.
377 */ 377 */
diff --git a/sound/pci/hda/hda_jack.c b/sound/pci/hda/hda_jack.c
index f56765ae73a7..b2d81ab22fb0 100644
--- a/sound/pci/hda/hda_jack.c
+++ b/sound/pci/hda/hda_jack.c
@@ -57,6 +57,8 @@ static u32 read_pin_sense(struct hda_codec *codec, hda_nid_t nid)
57 57
58/** 58/**
59 * snd_hda_jack_tbl_get - query the jack-table entry for the given NID 59 * snd_hda_jack_tbl_get - query the jack-table entry for the given NID
60 * @codec: the HDA codec
61 * @nid: pin NID to refer to
60 */ 62 */
61struct hda_jack_tbl * 63struct hda_jack_tbl *
62snd_hda_jack_tbl_get(struct hda_codec *codec, hda_nid_t nid) 64snd_hda_jack_tbl_get(struct hda_codec *codec, hda_nid_t nid)
@@ -75,6 +77,8 @@ EXPORT_SYMBOL_GPL(snd_hda_jack_tbl_get);
75 77
76/** 78/**
77 * snd_hda_jack_tbl_get_from_tag - query the jack-table entry for the given tag 79 * snd_hda_jack_tbl_get_from_tag - query the jack-table entry for the given tag
80 * @codec: the HDA codec
81 * @tag: tag value to refer to
78 */ 82 */
79struct hda_jack_tbl * 83struct hda_jack_tbl *
80snd_hda_jack_tbl_get_from_tag(struct hda_codec *codec, unsigned char tag) 84snd_hda_jack_tbl_get_from_tag(struct hda_codec *codec, unsigned char tag)
@@ -93,6 +97,8 @@ EXPORT_SYMBOL_GPL(snd_hda_jack_tbl_get_from_tag);
93 97
94/** 98/**
95 * snd_hda_jack_tbl_new - create a jack-table entry for the given NID 99 * snd_hda_jack_tbl_new - create a jack-table entry for the given NID
100 * @codec: the HDA codec
101 * @nid: pin NID to assign
96 */ 102 */
97static struct hda_jack_tbl * 103static struct hda_jack_tbl *
98snd_hda_jack_tbl_new(struct hda_codec *codec, hda_nid_t nid) 104snd_hda_jack_tbl_new(struct hda_codec *codec, hda_nid_t nid)
@@ -162,6 +168,7 @@ static void jack_detect_update(struct hda_codec *codec,
162 168
163/** 169/**
164 * snd_hda_set_dirty_all - Mark all the cached as dirty 170 * snd_hda_set_dirty_all - Mark all the cached as dirty
171 * @codec: the HDA codec
165 * 172 *
166 * This function sets the dirty flag to all entries of jack table. 173 * This function sets the dirty flag to all entries of jack table.
167 * It's called from the resume path in hda_codec.c. 174 * It's called from the resume path in hda_codec.c.
@@ -218,6 +225,9 @@ EXPORT_SYMBOL_GPL(snd_hda_jack_detect_state);
218 225
219/** 226/**
220 * snd_hda_jack_detect_enable - enable the jack-detection 227 * snd_hda_jack_detect_enable - enable the jack-detection
228 * @codec: the HDA codec
229 * @nid: pin NID to enable
230 * @func: callback function to register
221 * 231 *
222 * In the case of error, the return value will be a pointer embedded with 232 * In the case of error, the return value will be a pointer embedded with
223 * errno. Check and handle the return value appropriately with standard 233 * errno. Check and handle the return value appropriately with standard
@@ -266,6 +276,9 @@ EXPORT_SYMBOL_GPL(snd_hda_jack_detect_enable);
266 276
267/** 277/**
268 * snd_hda_jack_set_gating_jack - Set gating jack. 278 * snd_hda_jack_set_gating_jack - Set gating jack.
279 * @codec: the HDA codec
280 * @gated_nid: gated pin NID
281 * @gating_nid: gating pin NID
269 * 282 *
270 * Indicates the gated jack is only valid when the gating jack is plugged. 283 * Indicates the gated jack is only valid when the gating jack is plugged.
271 */ 284 */
@@ -287,6 +300,7 @@ EXPORT_SYMBOL_GPL(snd_hda_jack_set_gating_jack);
287 300
288/** 301/**
289 * snd_hda_jack_report_sync - sync the states of all jacks and report if changed 302 * snd_hda_jack_report_sync - sync the states of all jacks and report if changed
303 * @codec: the HDA codec
290 */ 304 */
291void snd_hda_jack_report_sync(struct hda_codec *codec) 305void snd_hda_jack_report_sync(struct hda_codec *codec)
292{ 306{
@@ -349,6 +363,11 @@ static void hda_free_jack_priv(struct snd_jack *jack)
349 363
350/** 364/**
351 * snd_hda_jack_add_kctl - Add a kctl for the given pin 365 * snd_hda_jack_add_kctl - Add a kctl for the given pin
366 * @codec: the HDA codec
367 * @nid: pin NID to assign
368 * @name: string name for the jack
369 * @idx: index number for the jack
370 * @phantom_jack: flag to deal as a phantom jack
352 * 371 *
353 * This assigns a jack-detection kctl to the given pin. The kcontrol 372 * This assigns a jack-detection kctl to the given pin. The kcontrol
354 * will have the given name and index. 373 * will have the given name and index.
@@ -456,6 +475,8 @@ static int add_jack_kctl(struct hda_codec *codec, hda_nid_t nid,
456 475
457/** 476/**
458 * snd_hda_jack_add_kctls - Add kctls for all pins included in the given pincfg 477 * snd_hda_jack_add_kctls - Add kctls for all pins included in the given pincfg
478 * @codec: the HDA codec
479 * @cfg: pin config table to parse
459 */ 480 */
460int snd_hda_jack_add_kctls(struct hda_codec *codec, 481int snd_hda_jack_add_kctls(struct hda_codec *codec,
461 const struct auto_pin_cfg *cfg) 482 const struct auto_pin_cfg *cfg)