aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-shmobile/clock-r8a7740.c
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2012-05-06 21:12:41 -0400
committerRafael J. Wysocki <rjw@sisk.pl>2012-05-12 16:24:50 -0400
commitc8241085e8606a14ef48e6d99556133c48aaddaf (patch)
tree37bb00670ce883f1868dc688eb86086b89f95eca /arch/arm/mach-shmobile/clock-r8a7740.c
parentf2c2d7e9210c4a82336b208adc88630cd0e77f57 (diff)
ARM: mach-shmobile: clock-r8a7740: use followparent_recalc on usb24s
If the clocks is always same value as the parent clock, we can use followparent_recalc() for .recalc Reported-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Simon Horman <horms@verge.net.au> Acked-by: Magnus Damm <damm@opensource.se> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Diffstat (limited to 'arch/arm/mach-shmobile/clock-r8a7740.c')
-rw-r--r--arch/arm/mach-shmobile/clock-r8a7740.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/arch/arm/mach-shmobile/clock-r8a7740.c b/arch/arm/mach-shmobile/clock-r8a7740.c
index 89a2f9dad3b3..81b54a6af20f 100644
--- a/arch/arm/mach-shmobile/clock-r8a7740.c
+++ b/arch/arm/mach-shmobile/clock-r8a7740.c
@@ -188,11 +188,6 @@ static struct clk *usb24s_parents[] = {
188 [1] = &extal2_clk 188 [1] = &extal2_clk
189}; 189};
190 190
191static unsigned long usb24s_recalc(struct clk *clk)
192{
193 return clk->parent->rate;
194};
195
196static int usb24s_enable(struct clk *clk) 191static int usb24s_enable(struct clk *clk)
197{ 192{
198 __raw_writel(__raw_readl(USBCKCR) & ~(1 << 8), USBCKCR); 193 __raw_writel(__raw_readl(USBCKCR) & ~(1 << 8), USBCKCR);
@@ -234,7 +229,7 @@ static int usb24s_set_parent(struct clk *clk, struct clk *parent)
234} 229}
235 230
236static struct sh_clk_ops usb24s_clk_ops = { 231static struct sh_clk_ops usb24s_clk_ops = {
237 .recalc = usb24s_recalc, 232 .recalc = followparent_recalc,
238 .enable = usb24s_enable, 233 .enable = usb24s_enable,
239 .disable = usb24s_disable, 234 .disable = usb24s_disable,
240 .set_parent = usb24s_set_parent, 235 .set_parent = usb24s_set_parent,