summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLukas Wunner2016-10-20 12:26:16 +0200
committerMark Brown2016-10-24 18:50:53 +0200
commit6d13f62d931ba638e54ba56f3a7dd3080ffb485a (patch)
tree74a3733042ed5fc08f2147e0bef0fa758592cd7a
parentASoC: Intel: Atom: add terminate entry for dmi_system_id tables (diff)
downloadkernel-qcow2-linux-6d13f62d931ba638e54ba56f3a7dd3080ffb485a.tar.gz
kernel-qcow2-linux-6d13f62d931ba638e54ba56f3a7dd3080ffb485a.tar.xz
kernel-qcow2-linux-6d13f62d931ba638e54ba56f3a7dd3080ffb485a.zip
ASoC: Intel: Skylake: Always acquire runtime pm ref on unload
skl_probe() releases a runtime pm ref unconditionally wheras skl_remove() acquires one only if the device is wakeup capable. Thus if the device is not wakeup capable, unloading and reloading the module will result in the refcount being decreased below 0. Fix it. Fixes: d8c2dab8381d ("ASoC: Intel: Add Skylake HDA audio driver") Signed-off-by: Lukas Wunner <lukas@wunner.de> Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r--sound/soc/intel/skylake/skl.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sound/soc/intel/skylake/skl.c b/sound/soc/intel/skylake/skl.c
index e3e764167765..7b7a380b1245 100644
--- a/sound/soc/intel/skylake/skl.c
+++ b/sound/soc/intel/skylake/skl.c
@@ -785,8 +785,7 @@ static void skl_remove(struct pci_dev *pci)
release_firmware(skl->tplg);
- if (pci_dev_run_wake(pci))
- pm_runtime_get_noresume(&pci->dev);
+ pm_runtime_get_noresume(&pci->dev);
/* codec removal, invoke bus_device_remove */
snd_hdac_ext_bus_device_remove(ebus);