Commit Graph

9 Commits

Author SHA1 Message Date
Amit Kucheria 9b839ec0a8 arm: mxc: utilise usecount field in clock operations
This patch fixes the clock refcounting when reparenting is used.

Boot-tested on imx51 babbage board.

Sascha pointed out a good explanation of refcounting here:
http://www.spinics.net/lists/arm-kernel/msg85879.html

Signed-off-by: Amit Kucheria <amit.kucheria@canonical.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-07-26 14:17:57 +02:00
Uwe Kleine-König 8ac5b7c5ec imx: WARN in clk_disable if the clock isn't enabled
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Cc: Sascha Hauer <kernel@pengutronix.de>
Cc: Russell King <linux@arm.linux.org.uk>
2010-02-02 09:07:11 +01:00
Sascha Hauer 5e63ff9a97 [ARM] MXC: remove the now unused #ifndef CONFIG_COMMON_CLKDEV
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-08-07 12:11:11 +02:00
Sascha Hauer 6d73665f05 MXC PLL decoding: calculate mfn value with less magic
Also, use cpu_is_* macros rather than CONFIG_ARCH_*

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-08-07 12:11:10 +02:00
Sascha Hauer d1755e3592 [ARM] MXC: add clkdev support
This patch only adds general clkdev support without actually switching
any MXC architecture to clkdev.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-03-13 10:33:50 +01:00
Sascha Hauer a2865197a5 [ARM] MXC: Use a single function for decoding a PLL
We had 3 versions of this function in clock support for MX1/2/3
Use a single one instead. I picked the one from the MX3 as it seems
to calculate more accurate as the other ones. Also, on MX27 and MX31 mfn
can be negative, this hasn't been handled correctly on MX27 since now.

This patch has been tested on MX27 and MX31 and produces the same clock
frequencies for me.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-03-13 10:33:46 +01:00
Huang Weiyi 8b540fdcb7 [ARM] remove unused #include <version.h>
The driver(s) below do not use LINUX_VERSION_CODE nor KERNEL_VERSION.
  arch/arm/plat-mxc/clock.c

This patch removes the said #include <version.h>.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-04 10:47:14 +01:00
Russell King a09e64fbc0 [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach
This just leaves include/asm-arm/plat-* to deal with.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-07 09:55:48 +01:00
Juergen Beisert c0db2ea4e3 MXC family: Add clock handling
Internal clock path handling for the mxc CPUs.

Changed against the original Freescale code (and against clocklib for example):
 - clock rate is always calculated whenever one ask for the current rate
   (means struct clk has no more a member called "rate"). So switching the PLL
   base frequency will propagate immediately to all other clocks that are
   depending on this frequency.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:02:47 +02:00