Skip to content

Commit 598b08b

Browse files
committed
Merge branch 'pci/switchtec'
- Fix error handling path in switchtec_pci_probe() (Christophe JAILLET) * pci/switchtec: PCI: switchtec: Fix an error handling path in switchtec_pci_probe()
2 parents 7dc249e + dec529b commit 598b08b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

drivers/pci/switch/switchtec.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1672,7 +1672,7 @@ static int switchtec_pci_probe(struct pci_dev *pdev,
16721672
rc = switchtec_init_isr(stdev);
16731673
if (rc) {
16741674
dev_err(&stdev->dev, "failed to init isr.\n");
1675-
goto err_put;
1675+
goto err_exit_pci;
16761676
}
16771677

16781678
iowrite32(SWITCHTEC_EVENT_CLEAR |
@@ -1693,6 +1693,8 @@ static int switchtec_pci_probe(struct pci_dev *pdev,
16931693

16941694
err_devadd:
16951695
stdev_kill(stdev);
1696+
err_exit_pci:
1697+
switchtec_exit_pci(stdev);
16961698
err_put:
16971699
ida_free(&switchtec_minor_ida, MINOR(stdev->dev.devt));
16981700
put_device(&stdev->dev);

0 commit comments

Comments
 (0)