summaryrefslogtreecommitdiffstats
path: root/sound/x86
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2017-02-02 11:27:40 -0500
committerTakashi Iwai <tiwai@suse.de>2017-02-03 11:37:41 -0500
commit44684f61b23c68786834dd2a99d4a68d40a13308 (patch)
tree64f89586f960e87081ebaa4368139dcaf20ca168 /sound/x86
parent36ed34662f1944ebf553b30fcba1abab1703d125 (diff)
ALSA: x86: Simplify comments
It's a stand-alone small driver code, and we don't have to describe too much formalized comments in kernel-doc style for local functions at all. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/x86')
-rw-r--r--sound/x86/intel_hdmi_audio.c66
1 files changed, 14 insertions, 52 deletions
diff --git a/sound/x86/intel_hdmi_audio.c b/sound/x86/intel_hdmi_audio.c
index 24a18b88c927..5613c675ce70 100644
--- a/sound/x86/intel_hdmi_audio.c
+++ b/sound/x86/intel_hdmi_audio.c
@@ -609,11 +609,7 @@ static int had_register_chmap_ctls(struct snd_intelhad *intelhaddata,
609} 609}
610 610
611/* 611/*
612 * snd_intelhad_prog_dip - to initialize Data Island Packets registers 612 * Initialize Data Island Packets registers
613 *
614 * @substream:substream for which the prepare function is called
615 * @intelhaddata:substream private data
616 *
617 * This function is called in the prepare callback 613 * This function is called in the prepare callback
618 */ 614 */
619static void snd_intelhad_prog_dip(struct snd_pcm_substream *substream, 615static void snd_intelhad_prog_dip(struct snd_pcm_substream *substream,
@@ -666,10 +662,7 @@ static void snd_intelhad_prog_dip(struct snd_pcm_substream *substream,
666} 662}
667 663
668/* 664/*
669 * snd_intelhad_prog_buffer - programs buffer address and length registers 665 * Programs buffer address and length registers
670 * @substream: substream for which the prepare function is called
671 * @intelhaddata: substream private data
672 *
673 * This function programs ring buffer address and length into registers. 666 * This function programs ring buffer address and length into registers.
674 */ 667 */
675static int snd_intelhad_prog_buffer(struct snd_pcm_substream *substream, 668static int snd_intelhad_prog_buffer(struct snd_pcm_substream *substream,
@@ -824,7 +817,7 @@ static int had_calculate_maud_value(u32 aud_samp_freq, u32 link_rate)
824} 817}
825 818
826/* 819/*
827 * snd_intelhad_prog_cts - Program HDMI audio CTS value 820 * Program HDMI audio CTS value
828 * 821 *
829 * @aud_samp_freq: sampling frequency of audio data 822 * @aud_samp_freq: sampling frequency of audio data
830 * @tmds: sampling frequency of the display data 823 * @tmds: sampling frequency of the display data
@@ -896,7 +889,7 @@ static int had_calculate_n_value(u32 aud_samp_freq)
896} 889}
897 890
898/* 891/*
899 * snd_intelhad_prog_n - Program HDMI audio N value 892 * Program HDMI audio N value
900 * 893 *
901 * @aud_samp_freq: sampling frequency of audio data 894 * @aud_samp_freq: sampling frequency of audio data
902 * @n_param: N value, depends on aud_samp_freq 895 * @n_param: N value, depends on aud_samp_freq
@@ -962,10 +955,7 @@ static void snd_intelhad_handle_underrun(struct snd_intelhad *intelhaddata)
962} 955}
963 956
964/* 957/*
965 * snd_intelhad_open - stream initializations are done here 958 * ALSA PCM open callback
966 * @substream:substream for which the stream function is called
967 *
968 * This function is called whenever a PCM stream is opened
969 */ 959 */
970static int snd_intelhad_open(struct snd_pcm_substream *substream) 960static int snd_intelhad_open(struct snd_pcm_substream *substream)
971{ 961{
@@ -1017,10 +1007,7 @@ static int snd_intelhad_open(struct snd_pcm_substream *substream)
1017} 1007}
1018 1008
1019/* 1009/*
1020 * snd_intelhad_close - to free parameteres when stream is stopped 1010 * ALSA PCM close callback
1021 * @substream: substream for which the function is called
1022 *
1023 * This function is called by ALSA framework when stream is stopped
1024 */ 1011 */
1025static int snd_intelhad_close(struct snd_pcm_substream *substream) 1012static int snd_intelhad_close(struct snd_pcm_substream *substream)
1026{ 1013{
@@ -1051,12 +1038,7 @@ static int snd_intelhad_close(struct snd_pcm_substream *substream)
1051} 1038}
1052 1039
1053/* 1040/*
1054 * snd_intelhad_hw_params - to setup the hardware parameters 1041 * ALSA PCM hw_params callback
1055 * like allocating the buffers
1056 * @substream: substream for which the function is called
1057 * @hw_params: hardware parameters
1058 *
1059 * This function is called by ALSA framework when hardware params are set
1060 */ 1042 */
1061static int snd_intelhad_hw_params(struct snd_pcm_substream *substream, 1043static int snd_intelhad_hw_params(struct snd_pcm_substream *substream,
1062 struct snd_pcm_hw_params *hw_params) 1044 struct snd_pcm_hw_params *hw_params)
@@ -1090,11 +1072,7 @@ static int snd_intelhad_hw_params(struct snd_pcm_substream *substream,
1090} 1072}
1091 1073
1092/* 1074/*
1093 * snd_intelhad_hw_free - to release the resources allocated during 1075 * ALSA PCM hw_free callback
1094 * hardware params setup
1095 * @substream: substream for which the function is called
1096 *
1097 * This function is called by ALSA framework before close callback.
1098 */ 1076 */
1099static int snd_intelhad_hw_free(struct snd_pcm_substream *substream) 1077static int snd_intelhad_hw_free(struct snd_pcm_substream *substream)
1100{ 1078{
@@ -1113,11 +1091,7 @@ static int snd_intelhad_hw_free(struct snd_pcm_substream *substream)
1113} 1091}
1114 1092
1115/* 1093/*
1116 * snd_intelhad_pcm_trigger - stream activities are handled here 1094 * ALSA PCM trigger callback
1117 * @substream: substream for which the stream function is called
1118 * @cmd: the stream commamd thats requested from upper layer
1119 *
1120 * This function is called whenever an a stream activity is invoked
1121 */ 1095 */
1122static int snd_intelhad_pcm_trigger(struct snd_pcm_substream *substream, 1096static int snd_intelhad_pcm_trigger(struct snd_pcm_substream *substream,
1123 int cmd) 1097 int cmd)
@@ -1172,10 +1146,7 @@ static int snd_intelhad_pcm_trigger(struct snd_pcm_substream *substream,
1172} 1146}
1173 1147
1174/* 1148/*
1175 * snd_intelhad_pcm_prepare - internal preparation before starting a stream 1149 * ALSA PCM prepare callback
1176 * @substream: substream for which the function is called
1177 *
1178 * This function is called when a stream is started for internal preparation.
1179 */ 1150 */
1180static int snd_intelhad_pcm_prepare(struct snd_pcm_substream *substream) 1151static int snd_intelhad_pcm_prepare(struct snd_pcm_substream *substream)
1181{ 1152{
@@ -1243,14 +1214,10 @@ prep_end:
1243} 1214}
1244 1215
1245/* 1216/*
1246 * snd_intelhad_pcm_pointer- to send the current buffer pointerprocessed by hw 1217 * ALSA PCM pointer callback
1247 * @substream: substream for which the function is called
1248 *
1249 * This function is called by ALSA framework to get the current hw buffer ptr
1250 * when a period is elapsed
1251 */ 1218 */
1252static snd_pcm_uframes_t snd_intelhad_pcm_pointer( 1219static snd_pcm_uframes_t
1253 struct snd_pcm_substream *substream) 1220snd_intelhad_pcm_pointer(struct snd_pcm_substream *substream)
1254{ 1221{
1255 struct snd_intelhad *intelhaddata; 1222 struct snd_intelhad *intelhaddata;
1256 u32 bytes_rendered = 0; 1223 u32 bytes_rendered = 0;
@@ -1299,12 +1266,7 @@ static snd_pcm_uframes_t snd_intelhad_pcm_pointer(
1299} 1266}
1300 1267
1301/* 1268/*
1302 * snd_intelhad_pcm_mmap- mmaps a kernel buffer to user space for copying data 1269 * ALSA PCM mmap callback
1303 * @substream: substream for which the function is called
1304 * @vma: struct instance of memory VMM memory area
1305 *
1306 * This function is called by OS when a user space component
1307 * tries to get mmap memory from driver
1308 */ 1270 */
1309static int snd_intelhad_pcm_mmap(struct snd_pcm_substream *substream, 1271static int snd_intelhad_pcm_mmap(struct snd_pcm_substream *substream,
1310 struct vm_area_struct *vma) 1272 struct vm_area_struct *vma)