aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/hda/hda_codec.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/pci/hda/hda_codec.c')
-rw-r--r--sound/pci/hda/hda_codec.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
index aa0e1c18b606..562403a23488 100644
--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -214,11 +214,6 @@ unsigned int snd_hda_codec_read(struct hda_codec *codec, hda_nid_t nid,
214} 214}
215EXPORT_SYMBOL_HDA(snd_hda_codec_read); 215EXPORT_SYMBOL_HDA(snd_hda_codec_read);
216 216
217/* Define the below to send and receive verbs synchronously.
218 * If you often get any codec communication errors, this is worth to try.
219 */
220/* #define SND_HDA_SUPPORT_SYNC_WRITE */
221
222/** 217/**
223 * snd_hda_codec_write - send a single command without waiting for response 218 * snd_hda_codec_write - send a single command without waiting for response
224 * @codec: the HDA codec 219 * @codec: the HDA codec
@@ -235,12 +230,9 @@ int snd_hda_codec_write(struct hda_codec *codec, hda_nid_t nid, int direct,
235 unsigned int verb, unsigned int parm) 230 unsigned int verb, unsigned int parm)
236{ 231{
237 unsigned int cmd = make_codec_cmd(codec, nid, direct, verb, parm); 232 unsigned int cmd = make_codec_cmd(codec, nid, direct, verb, parm);
238#ifdef SND_HDA_SUPPORT_SYNC_WRITE
239 unsigned int res; 233 unsigned int res;
240 return codec_exec_verb(codec, cmd, &res); 234 return codec_exec_verb(codec, cmd,
241#else 235 codec->bus->sync_write ? &res : NULL);
242 return codec_exec_verb(codec, cmd, NULL);
243#endif
244} 236}
245EXPORT_SYMBOL_HDA(snd_hda_codec_write); 237EXPORT_SYMBOL_HDA(snd_hda_codec_write);
246 238