summaryrefslogtreecommitdiff
path: root/sound/soc/sof/sof-pci-dev.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/sof/sof-pci-dev.c')
-rw-r--r--sound/soc/sof/sof-pci-dev.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sound/soc/sof/sof-pci-dev.c b/sound/soc/sof/sof-pci-dev.c
index 12f5cff22448..7fa2649e56e5 100644
--- a/sound/soc/sof/sof-pci-dev.c
+++ b/sound/soc/sof/sof-pci-dev.c
@@ -153,6 +153,11 @@ int sof_pci_probe(struct pci_dev *pci, const struct pci_device_id *pci_id)
dev_dbg(&pci->dev, "PCI DSP detected");
+ if (!desc) {
+ dev_err(dev, "error: no matching PCI descriptor\n");
+ return -ENODEV;
+ }
+
if (!desc->ops) {
dev_err(dev, "error: no matching PCI descriptor ops\n");
return -ENODEV;