Lines Matching refs:evt
26 struct clock_event_device evt; member
72 struct hpet_channel *clockevent_to_channel(struct clock_event_device *evt) in clockevent_to_channel() argument
74 return container_of(evt, struct hpet_channel, evt); in clockevent_to_channel()
297 static int hpet_clkevt_set_state_periodic(struct clock_event_device *evt) in hpet_clkevt_set_state_periodic() argument
299 unsigned int channel = clockevent_to_channel(evt)->num; in hpet_clkevt_set_state_periodic()
304 delta = ((uint64_t)(NSEC_PER_SEC / HZ)) * evt->mult; in hpet_clkevt_set_state_periodic()
305 delta >>= evt->shift; in hpet_clkevt_set_state_periodic()
328 static int hpet_clkevt_set_state_oneshot(struct clock_event_device *evt) in hpet_clkevt_set_state_oneshot() argument
330 unsigned int channel = clockevent_to_channel(evt)->num; in hpet_clkevt_set_state_oneshot()
341 static int hpet_clkevt_set_state_shutdown(struct clock_event_device *evt) in hpet_clkevt_set_state_shutdown() argument
343 unsigned int channel = clockevent_to_channel(evt)->num; in hpet_clkevt_set_state_shutdown()
353 static int hpet_clkevt_legacy_resume(struct clock_event_device *evt) in hpet_clkevt_legacy_resume() argument
361 hpet_clkevt_set_next_event(unsigned long delta, struct clock_event_device *evt) in hpet_clkevt_set_next_event() argument
363 unsigned int channel = clockevent_to_channel(evt)->num; in hpet_clkevt_set_next_event()
400 struct clock_event_device *evt = &hc->evt; in hpet_init_clockevent() local
402 evt->rating = rating; in hpet_init_clockevent()
403 evt->irq = hc->irq; in hpet_init_clockevent()
404 evt->name = hc->name; in hpet_init_clockevent()
405 evt->cpumask = cpumask_of(hc->cpu); in hpet_init_clockevent()
406 evt->set_state_oneshot = hpet_clkevt_set_state_oneshot; in hpet_init_clockevent()
407 evt->set_next_event = hpet_clkevt_set_next_event; in hpet_init_clockevent()
408 evt->set_state_shutdown = hpet_clkevt_set_state_shutdown; in hpet_init_clockevent()
410 evt->features = CLOCK_EVT_FEAT_ONESHOT; in hpet_init_clockevent()
412 evt->features |= CLOCK_EVT_FEAT_PERIODIC; in hpet_init_clockevent()
413 evt->set_state_periodic = hpet_clkevt_set_state_periodic; in hpet_init_clockevent()
427 hc->evt.tick_resume = hpet_clkevt_legacy_resume; in hpet_legacy_clockevent_register()
457 hc->evt.features |= CLOCK_EVT_FEAT_PERIODIC; in hpet_legacy_clockevent_register()
458 hc->evt.set_state_periodic = hpet_clkevt_set_state_periodic; in hpet_legacy_clockevent_register()
463 clockevents_config_and_register(&hc->evt, hpet_freq, in hpet_legacy_clockevent_register()
465 global_clock_event = &hc->evt; in hpet_legacy_clockevent_register()
609 static int hpet_clkevt_msi_resume(struct clock_event_device *evt) in hpet_clkevt_msi_resume() argument
611 struct hpet_channel *hc = clockevent_to_channel(evt); in hpet_clkevt_msi_resume()
625 struct clock_event_device *evt = &hc->evt; in hpet_msi_interrupt_handler() local
627 if (!evt->event_handler) { in hpet_msi_interrupt_handler()
632 evt->event_handler(evt); in hpet_msi_interrupt_handler()
655 struct clock_event_device *evt = &hc->evt; in init_one_hpet_msi_clockevent() local
662 evt->tick_resume = hpet_clkevt_msi_resume; in init_one_hpet_msi_clockevent()
664 clockevents_config_and_register(evt, hpet_freq, HPET_MIN_PROG_DELTA, in init_one_hpet_msi_clockevent()
1284 struct clock_event_device *evt = &hpet_base.channels[0].evt; in hpet_rtc_timer_init() local
1287 clc = (uint64_t) evt->mult * NSEC_PER_SEC; in hpet_rtc_timer_init()
1288 clc >>= evt->shift + DEFAULT_RTC_SHIFT; in hpet_rtc_timer_init()
1382 struct clock_event_device *evt = &hpet_base.channels[0].evt; in hpet_set_periodic_freq() local
1384 clc = (uint64_t) evt->mult * NSEC_PER_SEC; in hpet_set_periodic_freq()
1386 clc >>= evt->shift; in hpet_set_periodic_freq()