ARM: S3C24XX: remove legacy clock code
[deliverable/linux.git] / arch / arm / mach-s3c24xx / common.h
1 /*
2 * Copyright (c) 2012 Samsung Electronics Co., Ltd.
3 * http://www.samsung.com
4 *
5 * Common Header for S3C24XX SoCs
6 *
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License version 2 as
9 * published by the Free Software Foundation.
10 */
11
12 #ifndef __ARCH_ARM_MACH_S3C24XX_COMMON_H
13 #define __ARCH_ARM_MACH_S3C24XX_COMMON_H __FILE__
14
15 #include <linux/reboot.h>
16
17 struct s3c2410_uartcfg;
18
19 #ifdef CONFIG_CPU_S3C2410
20 extern int s3c2410_init(void);
21 extern int s3c2410a_init(void);
22 extern void s3c2410_map_io(void);
23 extern void s3c2410_init_uarts(struct s3c2410_uartcfg *cfg, int no);
24 extern void s3c2410_init_clocks(int xtal);
25 extern void s3c2410_restart(enum reboot_mode mode, const char *cmd);
26 extern void s3c2410_init_irq(void);
27 #else
28 #define s3c2410_init_clocks NULL
29 #define s3c2410_init_uarts NULL
30 #define s3c2410_map_io NULL
31 #define s3c2410_init NULL
32 #define s3c2410a_init NULL
33 #endif
34
35 #ifdef CONFIG_CPU_S3C2412
36 extern int s3c2412_init(void);
37 extern void s3c2412_map_io(void);
38 extern void s3c2412_init_uarts(struct s3c2410_uartcfg *cfg, int no);
39 extern void s3c2412_init_clocks(int xtal);
40 extern int s3c2412_baseclk_add(void);
41 extern void s3c2412_restart(enum reboot_mode mode, const char *cmd);
42 extern void s3c2412_init_irq(void);
43 #else
44 #define s3c2412_init_clocks NULL
45 #define s3c2412_init_uarts NULL
46 #define s3c2412_map_io NULL
47 #define s3c2412_init NULL
48 #endif
49
50 #ifdef CONFIG_CPU_S3C2416
51 extern int s3c2416_init(void);
52 extern void s3c2416_map_io(void);
53 extern void s3c2416_init_uarts(struct s3c2410_uartcfg *cfg, int no);
54 extern void s3c2416_init_clocks(int xtal);
55 extern int s3c2416_baseclk_add(void);
56 extern void s3c2416_restart(enum reboot_mode mode, const char *cmd);
57 extern void s3c2416_init_irq(void);
58
59 extern struct syscore_ops s3c2416_irq_syscore_ops;
60 #else
61 #define s3c2416_init_clocks NULL
62 #define s3c2416_init_uarts NULL
63 #define s3c2416_map_io NULL
64 #define s3c2416_init NULL
65 #endif
66
67 #if defined(CONFIG_CPU_S3C2440) || defined(CONFIG_CPU_S3C2442)
68 extern void s3c244x_map_io(void);
69 extern void s3c244x_init_uarts(struct s3c2410_uartcfg *cfg, int no);
70 extern void s3c244x_restart(enum reboot_mode mode, const char *cmd);
71 #else
72 #define s3c244x_init_uarts NULL
73 #endif
74
75 #ifdef CONFIG_CPU_S3C2440
76 extern int s3c2440_init(void);
77 extern void s3c2440_map_io(void);
78 extern void s3c2440_init_clocks(int xtal);
79 extern void s3c2440_init_irq(void);
80 #else
81 #define s3c2440_init NULL
82 #define s3c2440_map_io NULL
83 #endif
84
85 #ifdef CONFIG_CPU_S3C2442
86 extern int s3c2442_init(void);
87 extern void s3c2442_map_io(void);
88 extern void s3c2442_init_clocks(int xtal);
89 extern void s3c2442_init_irq(void);
90 #else
91 #define s3c2442_init NULL
92 #define s3c2442_map_io NULL
93 #endif
94
95 #ifdef CONFIG_CPU_S3C2443
96 extern int s3c2443_init(void);
97 extern void s3c2443_map_io(void);
98 extern void s3c2443_init_uarts(struct s3c2410_uartcfg *cfg, int no);
99 extern void s3c2443_init_clocks(int xtal);
100 extern int s3c2443_baseclk_add(void);
101 extern void s3c2443_restart(enum reboot_mode mode, const char *cmd);
102 extern void s3c2443_init_irq(void);
103 #else
104 #define s3c2443_init_clocks NULL
105 #define s3c2443_init_uarts NULL
106 #define s3c2443_map_io NULL
107 #define s3c2443_init NULL
108 #endif
109
110 extern struct syscore_ops s3c24xx_irq_syscore_ops;
111
112 extern struct platform_device s3c2410_device_dma;
113 extern struct platform_device s3c2412_device_dma;
114 extern struct platform_device s3c2440_device_dma;
115 extern struct platform_device s3c2443_device_dma;
116
117 extern struct platform_device s3c2410_device_dclk;
118
119 #ifdef CONFIG_S3C2410_COMMON_CLK
120 void __init s3c2410_common_clk_init(struct device_node *np, unsigned long xti_f,
121 int current_soc,
122 void __iomem *reg_base);
123 #endif
124 #ifdef CONFIG_S3C2412_COMMON_CLK
125 void __init s3c2412_common_clk_init(struct device_node *np, unsigned long xti_f,
126 unsigned long ext_f, void __iomem *reg_base);
127 #endif
128 #ifdef CONFIG_S3C2443_COMMON_CLK
129 void __init s3c2443_common_clk_init(struct device_node *np, unsigned long xti_f,
130 int current_soc,
131 void __iomem *reg_base);
132 #endif
133
134 #endif /* __ARCH_ARM_MACH_S3C24XX_COMMON_H */
This page took 0.033748 seconds and 5 git commands to generate.