blob: 20da9b1d7f7d01c0a537dd6a421b3eb7ea2e547e [file] [log] [blame]
Vineet Guptad8005e62013-01-18 15:12:18 +05301/*
Vineet Guptac4c9a042016-10-31 13:46:38 -07002 * Copyright (C) 2016-17 Synopsys, Inc. (www.synopsys.com)
Vineet Guptad8005e62013-01-18 15:12:18 +05303 * Copyright (C) 2004, 2007-2010, 2011-2012 Synopsys, Inc. (www.synopsys.com)
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 2 as
7 * published by the Free Software Foundation.
Vineet Guptad8005e62013-01-18 15:12:18 +05308 */
9
Vineet Guptac4c9a042016-10-31 13:46:38 -070010/* ARC700 has two 32bit independent prog Timers: TIMER0 and TIMER1, Each can be
11 * programmed to go from @count to @limit and optionally interrupt.
12 * We've designated TIMER0 for clockevents and TIMER1 for clocksource
Vineet Guptad8005e62013-01-18 15:12:18 +053013 *
Vineet Guptac4c9a042016-10-31 13:46:38 -070014 * ARCv2 based HS38 cores have RTC (in-core) and GFRC (inside ARConnect/MCIP)
15 * which are suitable for UP and SMP based clocksources respectively
Vineet Guptad8005e62013-01-18 15:12:18 +053016 */
17
Vineet Guptad8005e62013-01-18 15:12:18 +053018#include <linux/interrupt.h>
Noam Camus69fbd092016-01-14 12:20:08 +053019#include <linux/clk.h>
20#include <linux/clk-provider.h>
Vineet Guptad8005e62013-01-18 15:12:18 +053021#include <linux/clocksource.h>
22#include <linux/clockchips.h>
Noam Camuseec3c582016-01-01 15:48:49 +053023#include <linux/cpu.h>
Vineet Gupta77c8d0d2016-01-01 17:58:45 +053024#include <linux/of.h>
25#include <linux/of_irq.h>
Vineet Guptad8005e62013-01-18 15:12:18 +053026
Vineet Guptab26c2e32016-10-31 13:06:19 -070027#include <soc/arc/timers.h>
Vineet Gupta2d7f5c42016-10-31 11:27:08 -070028#include <soc/arc/mcip.h>
Vineet Gupta72d72882014-12-24 18:41:55 +053029
Vineet Guptad8005e62013-01-18 15:12:18 +053030
Vineet Gupta77c8d0d2016-01-01 17:58:45 +053031static unsigned long arc_timer_freq;
32
33static int noinline arc_get_timer_clk(struct device_node *node)
34{
35 struct clk *clk;
36 int ret;
37
38 clk = of_clk_get(node, 0);
39 if (IS_ERR(clk)) {
Rafał Miłeckiac9ce6d2017-03-09 10:47:10 +010040 pr_err("timer missing clk\n");
Vineet Gupta77c8d0d2016-01-01 17:58:45 +053041 return PTR_ERR(clk);
42 }
43
44 ret = clk_prepare_enable(clk);
45 if (ret) {
46 pr_err("Couldn't enable parent clk\n");
47 return ret;
48 }
49
50 arc_timer_freq = clk_get_rate(clk);
51
52 return 0;
53}
54
Vineet Guptad8005e62013-01-18 15:12:18 +053055/********** Clock Source Device *********/
56
Vineet Gupta04421422016-10-31 14:26:41 -070057#ifdef CONFIG_ARC_TIMERS_64BIT
Vineet Gupta72d72882014-12-24 18:41:55 +053058
Thomas Gleixnera5a1d1c2016-12-21 20:32:01 +010059static u64 arc_read_gfrc(struct clocksource *cs)
Vineet Gupta72d72882014-12-24 18:41:55 +053060{
61 unsigned long flags;
Vineet Gupta2cd690e2016-11-03 11:38:52 -070062 u32 l, h;
Vineet Gupta72d72882014-12-24 18:41:55 +053063
Eugeniy Paltsev6bd95492018-04-19 18:53:05 +030064 /*
65 * From a programming model pov, there seems to be just one instance of
66 * MCIP_CMD/MCIP_READBACK however micro-architecturally there's
67 * an instance PER ARC CORE (not per cluster), and there are dedicated
68 * hardware decode logic (per core) inside ARConnect to handle
69 * simultaneous read/write accesses from cores via those two registers.
70 * So several concurrent commands to ARConnect are OK if they are
71 * trying to access two different sub-components (like GFRC,
72 * inter-core interrupt, etc...). HW also supports simultaneously
73 * accessing GFRC by multiple cores.
74 * That's why it is safe to disable hard interrupts on the local CPU
75 * before access to GFRC instead of taking global MCIP spinlock
76 * defined in arch/arc/kernel/mcip.c
77 */
Vineet Gupta72d72882014-12-24 18:41:55 +053078 local_irq_save(flags);
79
Vineet Guptad584f0f2016-01-22 14:27:50 +053080 __mcip_cmd(CMD_GFRC_READ_LO, 0);
Vineet Gupta2cd690e2016-11-03 11:38:52 -070081 l = read_aux_reg(ARC_REG_MCIP_READBACK);
Vineet Gupta72d72882014-12-24 18:41:55 +053082
Vineet Guptad584f0f2016-01-22 14:27:50 +053083 __mcip_cmd(CMD_GFRC_READ_HI, 0);
Vineet Gupta2cd690e2016-11-03 11:38:52 -070084 h = read_aux_reg(ARC_REG_MCIP_READBACK);
Vineet Gupta72d72882014-12-24 18:41:55 +053085
86 local_irq_restore(flags);
87
Thomas Gleixnera5a1d1c2016-12-21 20:32:01 +010088 return (((u64)h) << 32) | l;
Vineet Gupta72d72882014-12-24 18:41:55 +053089}
90
Vineet Guptae608b532016-01-01 18:05:48 +053091static struct clocksource arc_counter_gfrc = {
Vineet Guptad584f0f2016-01-22 14:27:50 +053092 .name = "ARConnect GFRC",
Vineet Gupta72d72882014-12-24 18:41:55 +053093 .rating = 400,
Vineet Guptae608b532016-01-01 18:05:48 +053094 .read = arc_read_gfrc,
Vineet Gupta72d72882014-12-24 18:41:55 +053095 .mask = CLOCKSOURCE_MASK(64),
96 .flags = CLOCK_SOURCE_IS_CONTINUOUS,
97};
98
Daniel Lezcano43d75602016-06-15 14:50:12 +020099static int __init arc_cs_setup_gfrc(struct device_node *node)
Vineet Guptae608b532016-01-01 18:05:48 +0530100{
Vineet Guptaec7cb872016-10-31 13:02:31 -0700101 struct mcip_bcr mp;
Vineet Guptae608b532016-01-01 18:05:48 +0530102 int ret;
103
Vineet Guptaec7cb872016-10-31 13:02:31 -0700104 READ_BCR(ARC_REG_MCIP_BCR, mp);
105 if (!mp.gfrc) {
Rafał Miłeckiac9ce6d2017-03-09 10:47:10 +0100106 pr_warn("Global-64-bit-Ctr clocksource not detected\n");
Daniel Lezcano43d75602016-06-15 14:50:12 +0200107 return -ENXIO;
Vineet Guptaec7cb872016-10-31 13:02:31 -0700108 }
Vineet Guptae608b532016-01-01 18:05:48 +0530109
110 ret = arc_get_timer_clk(node);
111 if (ret)
Daniel Lezcano43d75602016-06-15 14:50:12 +0200112 return ret;
Vineet Guptae608b532016-01-01 18:05:48 +0530113
Daniel Lezcano43d75602016-06-15 14:50:12 +0200114 return clocksource_register_hz(&arc_counter_gfrc, arc_timer_freq);
Vineet Guptae608b532016-01-01 18:05:48 +0530115}
Daniel Lezcano17273392017-05-26 16:56:11 +0200116TIMER_OF_DECLARE(arc_gfrc, "snps,archs-timer-gfrc", arc_cs_setup_gfrc);
Vineet Guptae608b532016-01-01 18:05:48 +0530117
Vineet Guptaaa93e8e2013-11-07 14:57:16 +0530118#define AUX_RTC_CTRL 0x103
119#define AUX_RTC_LOW 0x104
120#define AUX_RTC_HIGH 0x105
121
Thomas Gleixnera5a1d1c2016-12-21 20:32:01 +0100122static u64 arc_read_rtc(struct clocksource *cs)
Vineet Guptaaa93e8e2013-11-07 14:57:16 +0530123{
124 unsigned long status;
Vineet Gupta2cd690e2016-11-03 11:38:52 -0700125 u32 l, h;
Vineet Guptaaa93e8e2013-11-07 14:57:16 +0530126
Vineet Gupta922cc172016-10-31 14:09:52 -0700127 /*
128 * hardware has an internal state machine which tracks readout of
129 * low/high and updates the CTRL.status if
130 * - interrupt/exception taken between the two reads
131 * - high increments after low has been read
132 */
133 do {
Vineet Gupta2cd690e2016-11-03 11:38:52 -0700134 l = read_aux_reg(AUX_RTC_LOW);
135 h = read_aux_reg(AUX_RTC_HIGH);
Vineet Gupta922cc172016-10-31 14:09:52 -0700136 status = read_aux_reg(AUX_RTC_CTRL);
137 } while (!(status & _BITUL(31)));
Vineet Guptaaa93e8e2013-11-07 14:57:16 +0530138
Thomas Gleixnera5a1d1c2016-12-21 20:32:01 +0100139 return (((u64)h) << 32) | l;
Vineet Guptaaa93e8e2013-11-07 14:57:16 +0530140}
141
Vineet Guptae608b532016-01-01 18:05:48 +0530142static struct clocksource arc_counter_rtc = {
Vineet Guptaaa93e8e2013-11-07 14:57:16 +0530143 .name = "ARCv2 RTC",
144 .rating = 350,
Vineet Guptae608b532016-01-01 18:05:48 +0530145 .read = arc_read_rtc,
Vineet Guptaaa93e8e2013-11-07 14:57:16 +0530146 .mask = CLOCKSOURCE_MASK(64),
147 .flags = CLOCK_SOURCE_IS_CONTINUOUS,
148};
149
Daniel Lezcano43d75602016-06-15 14:50:12 +0200150static int __init arc_cs_setup_rtc(struct device_node *node)
Vineet Guptae608b532016-01-01 18:05:48 +0530151{
Vineet Guptaec7cb872016-10-31 13:02:31 -0700152 struct bcr_timer timer;
Vineet Guptae608b532016-01-01 18:05:48 +0530153 int ret;
154
Vineet Guptaec7cb872016-10-31 13:02:31 -0700155 READ_BCR(ARC_REG_TIMERS_BCR, timer);
156 if (!timer.rtc) {
Rafał Miłeckiac9ce6d2017-03-09 10:47:10 +0100157 pr_warn("Local-64-bit-Ctr clocksource not detected\n");
Daniel Lezcano43d75602016-06-15 14:50:12 +0200158 return -ENXIO;
Vineet Guptaec7cb872016-10-31 13:02:31 -0700159 }
Vineet Guptae608b532016-01-01 18:05:48 +0530160
161 /* Local to CPU hence not usable in SMP */
Vineet Guptaec7cb872016-10-31 13:02:31 -0700162 if (IS_ENABLED(CONFIG_SMP)) {
Rafał Miłeckiac9ce6d2017-03-09 10:47:10 +0100163 pr_warn("Local-64-bit-Ctr not usable in SMP\n");
Daniel Lezcano43d75602016-06-15 14:50:12 +0200164 return -EINVAL;
Vineet Guptaec7cb872016-10-31 13:02:31 -0700165 }
Vineet Guptae608b532016-01-01 18:05:48 +0530166
167 ret = arc_get_timer_clk(node);
168 if (ret)
Daniel Lezcano43d75602016-06-15 14:50:12 +0200169 return ret;
Vineet Guptae608b532016-01-01 18:05:48 +0530170
171 write_aux_reg(AUX_RTC_CTRL, 1);
172
Daniel Lezcano43d75602016-06-15 14:50:12 +0200173 return clocksource_register_hz(&arc_counter_rtc, arc_timer_freq);
Vineet Guptae608b532016-01-01 18:05:48 +0530174}
Daniel Lezcano17273392017-05-26 16:56:11 +0200175TIMER_OF_DECLARE(arc_rtc, "snps,archs-timer-rtc", arc_cs_setup_rtc);
Vineet Guptae608b532016-01-01 18:05:48 +0530176
177#endif
Vineet Guptaaa93e8e2013-11-07 14:57:16 +0530178
Vineet Guptad8005e62013-01-18 15:12:18 +0530179/*
Vineet Guptae608b532016-01-01 18:05:48 +0530180 * 32bit TIMER1 to keep counting monotonically and wraparound
Vineet Guptad8005e62013-01-18 15:12:18 +0530181 */
Vineet Guptad8005e62013-01-18 15:12:18 +0530182
Thomas Gleixnera5a1d1c2016-12-21 20:32:01 +0100183static u64 arc_read_timer1(struct clocksource *cs)
Vineet Guptad8005e62013-01-18 15:12:18 +0530184{
Thomas Gleixnera5a1d1c2016-12-21 20:32:01 +0100185 return (u64) read_aux_reg(ARC_REG_TIMER1_CNT);
Vineet Guptad8005e62013-01-18 15:12:18 +0530186}
187
Vineet Guptae608b532016-01-01 18:05:48 +0530188static struct clocksource arc_counter_timer1 = {
Vineet Guptad8005e62013-01-18 15:12:18 +0530189 .name = "ARC Timer1",
190 .rating = 300,
Vineet Guptae608b532016-01-01 18:05:48 +0530191 .read = arc_read_timer1,
Vineet Guptad8005e62013-01-18 15:12:18 +0530192 .mask = CLOCKSOURCE_MASK(32),
193 .flags = CLOCK_SOURCE_IS_CONTINUOUS,
194};
195
Daniel Lezcano43d75602016-06-15 14:50:12 +0200196static int __init arc_cs_setup_timer1(struct device_node *node)
Vineet Guptae608b532016-01-01 18:05:48 +0530197{
198 int ret;
199
200 /* Local to CPU hence not usable in SMP */
201 if (IS_ENABLED(CONFIG_SMP))
Daniel Lezcano43d75602016-06-15 14:50:12 +0200202 return -EINVAL;
Vineet Guptae608b532016-01-01 18:05:48 +0530203
204 ret = arc_get_timer_clk(node);
205 if (ret)
Daniel Lezcano43d75602016-06-15 14:50:12 +0200206 return ret;
Vineet Guptae608b532016-01-01 18:05:48 +0530207
Vineet Guptab26c2e32016-10-31 13:06:19 -0700208 write_aux_reg(ARC_REG_TIMER1_LIMIT, ARC_TIMERN_MAX);
Vineet Guptae608b532016-01-01 18:05:48 +0530209 write_aux_reg(ARC_REG_TIMER1_CNT, 0);
210 write_aux_reg(ARC_REG_TIMER1_CTRL, TIMER_CTRL_NH);
211
Daniel Lezcano43d75602016-06-15 14:50:12 +0200212 return clocksource_register_hz(&arc_counter_timer1, arc_timer_freq);
Vineet Guptae608b532016-01-01 18:05:48 +0530213}
Vineet Guptaaa93e8e2013-11-07 14:57:16 +0530214
Vineet Guptad8005e62013-01-18 15:12:18 +0530215/********** Clock Event Device *********/
216
Vineet Gupta77c8d0d2016-01-01 17:58:45 +0530217static int arc_timer_irq;
Noam Camuseec3c582016-01-01 15:48:49 +0530218
Vineet Guptad8005e62013-01-18 15:12:18 +0530219/*
Vineet Guptac9a98e182014-06-25 17:14:03 +0530220 * Arm the timer to interrupt after @cycles
Vineet Guptad8005e62013-01-18 15:12:18 +0530221 * The distinction for oneshot/periodic is done in arc_event_timer_ack() below
222 */
Vineet Guptac9a98e182014-06-25 17:14:03 +0530223static void arc_timer_event_setup(unsigned int cycles)
Vineet Guptad8005e62013-01-18 15:12:18 +0530224{
Vineet Guptac9a98e182014-06-25 17:14:03 +0530225 write_aux_reg(ARC_REG_TIMER0_LIMIT, cycles);
Vineet Guptad8005e62013-01-18 15:12:18 +0530226 write_aux_reg(ARC_REG_TIMER0_CNT, 0); /* start from 0 */
227
228 write_aux_reg(ARC_REG_TIMER0_CTRL, TIMER_CTRL_IE | TIMER_CTRL_NH);
229}
230
Vineet Guptad8005e62013-01-18 15:12:18 +0530231
232static int arc_clkevent_set_next_event(unsigned long delta,
233 struct clock_event_device *dev)
234{
235 arc_timer_event_setup(delta);
236 return 0;
237}
238
Viresh Kumaraeec6cd2015-07-16 16:56:14 +0530239static int arc_clkevent_set_periodic(struct clock_event_device *dev)
Vineet Guptad8005e62013-01-18 15:12:18 +0530240{
Viresh Kumaraeec6cd2015-07-16 16:56:14 +0530241 /*
242 * At X Hz, 1 sec = 1000ms -> X cycles;
243 * 10ms -> X / 100 cycles
244 */
Vineet Gupta77c8d0d2016-01-01 17:58:45 +0530245 arc_timer_event_setup(arc_timer_freq / HZ);
Viresh Kumaraeec6cd2015-07-16 16:56:14 +0530246 return 0;
Vineet Guptad8005e62013-01-18 15:12:18 +0530247}
248
249static DEFINE_PER_CPU(struct clock_event_device, arc_clockevent_device) = {
Viresh Kumaraeec6cd2015-07-16 16:56:14 +0530250 .name = "ARC Timer0",
251 .features = CLOCK_EVT_FEAT_ONESHOT |
252 CLOCK_EVT_FEAT_PERIODIC,
253 .rating = 300,
Viresh Kumaraeec6cd2015-07-16 16:56:14 +0530254 .set_next_event = arc_clkevent_set_next_event,
255 .set_state_periodic = arc_clkevent_set_periodic,
Vineet Guptad8005e62013-01-18 15:12:18 +0530256};
257
258static irqreturn_t timer_irq_handler(int irq, void *dev_id)
259{
Vineet Guptaf8b34c32014-01-25 00:42:37 +0530260 /*
261 * Note that generic IRQ core could have passed @evt for @dev_id if
262 * irq_set_chip_and_handler() asked for handle_percpu_devid_irq()
263 */
264 struct clock_event_device *evt = this_cpu_ptr(&arc_clockevent_device);
Viresh Kumaraeec6cd2015-07-16 16:56:14 +0530265 int irq_reenable = clockevent_state_periodic(evt);
Vineet Guptad8005e62013-01-18 15:12:18 +0530266
Vineet Guptaf8b34c32014-01-25 00:42:37 +0530267 /*
Vineet Guptaa4f53852018-02-21 11:31:31 -0800268 * 1. ACK the interrupt
269 * - For ARC700, any write to CTRL reg ACKs it, so just rewrite
270 * Count when [N]ot [H]alted bit.
271 * - For HS3x, it is a bit subtle. On taken count-down interrupt,
272 * IP bit [3] is set, which needs to be cleared for ACK'ing.
273 * The write below can only update the other two bits, hence
274 * explicitly clears IP bit
275 * 2. Re-arm interrupt if periodic by writing to IE bit [0]
Vineet Guptaf8b34c32014-01-25 00:42:37 +0530276 */
277 write_aux_reg(ARC_REG_TIMER0_CTRL, irq_reenable | TIMER_CTRL_NH);
278
279 evt->event_handler(evt);
280
Vineet Guptad8005e62013-01-18 15:12:18 +0530281 return IRQ_HANDLED;
282}
283
Anna-Maria Gleixnerecd80812016-07-13 17:17:07 +0000284
285static int arc_timer_starting_cpu(unsigned int cpu)
Vineet Guptad8005e62013-01-18 15:12:18 +0530286{
Vineet Gupta2d4899f2014-05-08 14:06:38 +0530287 struct clock_event_device *evt = this_cpu_ptr(&arc_clockevent_device);
Vineet Guptad8005e62013-01-18 15:12:18 +0530288
Noam Camuseec3c582016-01-01 15:48:49 +0530289 evt->cpumask = cpumask_of(smp_processor_id());
290
Vineet Guptab26c2e32016-10-31 13:06:19 -0700291 clockevents_config_and_register(evt, arc_timer_freq, 0, ARC_TIMERN_MAX);
Anna-Maria Gleixnerecd80812016-07-13 17:17:07 +0000292 enable_percpu_irq(arc_timer_irq, 0);
293 return 0;
Noam Camuseec3c582016-01-01 15:48:49 +0530294}
295
Anna-Maria Gleixnerecd80812016-07-13 17:17:07 +0000296static int arc_timer_dying_cpu(unsigned int cpu)
297{
298 disable_percpu_irq(arc_timer_irq);
299 return 0;
300}
Noam Camuseec3c582016-01-01 15:48:49 +0530301
302/*
303 * clockevent setup for boot CPU
304 */
Daniel Lezcano43d75602016-06-15 14:50:12 +0200305static int __init arc_clockevent_setup(struct device_node *node)
Noam Camuseec3c582016-01-01 15:48:49 +0530306{
307 struct clock_event_device *evt = this_cpu_ptr(&arc_clockevent_device);
308 int ret;
309
Vineet Gupta77c8d0d2016-01-01 17:58:45 +0530310 arc_timer_irq = irq_of_parse_and_map(node, 0);
Daniel Lezcano43d75602016-06-15 14:50:12 +0200311 if (arc_timer_irq <= 0) {
Rafał Miłeckiac9ce6d2017-03-09 10:47:10 +0100312 pr_err("clockevent: missing irq\n");
Daniel Lezcano43d75602016-06-15 14:50:12 +0200313 return -EINVAL;
314 }
Vineet Gupta77c8d0d2016-01-01 17:58:45 +0530315
316 ret = arc_get_timer_clk(node);
Daniel Lezcano43d75602016-06-15 14:50:12 +0200317 if (ret) {
Rafał Miłeckiac9ce6d2017-03-09 10:47:10 +0100318 pr_err("clockevent: missing clk\n");
Daniel Lezcano43d75602016-06-15 14:50:12 +0200319 return ret;
320 }
Vineet Gupta77c8d0d2016-01-01 17:58:45 +0530321
Noam Camuseec3c582016-01-01 15:48:49 +0530322 /* Needs apriori irq_set_percpu_devid() done in intc map function */
323 ret = request_percpu_irq(arc_timer_irq, timer_irq_handler,
324 "Timer0 (per-cpu-tick)", evt);
Daniel Lezcano43d75602016-06-15 14:50:12 +0200325 if (ret) {
326 pr_err("clockevent: unable to request irq\n");
327 return ret;
328 }
Vineet Gupta56957942016-01-28 12:56:03 +0530329
Anna-Maria Gleixnerecd80812016-07-13 17:17:07 +0000330 ret = cpuhp_setup_state(CPUHP_AP_ARC_TIMER_STARTING,
Thomas Gleixner73c1b412016-12-21 20:19:54 +0100331 "clockevents/arc/timer:starting",
Anna-Maria Gleixnerecd80812016-07-13 17:17:07 +0000332 arc_timer_starting_cpu,
333 arc_timer_dying_cpu);
334 if (ret) {
Rafał Miłeckiac9ce6d2017-03-09 10:47:10 +0100335 pr_err("Failed to setup hotplug state\n");
Anna-Maria Gleixnerecd80812016-07-13 17:17:07 +0000336 return ret;
337 }
Daniel Lezcano43d75602016-06-15 14:50:12 +0200338 return 0;
Vineet Guptad8005e62013-01-18 15:12:18 +0530339}
Vineet Guptae608b532016-01-01 18:05:48 +0530340
Daniel Lezcano43d75602016-06-15 14:50:12 +0200341static int __init arc_of_timer_init(struct device_node *np)
Vineet Guptae608b532016-01-01 18:05:48 +0530342{
343 static int init_count = 0;
Daniel Lezcano43d75602016-06-15 14:50:12 +0200344 int ret;
Vineet Guptae608b532016-01-01 18:05:48 +0530345
346 if (!init_count) {
347 init_count = 1;
Daniel Lezcano43d75602016-06-15 14:50:12 +0200348 ret = arc_clockevent_setup(np);
Vineet Guptae608b532016-01-01 18:05:48 +0530349 } else {
Daniel Lezcano43d75602016-06-15 14:50:12 +0200350 ret = arc_cs_setup_timer1(np);
Vineet Guptae608b532016-01-01 18:05:48 +0530351 }
Daniel Lezcano43d75602016-06-15 14:50:12 +0200352
353 return ret;
Vineet Guptae608b532016-01-01 18:05:48 +0530354}
Daniel Lezcano17273392017-05-26 16:56:11 +0200355TIMER_OF_DECLARE(arc_clkevt, "snps,arc-timer", arc_of_timer_init);