diff options
Diffstat (limited to 'drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c')
-rw-r--r-- | drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c index 1f069b0f6af5..19b3a2567a46 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_pci.c @@ -61,8 +61,8 @@ static void stmmac_default_data(void) * matches the device. The probe functions returns zero when the driver choose * to take "ownership" of the device or an error code(-ve no) otherwise. */ -static int __devinit stmmac_pci_probe(struct pci_dev *pdev, - const struct pci_device_id *id) +static int stmmac_pci_probe(struct pci_dev *pdev, + const struct pci_device_id *id) { int ret = 0; void __iomem *addr = NULL; @@ -102,6 +102,7 @@ static int __devinit stmmac_pci_probe(struct pci_dev *pdev, priv = stmmac_dvr_probe(&(pdev->dev), &plat_dat, addr); if (!priv) { pr_err("%s: main driver probe failed", __func__); + ret = -ENODEV; goto err_out; } priv->dev->irq = pdev->irq; @@ -130,7 +131,7 @@ err_out_req_reg_failed: * Description: this function calls the main to free the net resources * and releases the PCI resources. */ -static void __devexit stmmac_pci_remove(struct pci_dev *pdev) +static void stmmac_pci_remove(struct pci_dev *pdev) { struct net_device *ndev = pci_get_drvdata(pdev); struct stmmac_priv *priv = netdev_priv(ndev); @@ -182,7 +183,7 @@ struct pci_driver stmmac_pci_driver = { .name = STMMAC_RESOURCE_NAME, .id_table = stmmac_id_table, .probe = stmmac_pci_probe, - .remove = __devexit_p(stmmac_pci_remove), + .remove = stmmac_pci_remove, #ifdef CONFIG_PM .suspend = stmmac_pci_suspend, .resume = stmmac_pci_resume, |