projects
/
GitHub
/
LineageOS
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0f4ccbb
)
ALSA: hda - check proper return value
author
Wang Xingchao
<xingchao.wang@intel.com>
Thu, 7 Jun 2012 08:52:07 +0000
(16:52 +0800)
committer
Takashi Iwai
<tiwai@suse.de>
Thu, 7 Jun 2012 09:40:58 +0000
(11:40 +0200)
snd_hda_param_read() return value -1 means error, others are responses
Signed-off-by: Wang Xingchao <xingchao.wang@intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/pci/hda/hda_proc.c
patch
|
blob
|
blame
|
history
diff --git
a/sound/pci/hda/hda_proc.c
b/sound/pci/hda/hda_proc.c
index 1dd9dbeeef6e686cbce1055a9075e846ba89ea63..7e46258fc7002e24eeb1159e49b05d157a534995 100644
(file)
--- a/
sound/pci/hda/hda_proc.c
+++ b/
sound/pci/hda/hda_proc.c
@@
-451,7
+451,7
@@
static void print_power_state(struct snd_info_buffer *buffer,
int sup = snd_hda_param_read(codec, nid, AC_PAR_POWER_STATE);
int pwr = snd_hda_codec_read(codec, nid, 0,
AC_VERB_GET_POWER_STATE, 0);
- if (sup)
+ if (sup
!= -1
)
snd_iprintf(buffer, " Power states: %s\n",
bits_names(sup, names, ARRAY_SIZE(names)));