aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/can
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/can')
-rw-r--r--drivers/net/can/flexcan.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/net/can/flexcan.c b/drivers/net/can/flexcan.c
index 165a4c798025..7fd8089946fb 100644
--- a/drivers/net/can/flexcan.c
+++ b/drivers/net/can/flexcan.c
@@ -802,7 +802,7 @@ static int flexcan_open(struct net_device *dev)
802 struct flexcan_priv *priv = netdev_priv(dev); 802 struct flexcan_priv *priv = netdev_priv(dev);
803 int err; 803 int err;
804 804
805 clk_enable(priv->clk); 805 clk_prepare_enable(priv->clk);
806 806
807 err = open_candev(dev); 807 err = open_candev(dev);
808 if (err) 808 if (err)
@@ -824,7 +824,7 @@ static int flexcan_open(struct net_device *dev)
824 out_close: 824 out_close:
825 close_candev(dev); 825 close_candev(dev);
826 out: 826 out:
827 clk_disable(priv->clk); 827 clk_disable_unprepare(priv->clk);
828 828
829 return err; 829 return err;
830} 830}
@@ -838,7 +838,7 @@ static int flexcan_close(struct net_device *dev)
838 flexcan_chip_stop(dev); 838 flexcan_chip_stop(dev);
839 839
840 free_irq(dev->irq, dev); 840 free_irq(dev->irq, dev);
841 clk_disable(priv->clk); 841 clk_disable_unprepare(priv->clk);
842 842
843 close_candev(dev); 843 close_candev(dev);
844 844
@@ -877,7 +877,7 @@ static int __devinit register_flexcandev(struct net_device *dev)
877 struct flexcan_regs __iomem *regs = priv->base; 877 struct flexcan_regs __iomem *regs = priv->base;
878 u32 reg, err; 878 u32 reg, err;
879 879
880 clk_enable(priv->clk); 880 clk_prepare_enable(priv->clk);
881 881
882 /* select "bus clock", chip must be disabled */ 882 /* select "bus clock", chip must be disabled */
883 flexcan_chip_disable(priv); 883 flexcan_chip_disable(priv);
@@ -911,7 +911,7 @@ static int __devinit register_flexcandev(struct net_device *dev)
911 out: 911 out:
912 /* disable core and turn off clocks */ 912 /* disable core and turn off clocks */
913 flexcan_chip_disable(priv); 913 flexcan_chip_disable(priv);
914 clk_disable(priv->clk); 914 clk_disable_unprepare(priv->clk);
915 915
916 return err; 916 return err;
917} 917}