summaryrefslogtreecommitdiff
path: root/arch/arm/plat-s3c24xx/include/plat
diff options
context:
space:
mode:
authorBen Dooks <ben-linux@fluff.org>2010-04-28 13:03:57 +0400
committerBen Dooks <ben-linux@fluff.org>2010-05-10 06:44:42 +0400
commitaf337f3e633a198034a99450416257ddf2307497 (patch)
treee5e308a4373f4981fc0c5a6361402f29644c677d /arch/arm/plat-s3c24xx/include/plat
parentd11a7d7100123d178821f82ecc11ba2d9d6e97c8 (diff)
downloadlinux-af337f3e633a198034a99450416257ddf2307497.tar.xz
ARM: S3C2443: Move parts of the clock code to common clock file
To share code with some of the newer parts such as the S3C2416, move parts of arch/arm/mach-s3c2443/clock.c to a common file called arch/arm/plat-s3c24xx/s3c2443-clock.c. Update the build configuration to deal with this new file. Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Diffstat (limited to 'arch/arm/plat-s3c24xx/include/plat')
-rw-r--r--arch/arm/plat-s3c24xx/include/plat/s3c2443.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/arch/arm/plat-s3c24xx/include/plat/s3c2443.h b/arch/arm/plat-s3c24xx/include/plat/s3c2443.h
index 815b107ed890..a19715feb798 100644
--- a/arch/arm/plat-s3c24xx/include/plat/s3c2443.h
+++ b/arch/arm/plat-s3c24xx/include/plat/s3c2443.h
@@ -30,3 +30,22 @@ extern int s3c2443_baseclk_add(void);
#define s3c2443_map_io NULL
#define s3c2443_init NULL
#endif
+
+/* common code used by s3c2443 and others.
+ * note, not to be used outside of arch/arm/mach-s3c* */
+
+struct clk; /* some files don't need clk.h otherwise */
+
+typedef unsigned int (*pll_fn)(unsigned int reg, unsigned int base);
+typedef unsigned int (*fdiv_fn)(unsigned long clkcon0);
+
+extern void s3c2443_common_setup_clocks(pll_fn get_mpll, fdiv_fn fdiv);
+extern void s3c2443_common_init_clocks(int xtal, pll_fn get_mpll, fdiv_fn fdiv);
+
+extern int s3c2443_clkcon_enable_h(struct clk *clk, int enable);
+extern int s3c2443_clkcon_enable_p(struct clk *clk, int enable);
+extern int s3c2443_clkcon_enable_s(struct clk *clk, int enable);
+
+extern struct clksrc_clk clk_epllref;
+extern struct clksrc_clk clk_esysclk;
+extern struct clksrc_clk clk_msysclk;