Commit 6a4ce20f authored by Yang Yingliang's avatar Yang Yingliang Committed by Mark Brown

ASoC: amd: acp: add missing platform_device_unregister() in acp_pci_probe()

Add missing platform_device_unregister() in error path in acp_pci_probe().

Fixes: c49f5e74 ("ASoC: amd: acp: Add error handling cases")
Signed-off-by: default avatarYang Yingliang <yangyingliang@huawei.com>
Link: https://lore.kernel.org/r/20220819073758.1273160-1-yangyingliang@huawei.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent fb5319af
......@@ -104,6 +104,7 @@ static int acp_pci_probe(struct pci_dev *pci, const struct pci_device_id *pci_id
addr = pci_resource_start(pci, 0);
chip->base = devm_ioremap(&pci->dev, addr, pci_resource_len(pci, 0));
if (!chip->base) {
platform_device_unregister(dmic_dev);
ret = -ENOMEM;
goto release_regions;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment