Unverified Commit 3475b44c authored by Keyon Jie's avatar Keyon Jie Committed by Mark Brown
Browse files

ASoC: SOF: sof-pci-dev: add .shutdown() callback



Add the .shutdown() callback to the sof-pci-dev driver, to help to
handle shutting down specific tasks for SOF PCI platforms.

Signed-off-by: default avatarKeyon Jie <yang.jie@linux.intel.com>
Reviewed-by: default avatarBard Liao <bard.liao@intel.com>
Reviewed-by: default avatarRanjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: default avatarKai Vehmanen <kai.vehmanen@linux.intel.com>
Link: https://lore.kernel.org/r/20210113152617.4048541-3-kai.vehmanen@linux.intel.com


Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent daff7f14
Loading
Loading
Loading
Loading
+6 −0
Original line number Original line Diff line number Diff line
@@ -450,6 +450,11 @@ static void sof_pci_remove(struct pci_dev *pci)
	pci_release_regions(pci);
	pci_release_regions(pci);
}
}


static void sof_pci_shutdown(struct pci_dev *pci)
{
	snd_sof_device_shutdown(&pci->dev);
}

/* PCI IDs */
/* PCI IDs */
static const struct pci_device_id sof_pci_ids[] = {
static const struct pci_device_id sof_pci_ids[] = {
#if IS_ENABLED(CONFIG_SND_SOC_SOF_MERRIFIELD)
#if IS_ENABLED(CONFIG_SND_SOC_SOF_MERRIFIELD)
@@ -523,6 +528,7 @@ static struct pci_driver snd_sof_pci_driver = {
	.id_table = sof_pci_ids,
	.id_table = sof_pci_ids,
	.probe = sof_pci_probe,
	.probe = sof_pci_probe,
	.remove = sof_pci_remove,
	.remove = sof_pci_remove,
	.shutdown = sof_pci_shutdown,
	.driver = {
	.driver = {
		.pm = &sof_pci_pm,
		.pm = &sof_pci_pm,
	},
	},