blob: a9fd45362fee45dc0782c0cf8ee1ea7c1354559d [file] [log] [blame]
Viresh Kumarb31e2372012-04-19 22:23:13 +05301/*
Arnd Bergmann54475212013-03-12 17:00:03 +01002 * spear machine family generic header file
Viresh Kumarb31e2372012-04-19 22:23:13 +05303 *
Arnd Bergmann54475212013-03-12 17:00:03 +01004 * Copyright (C) 2009-2012 ST Microelectronics
5 * Rajeev Kumar <rajeev-dlh.kumar@st.com>
Viresh Kumar10d89352012-06-20 12:53:02 -07006 * Viresh Kumar <viresh.linux@gmail.com>
Viresh Kumarb31e2372012-04-19 22:23:13 +05307 *
8 * This file is licensed under the terms of the GNU General Public
9 * License version 2. This program is licensed "as is" without any
10 * warranty of any kind, whether express or implied.
11 */
12
13#ifndef __MACH_GENERIC_H
14#define __MACH_GENERIC_H
15
16#include <linux/dmaengine.h>
Arnd Bergmann54475212013-03-12 17:00:03 +010017#include <linux/amba/pl08x.h>
18#include <linux/init.h>
Viresh Kumarb31e2372012-04-19 22:23:13 +053019#include <asm/mach/time.h>
20
Stephen Warren6bb27d72012-11-08 12:40:59 -070021extern void spear13xx_timer_init(void);
Arnd Bergmann54475212013-03-12 17:00:03 +010022extern void spear3xx_timer_init(void);
Viresh Kumarb31e2372012-04-19 22:23:13 +053023extern struct pl022_ssp_controller pl022_plat_data;
Arnd Bergmann54475212013-03-12 17:00:03 +010024extern struct pl08x_platform_data pl080_plat_data;
Viresh Kumarb31e2372012-04-19 22:23:13 +053025
Viresh Kumarb31e2372012-04-19 22:23:13 +053026void __init spear_setup_of_timer(void);
Arnd Bergmannd9909eb2012-12-02 17:59:57 +010027void __init spear3xx_clk_init(void __iomem *misc_base,
28 void __iomem *soc_config_base);
Arnd Bergmann54475212013-03-12 17:00:03 +010029void __init spear3xx_map_io(void);
30void __init spear3xx_dt_init_irq(void);
Arnd Bergmannd9909eb2012-12-02 17:59:57 +010031void __init spear6xx_clk_init(void __iomem *misc_base);
Viresh Kumarb31e2372012-04-19 22:23:13 +053032void __init spear13xx_map_io(void);
Viresh Kumarb31e2372012-04-19 22:23:13 +053033void __init spear13xx_l2x0_init(void);
Arnd Bergmann54475212013-03-12 17:00:03 +010034
Viresh Kumarb31e2372012-04-19 22:23:13 +053035void spear_restart(char, const char *);
Arnd Bergmann54475212013-03-12 17:00:03 +010036
Viresh Kumarb31e2372012-04-19 22:23:13 +053037void spear13xx_secondary_startup(void);
Arnd Bergmann2d8b21d2011-09-08 13:15:22 +010038void __cpuinit spear13xx_cpu_die(unsigned int cpu);
39
40extern struct smp_operations spear13xx_smp_ops;
Viresh Kumarb31e2372012-04-19 22:23:13 +053041
42#ifdef CONFIG_MACH_SPEAR1310
Arnd Bergmannd9909eb2012-12-02 17:59:57 +010043void __init spear1310_clk_init(void __iomem *misc_base, void __iomem *ras_base);
Viresh Kumarb31e2372012-04-19 22:23:13 +053044#else
Arnd Bergmannd9909eb2012-12-02 17:59:57 +010045static inline void spear1310_clk_init(void __iomem *misc_base, void __iomem *ras_base) {}
Viresh Kumarb31e2372012-04-19 22:23:13 +053046#endif
47
48#ifdef CONFIG_MACH_SPEAR1340
Arnd Bergmannd9909eb2012-12-02 17:59:57 +010049void __init spear1340_clk_init(void __iomem *misc_base);
Viresh Kumarb31e2372012-04-19 22:23:13 +053050#else
Arnd Bergmannd9909eb2012-12-02 17:59:57 +010051static inline void spear1340_clk_init(void __iomem *misc_base) {}
Viresh Kumarb31e2372012-04-19 22:23:13 +053052#endif
53
54#endif /* __MACH_GENERIC_H */