]> err.no Git - linux-2.6/commitdiff
[ALSA] hda-codec - Show power state in proc file
authorTakashi Iwai <tiwai@suse.de>
Wed, 2 Nov 2005 17:13:41 +0000 (18:13 +0100)
committerJaroslav Kysela <perex@suse.cz>
Fri, 4 Nov 2005 12:25:41 +0000 (13:25 +0100)
Modules: HDA generic driver

Show the power state of each widget in proc file.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/pci/hda/hda_proc.c

index 08f6a6efc5e6b75212c2a9c62a2c6a9e735c742d..39ddf1cd901901bab6c19b07b208f7f1480126b8 100644 (file)
@@ -281,6 +281,11 @@ static void print_codec_info(snd_info_entry_t *entry, snd_info_buffer_t *buffer)
                        print_pcm_caps(buffer, codec, nid);
                }
 
+               if (wid_caps & AC_WCAP_POWER)
+                       snd_iprintf(buffer, "  Power: 0x%x\n",
+                                   snd_hda_codec_read(codec, nid, 0,
+                                                      AC_VERB_GET_POWER_STATE, 0));
+
                if (wid_caps & AC_WCAP_CONN_LIST) {
                        int c, curr = -1;
                        if (conn_len > 1 && wid_type != AC_WID_AUD_MIX)