2012-03-29 06:55:48 +07:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2012 Samsung Electronics Co., Ltd.
|
|
|
|
* http://www.samsung.com
|
|
|
|
*
|
|
|
|
* Common Header for S3C24XX SoCs
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License version 2 as
|
|
|
|
* published by the Free Software Foundation.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __ARCH_ARM_MACH_S3C24XX_COMMON_H
|
|
|
|
#define __ARCH_ARM_MACH_S3C24XX_COMMON_H __FILE__
|
|
|
|
|
2013-07-09 06:01:40 +07:00
|
|
|
#include <linux/reboot.h>
|
|
|
|
|
2013-02-09 01:37:13 +07:00
|
|
|
struct s3c2410_uartcfg;
|
2013-02-09 01:31:28 +07:00
|
|
|
|
2013-02-09 01:37:13 +07:00
|
|
|
#ifdef CONFIG_CPU_S3C2410
|
2013-02-09 01:31:28 +07:00
|
|
|
extern int s3c2410_init(void);
|
|
|
|
extern int s3c2410a_init(void);
|
|
|
|
extern void s3c2410_map_io(void);
|
|
|
|
extern void s3c2410_init_uarts(struct s3c2410_uartcfg *cfg, int no);
|
|
|
|
extern void s3c2410_init_clocks(int xtal);
|
2013-07-09 06:01:40 +07:00
|
|
|
extern void s3c2410_restart(enum reboot_mode mode, const char *cmd);
|
2013-03-07 10:38:19 +07:00
|
|
|
extern void s3c2410_init_irq(void);
|
2013-02-09 01:31:28 +07:00
|
|
|
#else
|
|
|
|
#define s3c2410_init_clocks NULL
|
|
|
|
#define s3c2410_init_uarts NULL
|
|
|
|
#define s3c2410_map_io NULL
|
|
|
|
#define s3c2410_init NULL
|
|
|
|
#define s3c2410a_init NULL
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef CONFIG_CPU_S3C2412
|
|
|
|
extern int s3c2412_init(void);
|
|
|
|
extern void s3c2412_map_io(void);
|
|
|
|
extern void s3c2412_init_uarts(struct s3c2410_uartcfg *cfg, int no);
|
|
|
|
extern void s3c2412_init_clocks(int xtal);
|
|
|
|
extern int s3c2412_baseclk_add(void);
|
2013-07-09 06:01:40 +07:00
|
|
|
extern void s3c2412_restart(enum reboot_mode mode, const char *cmd);
|
2013-02-13 01:09:18 +07:00
|
|
|
extern void s3c2412_init_irq(void);
|
2013-02-09 01:31:28 +07:00
|
|
|
#else
|
|
|
|
#define s3c2412_init_clocks NULL
|
|
|
|
#define s3c2412_init_uarts NULL
|
|
|
|
#define s3c2412_map_io NULL
|
|
|
|
#define s3c2412_init NULL
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef CONFIG_CPU_S3C2416
|
|
|
|
extern int s3c2416_init(void);
|
|
|
|
extern void s3c2416_map_io(void);
|
|
|
|
extern void s3c2416_init_uarts(struct s3c2410_uartcfg *cfg, int no);
|
|
|
|
extern void s3c2416_init_clocks(int xtal);
|
|
|
|
extern int s3c2416_baseclk_add(void);
|
2013-07-09 06:01:40 +07:00
|
|
|
extern void s3c2416_restart(enum reboot_mode mode, const char *cmd);
|
2013-02-09 01:31:28 +07:00
|
|
|
extern void s3c2416_init_irq(void);
|
|
|
|
|
2013-02-09 01:37:13 +07:00
|
|
|
extern struct syscore_ops s3c2416_irq_syscore_ops;
|
2013-02-09 01:31:28 +07:00
|
|
|
#else
|
|
|
|
#define s3c2416_init_clocks NULL
|
|
|
|
#define s3c2416_init_uarts NULL
|
|
|
|
#define s3c2416_map_io NULL
|
|
|
|
#define s3c2416_init NULL
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#if defined(CONFIG_CPU_S3C2440) || defined(CONFIG_CPU_S3C2442)
|
|
|
|
extern void s3c244x_map_io(void);
|
|
|
|
extern void s3c244x_init_uarts(struct s3c2410_uartcfg *cfg, int no);
|
|
|
|
extern void s3c244x_init_clocks(int xtal);
|
2013-07-09 06:01:40 +07:00
|
|
|
extern void s3c244x_restart(enum reboot_mode mode, const char *cmd);
|
2013-02-09 01:31:28 +07:00
|
|
|
#else
|
|
|
|
#define s3c244x_init_clocks NULL
|
|
|
|
#define s3c244x_init_uarts NULL
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef CONFIG_CPU_S3C2440
|
|
|
|
extern int s3c2440_init(void);
|
|
|
|
extern void s3c2440_map_io(void);
|
2014-05-09 03:49:14 +07:00
|
|
|
extern void s3c2440_init_clocks(int xtal);
|
2013-02-13 00:59:20 +07:00
|
|
|
extern void s3c2440_init_irq(void);
|
2013-02-09 01:31:28 +07:00
|
|
|
#else
|
|
|
|
#define s3c2440_init NULL
|
|
|
|
#define s3c2440_map_io NULL
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef CONFIG_CPU_S3C2442
|
|
|
|
extern int s3c2442_init(void);
|
|
|
|
extern void s3c2442_map_io(void);
|
2014-05-09 03:49:14 +07:00
|
|
|
extern void s3c2442_init_clocks(int xtal);
|
2013-02-13 00:59:20 +07:00
|
|
|
extern void s3c2442_init_irq(void);
|
2013-02-09 01:31:28 +07:00
|
|
|
#else
|
|
|
|
#define s3c2442_init NULL
|
|
|
|
#define s3c2442_map_io NULL
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef CONFIG_CPU_S3C2443
|
|
|
|
extern int s3c2443_init(void);
|
|
|
|
extern void s3c2443_map_io(void);
|
|
|
|
extern void s3c2443_init_uarts(struct s3c2410_uartcfg *cfg, int no);
|
|
|
|
extern void s3c2443_init_clocks(int xtal);
|
|
|
|
extern int s3c2443_baseclk_add(void);
|
2013-07-09 06:01:40 +07:00
|
|
|
extern void s3c2443_restart(enum reboot_mode mode, const char *cmd);
|
2013-02-09 01:31:28 +07:00
|
|
|
extern void s3c2443_init_irq(void);
|
|
|
|
#else
|
|
|
|
#define s3c2443_init_clocks NULL
|
|
|
|
#define s3c2443_init_uarts NULL
|
|
|
|
#define s3c2443_map_io NULL
|
|
|
|
#define s3c2443_init NULL
|
|
|
|
#endif
|
|
|
|
|
2013-01-30 01:25:22 +07:00
|
|
|
extern struct syscore_ops s3c24xx_irq_syscore_ops;
|
|
|
|
|
2013-10-21 03:32:48 +07:00
|
|
|
extern struct platform_device s3c2410_device_dma;
|
2013-10-08 04:42:10 +07:00
|
|
|
extern struct platform_device s3c2412_device_dma;
|
2013-10-21 03:32:48 +07:00
|
|
|
extern struct platform_device s3c2440_device_dma;
|
2013-10-08 04:42:10 +07:00
|
|
|
extern struct platform_device s3c2443_device_dma;
|
|
|
|
|
2014-05-09 03:48:57 +07:00
|
|
|
extern struct platform_device s3c2410_device_dclk;
|
|
|
|
|
2014-05-09 03:49:14 +07:00
|
|
|
#ifdef CONFIG_S3C2410_COMMON_CLK
|
|
|
|
void __init s3c2410_common_clk_init(struct device_node *np, unsigned long xti_f,
|
|
|
|
int current_soc,
|
|
|
|
void __iomem *reg_base);
|
|
|
|
#endif
|
2014-02-25 07:50:44 +07:00
|
|
|
#ifdef CONFIG_S3C2412_COMMON_CLK
|
|
|
|
void __init s3c2412_common_clk_init(struct device_node *np, unsigned long xti_f,
|
|
|
|
unsigned long ext_f, void __iomem *reg_base);
|
|
|
|
#endif
|
2014-02-19 07:26:21 +07:00
|
|
|
#ifdef CONFIG_S3C2443_COMMON_CLK
|
|
|
|
void __init s3c2443_common_clk_init(struct device_node *np, unsigned long xti_f,
|
|
|
|
int current_soc,
|
|
|
|
void __iomem *reg_base);
|
|
|
|
#endif
|
|
|
|
|
2012-03-29 06:55:48 +07:00
|
|
|
#endif /* __ARCH_ARM_MACH_S3C24XX_COMMON_H */
|