diff options
author | Fengguang Wu <fengguang.wu@intel.com> | 2012-04-10 05:00:35 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2012-04-10 08:53:55 -0400 |
commit | fae3d88a5c56c3f836e95c4516da883a48612437 (patch) | |
tree | eb08d977ab3da42c466062ba237e05b4e4a1ae5f /sound | |
parent | 38be95dd3d314bd393a26f6e441ae2c57ef7f064 (diff) |
ALSA: hda - hide HDMI/ELD printks unless snd.debug=2
Also remove two warnings when CONFIG_SND_DEBUG is not set:
sound/pci/hda/patch_hdmi.c: In function ‘hdmi_intrinsic_event’:
sound/pci/hda/patch_hdmi.c:761:6: warning: unused variable ‘eldv’ [-Wunused-variable]
sound/pci/hda/patch_hdmi.c:760:6: warning: unused variable ‘pd’ [-Wunused-variable]
Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound')
-rw-r--r-- | sound/pci/hda/hda_eld.c | 6 | ||||
-rw-r--r-- | sound/pci/hda/patch_hdmi.c | 9 |
2 files changed, 7 insertions, 8 deletions
diff --git a/sound/pci/hda/hda_eld.c b/sound/pci/hda/hda_eld.c index b58b4b1687fa..4c054f4486b9 100644 --- a/sound/pci/hda/hda_eld.c +++ b/sound/pci/hda/hda_eld.c | |||
@@ -418,7 +418,7 @@ static void hdmi_show_short_audio_desc(struct cea_sad *a) | |||
418 | else | 418 | else |
419 | buf2[0] = '\0'; | 419 | buf2[0] = '\0'; |
420 | 420 | ||
421 | printk(KERN_INFO "HDMI: supports coding type %s:" | 421 | _snd_printd(SND_PR_VERBOSE, "HDMI: supports coding type %s:" |
422 | " channels = %d, rates =%s%s\n", | 422 | " channels = %d, rates =%s%s\n", |
423 | cea_audio_coding_type_names[a->format], | 423 | cea_audio_coding_type_names[a->format], |
424 | a->channels, | 424 | a->channels, |
@@ -442,14 +442,14 @@ void snd_hdmi_show_eld(struct hdmi_eld *e) | |||
442 | { | 442 | { |
443 | int i; | 443 | int i; |
444 | 444 | ||
445 | printk(KERN_INFO "HDMI: detected monitor %s at connection type %s\n", | 445 | _snd_printd(SND_PR_VERBOSE, "HDMI: detected monitor %s at connection type %s\n", |
446 | e->monitor_name, | 446 | e->monitor_name, |
447 | eld_connection_type_names[e->conn_type]); | 447 | eld_connection_type_names[e->conn_type]); |
448 | 448 | ||
449 | if (e->spk_alloc) { | 449 | if (e->spk_alloc) { |
450 | char buf[SND_PRINT_CHANNEL_ALLOCATION_ADVISED_BUFSIZE]; | 450 | char buf[SND_PRINT_CHANNEL_ALLOCATION_ADVISED_BUFSIZE]; |
451 | snd_print_channel_allocation(e->spk_alloc, buf, sizeof(buf)); | 451 | snd_print_channel_allocation(e->spk_alloc, buf, sizeof(buf)); |
452 | printk(KERN_INFO "HDMI: available speakers:%s\n", buf); | 452 | _snd_printd(SND_PR_VERBOSE, "HDMI: available speakers:%s\n", buf); |
453 | } | 453 | } |
454 | 454 | ||
455 | for (i = 0; i < e->sad_count; i++) | 455 | for (i = 0; i < e->sad_count; i++) |
diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c index 540cd13f7f15..83f345f3c961 100644 --- a/sound/pci/hda/patch_hdmi.c +++ b/sound/pci/hda/patch_hdmi.c | |||
@@ -757,8 +757,6 @@ static void hdmi_intrinsic_event(struct hda_codec *codec, unsigned int res) | |||
757 | struct hdmi_spec *spec = codec->spec; | 757 | struct hdmi_spec *spec = codec->spec; |
758 | int tag = res >> AC_UNSOL_RES_TAG_SHIFT; | 758 | int tag = res >> AC_UNSOL_RES_TAG_SHIFT; |
759 | int pin_nid; | 759 | int pin_nid; |
760 | int pd = !!(res & AC_UNSOL_RES_PD); | ||
761 | int eldv = !!(res & AC_UNSOL_RES_ELDV); | ||
762 | int pin_idx; | 760 | int pin_idx; |
763 | struct hda_jack_tbl *jack; | 761 | struct hda_jack_tbl *jack; |
764 | 762 | ||
@@ -768,9 +766,10 @@ static void hdmi_intrinsic_event(struct hda_codec *codec, unsigned int res) | |||
768 | pin_nid = jack->nid; | 766 | pin_nid = jack->nid; |
769 | jack->jack_dirty = 1; | 767 | jack->jack_dirty = 1; |
770 | 768 | ||
771 | printk(KERN_INFO | 769 | _snd_printd(SND_PR_VERBOSE, |
772 | "HDMI hot plug event: Codec=%d Pin=%d Presence_Detect=%d ELD_Valid=%d\n", | 770 | "HDMI hot plug event: Codec=%d Pin=%d Presence_Detect=%d ELD_Valid=%d\n", |
773 | codec->addr, pin_nid, pd, eldv); | 771 | codec->addr, pin_nid, |
772 | !!(res & AC_UNSOL_RES_PD), !!(res & AC_UNSOL_RES_ELDV)); | ||
774 | 773 | ||
775 | pin_idx = pin_nid_to_pin_index(spec, pin_nid); | 774 | pin_idx = pin_nid_to_pin_index(spec, pin_nid); |
776 | if (pin_idx < 0) | 775 | if (pin_idx < 0) |
@@ -992,7 +991,7 @@ static void hdmi_present_sense(struct hdmi_spec_per_pin *per_pin, int repoll) | |||
992 | if (eld->monitor_present) | 991 | if (eld->monitor_present) |
993 | eld_valid = !!(present & AC_PINSENSE_ELDV); | 992 | eld_valid = !!(present & AC_PINSENSE_ELDV); |
994 | 993 | ||
995 | printk(KERN_INFO | 994 | _snd_printd(SND_PR_VERBOSE, |
996 | "HDMI status: Codec=%d Pin=%d Presence_Detect=%d ELD_Valid=%d\n", | 995 | "HDMI status: Codec=%d Pin=%d Presence_Detect=%d ELD_Valid=%d\n", |
997 | codec->addr, pin_nid, eld->monitor_present, eld_valid); | 996 | codec->addr, pin_nid, eld->monitor_present, eld_valid); |
998 | 997 | ||