Lines Matching full:timers
93 * @num_wd_timers: number of rproc watchdog timers
94 * @timers: timer(s) info used by rproc
111 struct omap_rproc_timer *timers; member
263 * timers associated with a rproc (like IPUs which have 2 watchdog timers,
277 struct omap_rproc_timer *timers = oproc->timers; in omap_rproc_watchdog_isr() local
283 if (timers[i].irq > 0 && irq == timers[i].irq) { in omap_rproc_watchdog_isr()
284 wd_timer = &timers[i]; in omap_rproc_watchdog_isr()
302 * omap_rproc_enable_timers() - enable the timers for a remoteproc
306 * This function is used primarily to enable the timers associated with
321 struct omap_rproc_timer *timers = oproc->timers; in omap_rproc_enable_timers() local
334 np = of_parse_phandle(dev->of_node, "ti,timers", i); in omap_rproc_enable_timers()
337 "ti,watchdog-timers", in omap_rproc_enable_timers()
373 timers[i].irq = -1; in omap_rproc_enable_timers()
374 timers[i].timer_ops = timer_ops; in omap_rproc_enable_timers()
375 ret = omap_rproc_request_timer(dev, np, &timers[i]); in omap_rproc_enable_timers()
384 timers[i].irq = omap_rproc_get_timer_irq(&timers[i]); in omap_rproc_enable_timers()
385 if (timers[i].irq < 0) { in omap_rproc_enable_timers()
387 np, timers[i].irq); in omap_rproc_enable_timers()
392 ret = request_irq(timers[i].irq, in omap_rproc_enable_timers()
398 omap_rproc_release_timer(&timers[i]); in omap_rproc_enable_timers()
399 timers[i].odt = NULL; in omap_rproc_enable_timers()
400 timers[i].timer_ops = NULL; in omap_rproc_enable_timers()
401 timers[i].irq = -1; in omap_rproc_enable_timers()
409 ret = omap_rproc_start_timer(&timers[i]); in omap_rproc_enable_timers()
418 omap_rproc_stop_timer(&timers[i]); in omap_rproc_enable_timers()
431 free_irq(timers[i].irq, rproc); in omap_rproc_enable_timers()
432 omap_rproc_release_timer(&timers[i]); in omap_rproc_enable_timers()
433 timers[i].odt = NULL; in omap_rproc_enable_timers()
434 timers[i].timer_ops = NULL; in omap_rproc_enable_timers()
435 timers[i].irq = -1; in omap_rproc_enable_timers()
442 * omap_rproc_disable_timers() - disable the timers for a remoteproc
446 * This function is used primarily to disable the timers associated with
451 * Return: 0 on success or no timers
457 struct omap_rproc_timer *timers = oproc->timers; in omap_rproc_disable_timers() local
464 omap_rproc_stop_timer(&timers[i]); in omap_rproc_disable_timers()
467 free_irq(timers[i].irq, rproc); in omap_rproc_disable_timers()
468 omap_rproc_release_timer(&timers[i]); in omap_rproc_disable_timers()
469 timers[i].odt = NULL; in omap_rproc_disable_timers()
470 timers[i].timer_ops = NULL; in omap_rproc_disable_timers()
471 timers[i].irq = -1; in omap_rproc_disable_timers()
823 dev_err(dev, "disabling timers during suspend failed %d\n", in _omap_rproc_suspend()
882 dev_err(dev, "enabling timers during resume failed %d\n", ret); in _omap_rproc_resume()
1228 ret = of_count_phandle_with_args(np, "ti,watchdog-timers", NULL); in omap_rproc_count_wdog_timers()
1230 dev_dbg(dev, "device does not have watchdog timers, status = %d\n", in omap_rproc_count_wdog_timers()
1256 oproc->num_timers = of_count_phandle_with_args(np, "ti,timers", NULL); in omap_rproc_of_get_timers()
1258 dev_dbg(dev, "device does not have timers, status = %d\n", in omap_rproc_of_get_timers()
1267 oproc->timers = devm_kcalloc(dev, num_timers, in omap_rproc_of_get_timers()
1268 sizeof(*oproc->timers), in omap_rproc_of_get_timers()
1270 if (!oproc->timers) in omap_rproc_of_get_timers()
1273 dev_dbg(dev, "device has %d tick timers and %d watchdog timers\n", in omap_rproc_of_get_timers()