diff options
author | Takashi Iwai <tiwai@suse.de> | 2013-11-05 12:39:52 -0500 |
---|---|---|
committer | Mark Brown <broonie@linaro.org> | 2013-11-06 05:26:21 -0500 |
commit | f5b3a563943f415b99823be9918119f07337e328 (patch) | |
tree | d603f0cd734a68bc9e4c4ecf9260fa30ca366f6f /sound/soc | |
parent | 773392b25ce1e5d99c72fcc227bb53ba358497be (diff) |
ASoC: wm0010: Use WARN_ON() instead of BUG_ON()
Use WARN_ON() and handle the error cases accordingly.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'sound/soc')
-rw-r--r-- | sound/soc/codecs/wm0010.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sound/soc/codecs/wm0010.c b/sound/soc/codecs/wm0010.c index d5ebcb00019b..aea916431227 100644 --- a/sound/soc/codecs/wm0010.c +++ b/sound/soc/codecs/wm0010.c | |||
@@ -372,7 +372,8 @@ static int wm0010_firmware_load(const char *name, struct snd_soc_codec *codec) | |||
372 | offset = 0; | 372 | offset = 0; |
373 | dsp = inforec->dsp_target; | 373 | dsp = inforec->dsp_target; |
374 | wm0010->boot_failed = false; | 374 | wm0010->boot_failed = false; |
375 | BUG_ON(!list_empty(&xfer_list)); | 375 | if (WARN_ON(!list_empty(&xfer_list))) |
376 | return -EINVAL; | ||
376 | init_completion(&done); | 377 | init_completion(&done); |
377 | 378 | ||
378 | /* First record should be INFO */ | 379 | /* First record should be INFO */ |