blob: 362a8cd32eb0cb840db5ac1549a7f38ab901bcf9 [file] [log] [blame]
Kukjin Kim8551f3f2012-03-29 08:55:48 +09001/*
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
Heiko Stuebner74883352013-02-08 10:37:13 -080015struct s3c2410_uartcfg;
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080016
Heiko Stuebner74883352013-02-08 10:37:13 -080017#ifdef CONFIG_CPU_S3C2410
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080018extern int s3c2410_init(void);
19extern int s3c2410a_init(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080020extern void s3c2410_map_io(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080021extern void s3c2410_init_uarts(struct s3c2410_uartcfg *cfg, int no);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080022extern void s3c2410_init_clocks(int xtal);
Heiko Stuebner74883352013-02-08 10:37:13 -080023extern void s3c2410_restart(char mode, const char *cmd);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080024#else
25#define s3c2410_init_clocks NULL
26#define s3c2410_init_uarts NULL
27#define s3c2410_map_io NULL
28#define s3c2410_init NULL
29#define s3c2410a_init NULL
30#endif
31
32#ifdef CONFIG_CPU_S3C2412
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080033extern int s3c2412_init(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080034extern void s3c2412_map_io(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080035extern void s3c2412_init_uarts(struct s3c2410_uartcfg *cfg, int no);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080036extern void s3c2412_init_clocks(int xtal);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080037extern int s3c2412_baseclk_add(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080038extern void s3c2412_restart(char mode, const char *cmd);
39#else
40#define s3c2412_init_clocks NULL
41#define s3c2412_init_uarts NULL
42#define s3c2412_map_io NULL
43#define s3c2412_init NULL
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080044#endif
45
46#ifdef CONFIG_CPU_S3C2416
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080047extern int s3c2416_init(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080048extern void s3c2416_map_io(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080049extern void s3c2416_init_uarts(struct s3c2410_uartcfg *cfg, int no);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080050extern void s3c2416_init_clocks(int xtal);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080051extern int s3c2416_baseclk_add(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080052extern void s3c2416_restart(char mode, const char *cmd);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080053extern void s3c2416_init_irq(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080054
Heiko Stuebner74883352013-02-08 10:37:13 -080055extern struct syscore_ops s3c2416_irq_syscore_ops;
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080056#else
57#define s3c2416_init_clocks NULL
58#define s3c2416_init_uarts NULL
59#define s3c2416_map_io NULL
60#define s3c2416_init NULL
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080061#endif
62
63#if defined(CONFIG_CPU_S3C2440) || defined(CONFIG_CPU_S3C2442)
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080064extern void s3c244x_map_io(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080065extern void s3c244x_init_uarts(struct s3c2410_uartcfg *cfg, int no);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080066extern void s3c244x_init_clocks(int xtal);
Heiko Stuebner74883352013-02-08 10:37:13 -080067extern void s3c244x_restart(char mode, const char *cmd);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080068#else
69#define s3c244x_init_clocks NULL
70#define s3c244x_init_uarts NULL
71#endif
72
73#ifdef CONFIG_CPU_S3C2440
74extern int s3c2440_init(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080075extern void s3c2440_map_io(void);
Heiko Stuebnerce6c1642013-02-12 09:59:20 -080076extern void s3c2440_init_irq(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080077#else
78#define s3c2440_init NULL
79#define s3c2440_map_io NULL
80#endif
81
82#ifdef CONFIG_CPU_S3C2442
83extern int s3c2442_init(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080084extern void s3c2442_map_io(void);
Heiko Stuebnerce6c1642013-02-12 09:59:20 -080085extern void s3c2442_init_irq(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080086#else
87#define s3c2442_init NULL
88#define s3c2442_map_io NULL
89#endif
90
91#ifdef CONFIG_CPU_S3C2443
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080092extern int s3c2443_init(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080093extern void s3c2443_map_io(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080094extern void s3c2443_init_uarts(struct s3c2410_uartcfg *cfg, int no);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080095extern void s3c2443_init_clocks(int xtal);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080096extern int s3c2443_baseclk_add(void);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080097extern void s3c2443_restart(char mode, const char *cmd);
Heiko Stuebnere1a621d2013-02-08 10:31:28 -080098extern void s3c2443_init_irq(void);
99#else
100#define s3c2443_init_clocks NULL
101#define s3c2443_init_uarts NULL
102#define s3c2443_map_io NULL
103#define s3c2443_init NULL
Heiko Stuebnere1a621d2013-02-08 10:31:28 -0800104#endif
105
Heiko Stuebnerd8fdec12013-01-29 10:25:22 -0800106extern struct syscore_ops s3c24xx_irq_syscore_ops;
107
Kukjin Kim8551f3f2012-03-29 08:55:48 +0900108#endif /* __ARCH_ARM_MACH_S3C24XX_COMMON_H */