diff options
author | Mark Brown <broonie@kernel.org> | 2016-01-05 18:07:33 -0500 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2016-01-05 18:07:33 -0500 |
commit | bc42f363da213b4bf7c15a2dc87b2b1a85cde867 (patch) | |
tree | 9d004dc4c3e35f07f6a8df1b83ea6bf6be8a373e | |
parent | 84a5347b89690aae2c9d08f64219d71108c70011 (diff) | |
parent | d8018361b58bb7b9a2a657104e54c33c2ef1439d (diff) |
Merge remote-tracking branch 'asoc/fix/intel' into asoc-linus
-rw-r--r-- | sound/soc/intel/skylake/skl-topology.c | 3 | ||||
-rw-r--r-- | sound/soc/intel/skylake/skl.c | 4 | ||||
-rw-r--r-- | sound/soc/intel/skylake/skl.h | 2 |
3 files changed, 8 insertions, 1 deletions
diff --git a/sound/soc/intel/skylake/skl-topology.c b/sound/soc/intel/skylake/skl-topology.c index ffea427aeca8..ad4d0f82603e 100644 --- a/sound/soc/intel/skylake/skl-topology.c +++ b/sound/soc/intel/skylake/skl-topology.c | |||
@@ -1240,7 +1240,6 @@ int skl_tplg_init(struct snd_soc_platform *platform, struct hdac_ext_bus *ebus) | |||
1240 | */ | 1240 | */ |
1241 | ret = snd_soc_tplg_component_load(&platform->component, | 1241 | ret = snd_soc_tplg_component_load(&platform->component, |
1242 | &skl_tplg_ops, fw, 0); | 1242 | &skl_tplg_ops, fw, 0); |
1243 | release_firmware(fw); | ||
1244 | if (ret < 0) { | 1243 | if (ret < 0) { |
1245 | dev_err(bus->dev, "tplg component load failed%d\n", ret); | 1244 | dev_err(bus->dev, "tplg component load failed%d\n", ret); |
1246 | return -EINVAL; | 1245 | return -EINVAL; |
@@ -1249,5 +1248,7 @@ int skl_tplg_init(struct snd_soc_platform *platform, struct hdac_ext_bus *ebus) | |||
1249 | skl->resource.max_mcps = SKL_MAX_MCPS; | 1248 | skl->resource.max_mcps = SKL_MAX_MCPS; |
1250 | skl->resource.max_mem = SKL_FW_MAX_MEM; | 1249 | skl->resource.max_mem = SKL_FW_MAX_MEM; |
1251 | 1250 | ||
1251 | skl->tplg = fw; | ||
1252 | |||
1252 | return 0; | 1253 | return 0; |
1253 | } | 1254 | } |
diff --git a/sound/soc/intel/skylake/skl.c b/sound/soc/intel/skylake/skl.c index 5319529aedf7..caa69c4598a6 100644 --- a/sound/soc/intel/skylake/skl.c +++ b/sound/soc/intel/skylake/skl.c | |||
@@ -25,6 +25,7 @@ | |||
25 | #include <linux/pci.h> | 25 | #include <linux/pci.h> |
26 | #include <linux/pm_runtime.h> | 26 | #include <linux/pm_runtime.h> |
27 | #include <linux/platform_device.h> | 27 | #include <linux/platform_device.h> |
28 | #include <linux/firmware.h> | ||
28 | #include <sound/pcm.h> | 29 | #include <sound/pcm.h> |
29 | #include "skl.h" | 30 | #include "skl.h" |
30 | 31 | ||
@@ -520,6 +521,9 @@ static void skl_remove(struct pci_dev *pci) | |||
520 | struct hdac_ext_bus *ebus = pci_get_drvdata(pci); | 521 | struct hdac_ext_bus *ebus = pci_get_drvdata(pci); |
521 | struct skl *skl = ebus_to_skl(ebus); | 522 | struct skl *skl = ebus_to_skl(ebus); |
522 | 523 | ||
524 | if (skl->tplg) | ||
525 | release_firmware(skl->tplg); | ||
526 | |||
523 | if (pci_dev_run_wake(pci)) | 527 | if (pci_dev_run_wake(pci)) |
524 | pm_runtime_get_noresume(&pci->dev); | 528 | pm_runtime_get_noresume(&pci->dev); |
525 | pci_dev_put(pci); | 529 | pci_dev_put(pci); |
diff --git a/sound/soc/intel/skylake/skl.h b/sound/soc/intel/skylake/skl.h index dd2e79ae45a8..a0709e344d44 100644 --- a/sound/soc/intel/skylake/skl.h +++ b/sound/soc/intel/skylake/skl.h | |||
@@ -68,6 +68,8 @@ struct skl { | |||
68 | struct skl_dsp_resource resource; | 68 | struct skl_dsp_resource resource; |
69 | struct list_head ppl_list; | 69 | struct list_head ppl_list; |
70 | struct list_head dapm_path_list; | 70 | struct list_head dapm_path_list; |
71 | |||
72 | const struct firmware *tplg; | ||
71 | }; | 73 | }; |
72 | 74 | ||
73 | #define skl_to_ebus(s) (&(s)->ebus) | 75 | #define skl_to_ebus(s) (&(s)->ebus) |