summaryrefslogtreecommitdiff
path: root/arch/arm/mach-s3c24xx/common.c
diff options
context:
space:
mode:
authorHeiko Stuebner <heiko@sntech.de>2014-05-09 05:49:14 +0900
committerKukjin Kim <kgene.kim@samsung.com>2014-05-13 08:00:42 +0900
commit4659c534834c33c698c9400e0aedd1e1aa48e9b6 (patch)
treebef32de3643870153f26f89b616b19fc69af0e02 /arch/arm/mach-s3c24xx/common.c
parent3f7c01ade226e7006d76e42f8c9b99ada7085312 (diff)
ARM: S3C24XX: add platform code for conversion to the common clock framework
This adds the necessary init functions to init the clocks from the common clock framework and necessary CONFIG_SAMSUNG_CLOCK ifdefs around the legacy clock code. This also includes empty stubs for the *_setup_clocks functions that are called from the cpufreq driver on resume. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Reviewed-by: Tomasz Figa <t.figa@samsung.com> Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Diffstat (limited to 'arch/arm/mach-s3c24xx/common.c')
-rw-r--r--arch/arm/mach-s3c24xx/common.c25
1 files changed, 25 insertions, 0 deletions
diff --git a/arch/arm/mach-s3c24xx/common.c b/arch/arm/mach-s3c24xx/common.c
index 7cc6d944c820..35cf88e1fa83 100644
--- a/arch/arm/mach-s3c24xx/common.c
+++ b/arch/arm/mach-s3c24xx/common.c
@@ -53,6 +53,7 @@
#include <plat/cpu-freq.h>
#include <plat/pll.h>
#include <plat/pwm-core.h>
+#include <plat/watchdog-reset.h>
#include "common.h"
@@ -533,6 +534,14 @@ struct platform_device s3c2443_device_dma = {
};
#endif
+#if defined(CONFIG_COMMON_CLK) && defined(CONFIG_CPU_S3C2410)
+void __init s3c2410_init_clocks(int xtal)
+{
+ s3c2410_common_clk_init(NULL, xtal, 0, S3C24XX_VA_CLKPWR);
+ samsung_wdt_reset_init(S3C24XX_VA_WATCHDOG);
+}
+#endif
+
#ifdef CONFIG_CPU_S3C2412
void __init s3c2412_init_clocks(int xtal)
{
@@ -547,6 +556,22 @@ void __init s3c2416_init_clocks(int xtal)
}
#endif
+#if defined(CONFIG_COMMON_CLK) && defined(CONFIG_CPU_S3C2440)
+void __init s3c2440_init_clocks(int xtal)
+{
+ s3c2410_common_clk_init(NULL, xtal, 1, S3C24XX_VA_CLKPWR);
+ samsung_wdt_reset_init(S3C24XX_VA_WATCHDOG);
+}
+#endif
+
+#if defined(CONFIG_COMMON_CLK) && defined(CONFIG_CPU_S3C2442)
+void __init s3c2442_init_clocks(int xtal)
+{
+ s3c2410_common_clk_init(NULL, xtal, 2, S3C24XX_VA_CLKPWR);
+ samsung_wdt_reset_init(S3C24XX_VA_WATCHDOG);
+}
+#endif
+
#ifdef CONFIG_CPU_S3C2443
void __init s3c2443_init_clocks(int xtal)
{