[alsa-devel] [PATCH] ASoC: Intel: fix Coccinelle kfree warning
Firo Yang
firogm at gmail.com
Sun Apr 26 17:42:12 CEST 2015
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 at 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
More information about the Alsa-devel
mailing list