Skip to content

Commit

Permalink
ALSA: hda/ca0132 - Check download state of DSP.
Browse files Browse the repository at this point in the history
Instead of using the dspload_is_loaded() function, check the dsp_state
that is kept in the spec.  The dspload_is_loaded() function returns
true if the DSP transfer was never started.  This false-positive leads
to multiple second delays when ca0132_setup_efaults() times out on
each write.

Signed-off-by: Dylan Reid <[email protected]>
Signed-off-by: Takashi Iwai <[email protected]>
  • Loading branch information
dgreid authored and tiwai committed Mar 15, 2013
1 parent d1d2850 commit e8f1bd5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions sound/pci/hda/patch_ca0132.c
Original file line number Diff line number Diff line change
Expand Up @@ -3239,7 +3239,7 @@ static int ca0132_set_vipsource(struct hda_codec *codec, int val)
struct ca0132_spec *spec = codec->spec;
unsigned int tmp;

if (!dspload_is_loaded(codec))
if (spec->dsp_state != DSP_DOWNLOADED)
return 0;

/* if CrystalVoice if off, vipsource should be 0 */
Expand Down Expand Up @@ -4267,11 +4267,12 @@ static void ca0132_refresh_widget_caps(struct hda_codec *codec)
*/
static void ca0132_setup_defaults(struct hda_codec *codec)
{
struct ca0132_spec *spec = codec->spec;
unsigned int tmp;
int num_fx;
int idx, i;

if (!dspload_is_loaded(codec))
if (spec->dsp_state != DSP_DOWNLOADED)
return;

/* out, in effects + voicefx */
Expand Down

0 comments on commit e8f1bd5

Please sign in to comment.