aboutsummaryrefslogtreecommitdiff
path: root/sound/pci/hda/patch_sigmatel.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2013-01-11 17:40:31 +0100
committerTakashi Iwai <tiwai@suse.de>2013-01-12 08:44:47 +0100
commitbc759721fb44bc07e4f82445cc378a9d2724651f (patch)
tree6f096f37647a91f4cb5f6c4ceed9d07e08822682 /sound/pci/hda/patch_sigmatel.c
parent09b70e8509862debff5a033052f8adbd7402fa4e (diff)
ALSA: hda - Add snd_hda_get_int_hint() helper function
It'll be used in hda_generic.c, too. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/hda/patch_sigmatel.c')
-rw-r--r--sound/pci/hda/patch_sigmatel.c22
1 files changed, 4 insertions, 18 deletions
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c
index d3a81f10fe5..9cc4cb9b4bd 100644
--- a/sound/pci/hda/patch_sigmatel.c
+++ b/sound/pci/hda/patch_sigmatel.c
@@ -4295,24 +4295,10 @@ static void stac92xx_power_down(struct hda_codec *codec)
static void stac_toggle_power_map(struct hda_codec *codec, hda_nid_t nid,
int enable);
-static inline int get_int_hint(struct hda_codec *codec, const char *key,
- int *valp)
-{
-#ifdef CONFIG_SND_HDA_RECONFIG
- const char *p;
- mutex_lock(&codec->user_mutex);
- p = snd_hda_get_hint(codec, key);
- if (p) {
- unsigned long val;
- if (!strict_strtoul(p, 0, &val)) {
- *valp = val;
- mutex_unlock(&codec->user_mutex);
- return 1;
- }
- }
- mutex_unlock(&codec->user_mutex);
-#endif
- return 0;
+static inline bool get_int_hint(struct hda_codec *codec, const char *key,
+ int *valp)
+{
+ return !snd_hda_get_int_hint(codec, key, valp);
}
/* override some hints from the hwdep entry */