summaryrefslogtreecommitdiffstats
path: root/sound/pci/hda/patch_realtek.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2010-09-21 09:57:06 +0200
committerTakashi Iwai <tiwai@suse.de>2010-09-21 10:00:03 +0200
commit9e5341b92d1d2dde11691b394721b45b36416bef (patch)
tree987a81df30cec229d2af12f87c4b572ded04095d /sound/pci/hda/patch_realtek.c
parent9396d3174b761685d6fefb1103e66b96a2e5db6d (diff)
downloadop-kernel-dev-9e5341b92d1d2dde11691b394721b45b36416bef.zip
op-kernel-dev-9e5341b92d1d2dde11691b394721b45b36416bef.tar.gz
ALSA: hda - Introduce hda_call_check_power_status() helper
Replace the explicit ifdef check and call of check_power_status ops with a new helper function, hda_call_check_power_status(). Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/hda/patch_realtek.c')
-rw-r--r--sound/pci/hda/patch_realtek.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index 8689216..9bedca0 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -3729,10 +3729,7 @@ static int alc_init(struct hda_codec *codec)
if (spec->init_hook)
spec->init_hook(codec);
-#ifdef CONFIG_SND_HDA_POWER_SAVE
- if (codec->patch_ops.check_power_status)
- codec->patch_ops.check_power_status(codec, 0x01);
-#endif
+ hda_call_check_power_status(codec, 0x01);
return 0;
}
@@ -4128,8 +4125,7 @@ static int alc_resume(struct hda_codec *codec)
codec->patch_ops.init(codec);
snd_hda_codec_resume_amp(codec);
snd_hda_codec_resume_cache(codec);
- if (codec->patch_ops.check_power_status)
- codec->patch_ops.check_power_status(codec, 0x01);
+ hda_call_check_power_status(codec, 0x01);
return 0;
}
#endif
@@ -14703,8 +14699,7 @@ static int alc269_resume(struct hda_codec *codec)
snd_hda_codec_resume_amp(codec);
snd_hda_codec_resume_cache(codec);
- if (codec->patch_ops.check_power_status)
- codec->patch_ops.check_power_status(codec, 0x01);
+ hda_call_check_power_status(codec, 0x01);
return 0;
}
#endif /* SND_HDA_NEEDS_RESUME */
OpenPOWER on IntegriCloud