aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/hda/hda_proc.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2007-07-27 10:52:19 -0400
committerJaroslav Kysela <perex@perex.cz>2007-10-16 09:58:09 -0400
commitd01ce99fc53271cd8ef0ef6b9a2790177fd410a1 (patch)
treed6723036b6bd896c120cf49dd049ddf182ec703d /sound/pci/hda/hda_proc.c
parente2340465ec9587362a057524d3e2163377366771 (diff)
[ALSA] hda-intel - Coding style fixes
Fix codes to follow more to the standard kernel coding style. Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Diffstat (limited to 'sound/pci/hda/hda_proc.c')
-rw-r--r--sound/pci/hda/hda_proc.c27
1 files changed, 18 insertions, 9 deletions
diff --git a/sound/pci/hda/hda_proc.c b/sound/pci/hda/hda_proc.c
index ac15066fd300..ccd19180e541 100644
--- a/sound/pci/hda/hda_proc.c
+++ b/sound/pci/hda/hda_proc.c
@@ -58,7 +58,8 @@ static void print_amp_caps(struct snd_info_buffer *buffer,
58 snd_iprintf(buffer, "N/A\n"); 58 snd_iprintf(buffer, "N/A\n");
59 return; 59 return;
60 } 60 }
61 snd_iprintf(buffer, "ofs=0x%02x, nsteps=0x%02x, stepsize=0x%02x, mute=%x\n", 61 snd_iprintf(buffer, "ofs=0x%02x, nsteps=0x%02x, stepsize=0x%02x, "
62 "mute=%x\n",
62 caps & AC_AMPCAP_OFFSET, 63 caps & AC_AMPCAP_OFFSET,
63 (caps & AC_AMPCAP_NUM_STEPS) >> AC_AMPCAP_NUM_STEPS_SHIFT, 64 (caps & AC_AMPCAP_NUM_STEPS) >> AC_AMPCAP_NUM_STEPS_SHIFT,
64 (caps & AC_AMPCAP_STEP_SIZE) >> AC_AMPCAP_STEP_SIZE_SHIFT, 65 (caps & AC_AMPCAP_STEP_SIZE) >> AC_AMPCAP_STEP_SIZE_SHIFT,
@@ -76,11 +77,13 @@ static void print_amp_vals(struct snd_info_buffer *buffer,
76 for (i = 0; i < indices; i++) { 77 for (i = 0; i < indices; i++) {
77 snd_iprintf(buffer, " ["); 78 snd_iprintf(buffer, " [");
78 if (stereo) { 79 if (stereo) {
79 val = snd_hda_codec_read(codec, nid, 0, AC_VERB_GET_AMP_GAIN_MUTE, 80 val = snd_hda_codec_read(codec, nid, 0,
81 AC_VERB_GET_AMP_GAIN_MUTE,
80 AC_AMP_GET_LEFT | dir | i); 82 AC_AMP_GET_LEFT | dir | i);
81 snd_iprintf(buffer, "0x%02x ", val); 83 snd_iprintf(buffer, "0x%02x ", val);
82 } 84 }
83 val = snd_hda_codec_read(codec, nid, 0, AC_VERB_GET_AMP_GAIN_MUTE, 85 val = snd_hda_codec_read(codec, nid, 0,
86 AC_VERB_GET_AMP_GAIN_MUTE,
84 AC_AMP_GET_RIGHT | dir | i); 87 AC_AMP_GET_RIGHT | dir | i);
85 snd_iprintf(buffer, "0x%02x]", val); 88 snd_iprintf(buffer, "0x%02x]", val);
86 } 89 }
@@ -237,7 +240,8 @@ static void print_pin_caps(struct snd_info_buffer *buffer,
237} 240}
238 241
239 242
240static void print_codec_info(struct snd_info_entry *entry, struct snd_info_buffer *buffer) 243static void print_codec_info(struct snd_info_entry *entry,
244 struct snd_info_buffer *buffer)
241{ 245{
242 struct hda_codec *codec = entry->private_data; 246 struct hda_codec *codec = entry->private_data;
243 char buf[32]; 247 char buf[32];
@@ -271,9 +275,11 @@ static void print_codec_info(struct snd_info_entry *entry, struct snd_info_buffe
271 return; 275 return;
272 } 276 }
273 for (i = 0; i < nodes; i++, nid++) { 277 for (i = 0; i < nodes; i++, nid++) {
274 unsigned int wid_caps = snd_hda_param_read(codec, nid, 278 unsigned int wid_caps =
275 AC_PAR_AUDIO_WIDGET_CAP); 279 snd_hda_param_read(codec, nid,
276 unsigned int wid_type = (wid_caps & AC_WCAP_TYPE) >> AC_WCAP_TYPE_SHIFT; 280 AC_PAR_AUDIO_WIDGET_CAP);
281 unsigned int wid_type =
282 (wid_caps & AC_WCAP_TYPE) >> AC_WCAP_TYPE_SHIFT;
277 int conn_len = 0; 283 int conn_len = 0;
278 hda_nid_t conn[HDA_MAX_CONNECTIONS]; 284 hda_nid_t conn[HDA_MAX_CONNECTIONS];
279 285
@@ -313,7 +319,9 @@ static void print_codec_info(struct snd_info_entry *entry, struct snd_info_buffe
313 if (wid_type == AC_WID_PIN) { 319 if (wid_type == AC_WID_PIN) {
314 unsigned int pinctls; 320 unsigned int pinctls;
315 print_pin_caps(buffer, codec, nid); 321 print_pin_caps(buffer, codec, nid);
316 pinctls = snd_hda_codec_read(codec, nid, 0, AC_VERB_GET_PIN_WIDGET_CONTROL, 0); 322 pinctls = snd_hda_codec_read(codec, nid, 0,
323 AC_VERB_GET_PIN_WIDGET_CONTROL,
324 0);
317 snd_iprintf(buffer, " Pin-ctls: 0x%02x:", pinctls); 325 snd_iprintf(buffer, " Pin-ctls: 0x%02x:", pinctls);
318 if (pinctls & AC_PINCTL_IN_EN) 326 if (pinctls & AC_PINCTL_IN_EN)
319 snd_iprintf(buffer, " IN"); 327 snd_iprintf(buffer, " IN");
@@ -333,7 +341,8 @@ static void print_codec_info(struct snd_info_entry *entry, struct snd_info_buffe
333 if (wid_caps & AC_WCAP_POWER) 341 if (wid_caps & AC_WCAP_POWER)
334 snd_iprintf(buffer, " Power: 0x%x\n", 342 snd_iprintf(buffer, " Power: 0x%x\n",
335 snd_hda_codec_read(codec, nid, 0, 343 snd_hda_codec_read(codec, nid, 0,
336 AC_VERB_GET_POWER_STATE, 0)); 344 AC_VERB_GET_POWER_STATE,
345 0));
337 346
338 if (wid_caps & AC_WCAP_CONN_LIST) { 347 if (wid_caps & AC_WCAP_CONN_LIST) {
339 int c, curr = -1; 348 int c, curr = -1;