aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/serial/jsm/jsm_driver.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/serial/jsm/jsm_driver.c b/drivers/serial/jsm/jsm_driver.c
index eaf545014119..18f548449c63 100644
--- a/drivers/serial/jsm/jsm_driver.c
+++ b/drivers/serial/jsm/jsm_driver.c
@@ -172,13 +172,15 @@ static int __devinit jsm_probe_one(struct pci_dev *pdev, const struct pci_device
172 jsm_uart_port_init here! */ 172 jsm_uart_port_init here! */
173 dev_err(&pdev->dev, "memory allocation for flipbuf failed\n"); 173 dev_err(&pdev->dev, "memory allocation for flipbuf failed\n");
174 rc = -ENOMEM; 174 rc = -ENOMEM;
175 goto out_free_irq; 175 goto out_free_uart;
176 } 176 }
177 177
178 pci_set_drvdata(pdev, brd); 178 pci_set_drvdata(pdev, brd);
179 pci_save_state(pdev); 179 pci_save_state(pdev);
180 180
181 return 0; 181 return 0;
182 out_free_uart:
183 jsm_remove_uart_port(brd);
182 out_free_irq: 184 out_free_irq:
183 jsm_remove_uart_port(brd); 185 jsm_remove_uart_port(brd);
184 free_irq(brd->irq, brd); 186 free_irq(brd->irq, brd);