aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/irda
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/irda')
-rw-r--r--drivers/net/irda/pxaficp_ir.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/net/irda/pxaficp_ir.c b/drivers/net/irda/pxaficp_ir.c
index 8239c520f1ef..8db71ab20456 100644
--- a/drivers/net/irda/pxaficp_ir.c
+++ b/drivers/net/irda/pxaficp_ir.c
@@ -832,6 +832,11 @@ static int pxa_irda_probe(struct platform_device *pdev)
832 if (err) 832 if (err)
833 goto err_mem_5; 833 goto err_mem_5;
834 834
835 if (si->pdata->startup)
836 err = si->pdata->startup(si->dev);
837 if (err)
838 goto err_startup;
839
835 dev->hard_start_xmit = pxa_irda_hard_xmit; 840 dev->hard_start_xmit = pxa_irda_hard_xmit;
836 dev->open = pxa_irda_start; 841 dev->open = pxa_irda_start;
837 dev->stop = pxa_irda_stop; 842 dev->stop = pxa_irda_stop;
@@ -857,6 +862,9 @@ static int pxa_irda_probe(struct platform_device *pdev)
857 dev_set_drvdata(&pdev->dev, dev); 862 dev_set_drvdata(&pdev->dev, dev);
858 863
859 if (err) { 864 if (err) {
865 if (si->pdata->shutdown)
866 si->pdata->shutdown(si->dev);
867err_startup:
860 kfree(si->tx_buff.head); 868 kfree(si->tx_buff.head);
861err_mem_5: 869err_mem_5:
862 kfree(si->rx_buff.head); 870 kfree(si->rx_buff.head);
@@ -882,6 +890,8 @@ static int pxa_irda_remove(struct platform_device *_dev)
882 if (dev) { 890 if (dev) {
883 struct pxa_irda *si = netdev_priv(dev); 891 struct pxa_irda *si = netdev_priv(dev);
884 unregister_netdev(dev); 892 unregister_netdev(dev);
893 if (si->pdata->shutdown)
894 si->pdata->shutdown(si->dev);
885 kfree(si->tx_buff.head); 895 kfree(si->tx_buff.head);
886 kfree(si->rx_buff.head); 896 kfree(si->rx_buff.head);
887 clk_put(si->fir_clk); 897 clk_put(si->fir_clk);