Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1227756
| From | Sudip Mukherjee <sudipm.mukherjee@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH 2/3] ASoC: wm0010: fix memory leak |
| Date | 2015-09-18 12:40 +0200 |
| Message-ID | <qa1fc-8td-23@gated-at.bofh.it> (permalink) |
| References | <qa1fc-8td-7@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
We have requested for the firmware but we have missed releasing it both
on success and on error path.
While checking the code it turned out that the requested firmware is not
even used. More over the same firmware is being loaded by
wm0010_stage2_load().
Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
---
sound/soc/codecs/wm0010.c | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/sound/soc/codecs/wm0010.c b/sound/soc/codecs/wm0010.c
index 79a7cd3..4947be5 100644
--- a/sound/soc/codecs/wm0010.c
+++ b/sound/soc/codecs/wm0010.c
@@ -577,7 +577,6 @@ static int wm0010_boot(struct snd_soc_codec *codec)
struct wm0010_priv *wm0010 = snd_soc_codec_get_drvdata(codec);
unsigned long flags;
int ret;
- const struct firmware *fw;
struct spi_message m;
struct spi_transfer t;
struct dfw_pllrec pll_rec;
@@ -623,14 +622,6 @@ static int wm0010_boot(struct snd_soc_codec *codec)
wm0010->state = WM0010_OUT_OF_RESET;
spin_unlock_irqrestore(&wm0010->irq_lock, flags);
- /* First the bootloader */
- ret = request_firmware(&fw, "wm0010_stage2.bin", codec->dev);
- if (ret != 0) {
- dev_err(codec->dev, "Failed to request stage2 loader: %d\n",
- ret);
- goto abort;
- }
-
if (!wait_for_completion_timeout(&wm0010->boot_completion,
msecs_to_jiffies(20)))
dev_err(codec->dev, "Failed to get interrupt from DSP\n");
--
1.9.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 1/3] ASoC: wm0010: disable regulator on error Sudip Mukherjee <sudipm.mukherjee@gmail.com> - 2015-09-18 12:40 +0200
[PATCH 2/3] ASoC: wm0010: fix memory leak Sudip Mukherjee <sudipm.mukherjee@gmail.com> - 2015-09-18 12:40 +0200
Re: [PATCH 2/3] ASoC: wm0010: fix memory leak Charles Keepax <ckeepax@opensource.wolfsonmicro.com> - 2015-09-18 14:10 +0200
[PATCH 3/3] ASoC: wm0010: fix error path Sudip Mukherjee <sudipm.mukherjee@gmail.com> - 2015-09-18 12:40 +0200
Re: [PATCH 3/3] ASoC: wm0010: fix error path Charles Keepax <ckeepax@opensource.wolfsonmicro.com> - 2015-09-18 14:10 +0200
Re: [PATCH 1/3] ASoC: wm0010: disable regulator on error Charles Keepax <ckeepax@opensource.wolfsonmicro.com> - 2015-09-18 14:00 +0200
Re: [PATCH 1/3] ASoC: wm0010: disable regulator on error Sudip Mukherjee <sudipm.mukherjee@gmail.com> - 2015-09-18 14:50 +0200
Re: [PATCH 1/3] ASoC: wm0010: disable regulator on error Charles Keepax <ckeepax@opensource.wolfsonmicro.com> - 2015-09-18 15:10 +0200
csiph-web