common.h 2.8 KB
Newer Older
1 2 3
#ifndef __ARCH_MACH_COMMON_H
#define __ARCH_MACH_COMMON_H

4
extern void shmobile_earlytimer_init(void);
5
extern struct sys_timer shmobile_timer;
6
extern void shmobile_setup_delay(unsigned int max_cpu_core_mhz,
7
			 unsigned int mult, unsigned int div);
8
struct twd_local_timer;
9
extern void shmobile_setup_console(void);
M
Magnus Damm 已提交
10
extern void shmobile_secondary_vector(void);
11
struct clk;
12
extern int shmobile_clk_init(void);
13
extern void shmobile_handle_irq_intc(struct pt_regs *);
14
extern struct platform_suspend_ops shmobile_suspend_ops;
15
struct cpuidle_driver;
16 17 18 19
struct cpuidle_device;
extern int shmobile_enter_wfi(struct cpuidle_device *dev,
			      struct cpuidle_driver *drv, int index);
extern void shmobile_cpuidle_set_driver(struct cpuidle_driver *drv);
20

21
extern void sh7372_init_irq(void);
22
extern void sh7372_map_io(void);
23 24
extern void sh7372_add_early_devices(void);
extern void sh7372_add_standard_devices(void);
25
extern void sh7372_clock_init(void);
26
extern void sh7372_pinmux_init(void);
27
extern void sh7372_pm_init(void);
28 29
extern void sh7372_resume_core_standby_sysc(void);
extern int sh7372_do_idle_sysc(unsigned long sleep_mode);
30 31
extern struct clk sh7372_extal1_clk;
extern struct clk sh7372_extal2_clk;
32

33
extern void sh73a0_init_irq(void);
34
extern void sh73a0_map_io(void);
35 36 37
extern void sh73a0_add_early_devices(void);
extern void sh73a0_add_standard_devices(void);
extern void sh73a0_clock_init(void);
38
extern void sh73a0_pinmux_init(void);
39 40
extern struct clk sh73a0_extal1_clk;
extern struct clk sh73a0_extal2_clk;
41 42
extern struct clk sh73a0_extcki_clk;
extern struct clk sh73a0_extalr_clk;
43

44
extern void r8a7740_init_irq(void);
45
extern void r8a7740_map_io(void);
46 47 48 49 50
extern void r8a7740_add_early_devices(void);
extern void r8a7740_add_standard_devices(void);
extern void r8a7740_clock_init(u8 md_ck);
extern void r8a7740_pinmux_init(void);

51
extern void r8a7779_init_irq(void);
52
extern void r8a7779_map_io(void);
53 54 55
extern void r8a7779_add_early_devices(void);
extern void r8a7779_add_standard_devices(void);
extern void r8a7779_clock_init(void);
56
extern void r8a7779_pinmux_init(void);
57
extern void r8a7779_pm_init(void);
58
extern void r8a7740_meram_workaround(void);
59

60
extern void r8a7779_register_twd(void);
61

62 63 64 65 66 67 68 69 70 71 72 73
#ifdef CONFIG_SUSPEND
int shmobile_suspend_init(void);
#else
static inline int shmobile_suspend_init(void) { return 0; }
#endif

#ifdef CONFIG_CPU_IDLE
int shmobile_cpuidle_init(void);
#else
static inline int shmobile_cpuidle_init(void) { return 0; }
#endif

74 75 76 77 78 79 80 81 82 83 84
extern void shmobile_cpu_die(unsigned int cpu);
extern int shmobile_cpu_disable(unsigned int cpu);

#ifdef CONFIG_HOTPLUG_CPU
extern int shmobile_cpu_is_dead(unsigned int cpu);
#else
static inline int shmobile_cpu_is_dead(unsigned int cpu) { return 1; }
#endif

extern void shmobile_smp_init_cpus(unsigned int ncores);

85
static inline void __init shmobile_init_late(void)
86 87 88 89 90
{
	shmobile_suspend_init();
	shmobile_cpuidle_init();
}

91
#endif /* __ARCH_MACH_COMMON_H */