USB: ehci: ohci: Add clk_{un}prepare() support
authorViresh Kumar <viresh.kumar@st.com>
Tue, 17 Apr 2012 11:38:50 +0000 (17:08 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 18 Apr 2012 21:33:43 +0000 (14:33 -0700)
clk_{un}prepare is mandatory for platforms using common clock framework. Since
these drivers are used by SPEAr platform, which supports common clock framework,
add clk_{un}prepare() support for them.

Signed-off-by: Viresh Kumar <viresh.kumar@st.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/host/ehci-spear.c
drivers/usb/host/ohci-spear.c

index 2e3c89a96650931fb3dce6b68c54d409f9c871a6..37ba8c8d2fd06b05daa2e969a349a139305916f4 100644 (file)
@@ -26,12 +26,12 @@ struct spear_ehci {
 
 static void spear_start_ehci(struct spear_ehci *ehci)
 {
-       clk_enable(ehci->clk);
+       clk_prepare_enable(ehci->clk);
 }
 
 static void spear_stop_ehci(struct spear_ehci *ehci)
 {
-       clk_disable(ehci->clk);
+       clk_disable_unprepare(ehci->clk);
 }
 
 static int ehci_spear_setup(struct usb_hcd *hcd)
index eb4640b1e4028b1967f2c3d986d21c2739544691..fc7305ee3c9cd465ecdb68c64b140e9f9da10fc9 100644 (file)
@@ -25,12 +25,12 @@ struct spear_ohci {
 
 static void spear_start_ohci(struct spear_ohci *ohci)
 {
-       clk_enable(ohci->clk);
+       clk_prepare_enable(ohci->clk);
 }
 
 static void spear_stop_ohci(struct spear_ohci *ohci)
 {
-       clk_disable(ohci->clk);
+       clk_disable_unprepare(ohci->clk);
 }
 
 static int __devinit ohci_spear_start(struct usb_hcd *hcd)