ASoC: Intel: Skylake: fix memory leak
authorSudip Mukherjee <sudipm.mukherjee@gmail.com>
Mon, 23 Nov 2015 11:08:48 +0000 (16:38 +0530)
committerMark Brown <broonie@kernel.org>
Mon, 23 Nov 2015 11:29:12 +0000 (11:29 +0000)
We have requested the firmware but missed releasing it.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/intel/skylake/skl-topology.c

index a7854c8fc523e832f6137437c6e7737cc5eee46c..ffea427aeca8eab29809f049c53ba27f71b54393 100644 (file)
@@ -1240,6 +1240,7 @@ int skl_tplg_init(struct snd_soc_platform *platform, struct hdac_ext_bus *ebus)
         */
        ret = snd_soc_tplg_component_load(&platform->component,
                                        &skl_tplg_ops, fw, 0);
+       release_firmware(fw);
        if (ret < 0) {
                dev_err(bus->dev, "tplg component load failed%d\n", ret);
                return -EINVAL;