xref: /openbmc/linux/arch/arm/mach-s3c/s3c64xx.h (revision 7a010c3c)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3  * Copyright (c) 2011 Samsung Electronics Co., Ltd.
4  *		http://www.samsung.com
5  *
6  * Copyright 2008 Openmoko, Inc.
7  * Copyright 2008 Simtec Electronics
8  *	Ben Dooks <ben@simtec.co.uk>
9  *	http://armlinux.simtec.co.uk/
10  *
11  * Common Header for S3C64XX machines
12  */
13 
14 #ifndef __ARCH_ARM_MACH_S3C64XX_COMMON_H
15 #define __ARCH_ARM_MACH_S3C64XX_COMMON_H
16 
17 #include <linux/reboot.h>
18 
19 void s3c64xx_init_irq(u32 vic0, u32 vic1);
20 void s3c64xx_init_io(struct map_desc *mach_desc, int size);
21 
22 struct device_node;
23 void s3c64xx_set_xtal_freq(unsigned long freq);
24 void s3c64xx_set_xusbxti_freq(unsigned long freq);
25 
26 #ifdef CONFIG_CPU_S3C6400
27 
28 extern  int s3c6400_init(void);
29 extern void s3c6400_init_irq(void);
30 extern void s3c6400_map_io(void);
31 
32 #else
33 #define s3c6400_map_io NULL
34 #define s3c6400_init NULL
35 #endif
36 
37 #ifdef CONFIG_CPU_S3C6410
38 
39 extern  int s3c6410_init(void);
40 extern void s3c6410_init_irq(void);
41 extern void s3c6410_map_io(void);
42 
43 #else
44 #define s3c6410_map_io NULL
45 #define s3c6410_init NULL
46 #endif
47 
48 #ifdef CONFIG_S3C64XX_PL080
49 extern struct pl08x_platform_data s3c64xx_dma0_plat_data;
50 extern struct pl08x_platform_data s3c64xx_dma1_plat_data;
51 #endif
52 
53 /* Samsung HR-Timer Clock mode */
54 enum s3c64xx_timer_mode {
55 	S3C64XX_PWM0,
56 	S3C64XX_PWM1,
57 	S3C64XX_PWM2,
58 	S3C64XX_PWM3,
59 	S3C64XX_PWM4,
60 };
61 
62 extern void __init s3c64xx_set_timer_source(enum s3c64xx_timer_mode event,
63 					    enum s3c64xx_timer_mode source);
64 extern void __init s3c64xx_timer_init(void);
65 
66 #endif /* __ARCH_ARM_MACH_S3C64XX_COMMON_H */
67