All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ASoC: Intel: fix Coccinelle kfree warning
@ 2015-04-26 15:42 ` Firo Yang
  0 siblings, 0 replies; 8+ messages in thread
From: Firo Yang @ 2015-04-26 15:42 UTC (permalink / raw)
  To: lgirdwood
  Cc: kernel-janitors, broonie, perex, tiwai, yang.jie, han.lu,
	jarkko.nikula, pawel.piskorski, alsa-devel, Firo Yang

It's not necessary to use kfree() to free memory allocated with
devm_kzalloc in a probe function and using kfree leads to a double free.

Signed-off-by: Firo Yang <firogm@gmail.com>
---
 sound/soc/intel/haswell/sst-haswell-ipc.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/sound/soc/intel/haswell/sst-haswell-ipc.c b/sound/soc/intel/haswell/sst-haswell-ipc.c
index 344a1e9..324eceb 100644
--- a/sound/soc/intel/haswell/sst-haswell-ipc.c
+++ b/sound/soc/intel/haswell/sst-haswell-ipc.c
@@ -2201,7 +2201,6 @@ dma_err:
 dsp_new_err:
 	sst_ipc_fini(ipc);
 ipc_init_err:
-	kfree(hsw);
 	return ret;
 }
 EXPORT_SYMBOL_GPL(sst_hsw_dsp_init);
-- 
2.1.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2015-04-27  7:52 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-04-26 15:42 [PATCH] ASoC: Intel: fix Coccinelle kfree warning Firo Yang
2015-04-26 15:42 ` Firo Yang
2015-04-27  7:23 ` Jie, Yang
2015-04-27  7:23   ` Jie, Yang
2015-04-27  7:42   ` Firo Yang
2015-04-27  7:42     ` Firo Yang
2015-04-27  7:52     ` Jie, Yang
2015-04-27  7:52       ` Jie, Yang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.