[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.LNX.2.00.1204092243450.14420@swampdragon.chaosbits.net>
Date: Mon, 9 Apr 2012 22:52:19 +0200 (CEST)
From: Jesper Juhl <jj@...osbits.net>
To: linux-kernel@...r.kernel.org
cc: trivial@...nel.org, alsa-devel@...a-project.org,
Takashi Iwai <tiwai@...e.de>, Jaroslav Kysela <perex@...ex.cz>,
Liam Girdwood <lrg@...com>,
Dimitris Papastamos <dp@...nsource.wolfsonmicro.com>,
Ian Lartey <ian@...nsource.wolfsonmicro.com>,
Mark Brown <broonie@...nsource.wolfsonmicro.com>
Subject: [PATCH 24/26] ASoC: wm8994: Don't test for NULL before
release_firmware()
release_firmware() does its own NULL ptr testing, it's redundant to
also test before calling it.
Signed-off-by: Jesper Juhl <jj@...osbits.net>
---
sound/soc/codecs/wm8994.c | 12 ++++--------
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/sound/soc/codecs/wm8994.c b/sound/soc/codecs/wm8994.c
index 7c49642..cf7e5d2 100644
--- a/sound/soc/codecs/wm8994.c
+++ b/sound/soc/codecs/wm8994.c
@@ -3972,7 +3972,7 @@ err_irq:
return ret;
}
-static int wm8994_codec_remove(struct snd_soc_codec *codec)
+static int wm8994_codec_remove(struct snd_soc_codec *codec)
{
struct wm8994_priv *wm8994 = snd_soc_codec_get_drvdata(codec);
struct wm8994 *control = wm8994->wm8994;
@@ -4013,14 +4013,10 @@ static int wm8994_codec_remove(struct snd_soc_codec *codec)
free_irq(wm8994->micdet_irq, wm8994);
break;
}
- if (wm8994->mbc)
- release_firmware(wm8994->mbc);
- if (wm8994->mbc_vss)
- release_firmware(wm8994->mbc_vss);
- if (wm8994->enh_eq)
- release_firmware(wm8994->enh_eq);
+ release_firmware(wm8994->mbc);
+ release_firmware(wm8994->mbc_vss);
+ release_firmware(wm8994->enh_eq);
kfree(wm8994->retune_mobile_texts);
-
return 0;
}
--
1.7.10
--
Jesper Juhl <jj@...osbits.net> http://www.chaosbits.net/
Don't top-post http://www.catb.org/jargon/html/T/top-post.html
Plain text mails only, please.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists