blob: 1f8a1caa7cb4d4b6d9900a34aed168c3011930ae [file] [log] [blame]
Sudeep Holla0b7402d2015-05-18 16:29:40 +01001#ifndef __CLKSOURCE_TIMER_SP804_H
2#define __CLKSOURCE_TIMER_SP804_H
3
Rob Herring7a0eca72013-03-25 11:23:52 -05004struct clk;
5
Rob Herringa7bf6162011-12-12 15:29:08 -06006void __sp804_clocksource_and_sched_clock_init(void __iomem *,
Rob Herring7a0eca72013-03-25 11:23:52 -05007 const char *, struct clk *, int);
8void __sp804_clockevents_init(void __iomem *, unsigned int,
9 struct clk *, const char *);
Sudeep Holla1e5f0512015-05-18 16:29:04 +010010void sp804_timer_disable(void __iomem *);
Rob Herringa7bf6162011-12-12 15:29:08 -060011
12static inline void sp804_clocksource_init(void __iomem *base, const char *name)
13{
Rob Herring7a0eca72013-03-25 11:23:52 -050014 __sp804_clocksource_and_sched_clock_init(base, name, NULL, 0);
Rob Herringa7bf6162011-12-12 15:29:08 -060015}
16
17static inline void sp804_clocksource_and_sched_clock_init(void __iomem *base,
18 const char *name)
19{
Rob Herring7a0eca72013-03-25 11:23:52 -050020 __sp804_clocksource_and_sched_clock_init(base, name, NULL, 1);
Rob Herringa7bf6162011-12-12 15:29:08 -060021}
22
Rob Herring7a0eca72013-03-25 11:23:52 -050023static inline void sp804_clockevents_init(void __iomem *base, unsigned int irq, const char *name)
24{
25 __sp804_clockevents_init(base, irq, NULL, name);
26
27}
Sudeep Holla0b7402d2015-05-18 16:29:40 +010028#endif