Commit 128ced8f authored by Wolfgang Grandegger's avatar Wolfgang Grandegger Committed by David S. Miller

can: some fixes and cleanups to the initial device driver interface

This patch fixes a few errors sneaked into the initial version of the
device driver interface.
Signed-off-by: default avatarWolfgang Grandegger <wg@grandegger.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 86d15cd8
...@@ -477,7 +477,7 @@ int open_candev(struct net_device *dev) ...@@ -477,7 +477,7 @@ int open_candev(struct net_device *dev)
return 0; return 0;
} }
EXPORT_SYMBOL(open_candev); EXPORT_SYMBOL_GPL(open_candev);
/* /*
* Common close function for cleanup before the device gets closed. * Common close function for cleanup before the device gets closed.
......
...@@ -218,14 +218,12 @@ static int __devinit ems_pci_add_card(struct pci_dev *pdev, ...@@ -218,14 +218,12 @@ static int __devinit ems_pci_add_card(struct pci_dev *pdev,
card->conf_addr = pci_iomap(pdev, 0, EMS_PCI_MEM_SIZE); card->conf_addr = pci_iomap(pdev, 0, EMS_PCI_MEM_SIZE);
if (card->conf_addr == NULL) { if (card->conf_addr == NULL) {
err = -ENOMEM; err = -ENOMEM;
goto failure_cleanup; goto failure_cleanup;
} }
card->base_addr = pci_iomap(pdev, 1, EMS_PCI_MEM_SIZE); card->base_addr = pci_iomap(pdev, 1, EMS_PCI_MEM_SIZE);
if (card->base_addr == NULL) { if (card->base_addr == NULL) {
err = -ENOMEM; err = -ENOMEM;
goto failure_cleanup; goto failure_cleanup;
} }
...@@ -239,7 +237,6 @@ static int __devinit ems_pci_add_card(struct pci_dev *pdev, ...@@ -239,7 +237,6 @@ static int __devinit ems_pci_add_card(struct pci_dev *pdev,
ems_pci_readb(card, 3) != 0xCB || ems_pci_readb(card, 3) != 0xCB ||
ems_pci_readb(card, 4) != 0x11) { ems_pci_readb(card, 4) != 0x11) {
dev_err(&pdev->dev, "Not EMS Dr. Thomas Wuensche interface\n"); dev_err(&pdev->dev, "Not EMS Dr. Thomas Wuensche interface\n");
err = -ENODEV; err = -ENODEV;
goto failure_cleanup; goto failure_cleanup;
} }
......
...@@ -532,8 +532,8 @@ static int sja1000_open(struct net_device *dev) ...@@ -532,8 +532,8 @@ static int sja1000_open(struct net_device *dev)
err = request_irq(dev->irq, &sja1000_interrupt, priv->irq_flags, err = request_irq(dev->irq, &sja1000_interrupt, priv->irq_flags,
dev->name, (void *)dev); dev->name, (void *)dev);
if (err) { if (err) {
return -EAGAIN;
close_candev(dev); close_candev(dev);
return -EAGAIN;
} }
} }
......
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