linux/arch/arm/mach-s3c24xx/common.h
<<
>>
Prefs
   1/* SPDX-License-Identifier: GPL-2.0 */
   2/*
   3 * Copyright (c) 2012 Samsung Electronics Co., Ltd.
   4 *              http://www.samsung.com
   5 *
   6 * Common Header for S3C24XX SoCs
   7 */
   8
   9#ifndef __ARCH_ARM_MACH_S3C24XX_COMMON_H
  10#define __ARCH_ARM_MACH_S3C24XX_COMMON_H __FILE__
  11
  12#include <linux/reboot.h>
  13
  14struct s3c2410_uartcfg;
  15
  16#ifdef CONFIG_CPU_S3C2410
  17extern  int s3c2410_init(void);
  18extern  int s3c2410a_init(void);
  19extern void s3c2410_map_io(void);
  20extern void s3c2410_init_uarts(struct s3c2410_uartcfg *cfg, int no);
  21extern void s3c2410_init_clocks(int xtal);
  22extern void s3c2410_init_irq(void);
  23#else
  24#define s3c2410_init_clocks NULL
  25#define s3c2410_init_uarts NULL
  26#define s3c2410_map_io NULL
  27#define s3c2410_init NULL
  28#define s3c2410a_init NULL
  29#endif
  30
  31#ifdef CONFIG_CPU_S3C2412
  32extern  int s3c2412_init(void);
  33extern void s3c2412_map_io(void);
  34extern void s3c2412_init_uarts(struct s3c2410_uartcfg *cfg, int no);
  35extern void s3c2412_init_clocks(int xtal);
  36extern  int s3c2412_baseclk_add(void);
  37extern void s3c2412_init_irq(void);
  38#else
  39#define s3c2412_init_clocks NULL
  40#define s3c2412_init_uarts NULL
  41#define s3c2412_map_io NULL
  42#define s3c2412_init NULL
  43#endif
  44
  45#ifdef CONFIG_CPU_S3C2416
  46extern  int s3c2416_init(void);
  47extern void s3c2416_map_io(void);
  48extern void s3c2416_init_uarts(struct s3c2410_uartcfg *cfg, int no);
  49extern void s3c2416_init_clocks(int xtal);
  50extern  int s3c2416_baseclk_add(void);
  51extern void s3c2416_init_irq(void);
  52
  53extern struct syscore_ops s3c2416_irq_syscore_ops;
  54#else
  55#define s3c2416_init_clocks NULL
  56#define s3c2416_init_uarts NULL
  57#define s3c2416_map_io NULL
  58#define s3c2416_init NULL
  59#endif
  60
  61#if defined(CONFIG_CPU_S3C2440) || defined(CONFIG_CPU_S3C2442)
  62extern void s3c244x_map_io(void);
  63extern void s3c244x_init_uarts(struct s3c2410_uartcfg *cfg, int no);
  64#else
  65#define s3c244x_init_uarts NULL
  66#endif
  67
  68#ifdef CONFIG_CPU_S3C2440
  69extern  int s3c2440_init(void);
  70extern void s3c2440_map_io(void);
  71extern void s3c2440_init_clocks(int xtal);
  72extern void s3c2440_init_irq(void);
  73#else
  74#define s3c2440_init NULL
  75#define s3c2440_map_io NULL
  76#endif
  77
  78#ifdef CONFIG_CPU_S3C2442
  79extern  int s3c2442_init(void);
  80extern void s3c2442_map_io(void);
  81extern void s3c2442_init_clocks(int xtal);
  82extern void s3c2442_init_irq(void);
  83#else
  84#define s3c2442_init NULL
  85#define s3c2442_map_io NULL
  86#endif
  87
  88#ifdef CONFIG_CPU_S3C2443
  89extern  int s3c2443_init(void);
  90extern void s3c2443_map_io(void);
  91extern void s3c2443_init_uarts(struct s3c2410_uartcfg *cfg, int no);
  92extern void s3c2443_init_clocks(int xtal);
  93extern  int s3c2443_baseclk_add(void);
  94extern void s3c2443_init_irq(void);
  95#else
  96#define s3c2443_init_clocks NULL
  97#define s3c2443_init_uarts NULL
  98#define s3c2443_map_io NULL
  99#define s3c2443_init NULL
 100#endif
 101
 102extern struct syscore_ops s3c24xx_irq_syscore_ops;
 103
 104extern struct platform_device s3c2410_device_dma;
 105extern struct platform_device s3c2412_device_dma;
 106extern struct platform_device s3c2440_device_dma;
 107extern struct platform_device s3c2443_device_dma;
 108
 109extern struct platform_device s3c2410_device_dclk;
 110
 111#ifdef CONFIG_S3C2410_COMMON_CLK
 112void __init s3c2410_common_clk_init(struct device_node *np, unsigned long xti_f,
 113                                    int current_soc,
 114                                    void __iomem *reg_base);
 115#endif
 116#ifdef CONFIG_S3C2412_COMMON_CLK
 117void __init s3c2412_common_clk_init(struct device_node *np, unsigned long xti_f,
 118                                unsigned long ext_f, void __iomem *reg_base);
 119#endif
 120#ifdef CONFIG_S3C2443_COMMON_CLK
 121void __init s3c2443_common_clk_init(struct device_node *np, unsigned long xti_f,
 122                                    int current_soc,
 123                                    void __iomem *reg_base);
 124#endif
 125
 126#endif /* __ARCH_ARM_MACH_S3C24XX_COMMON_H */
 127