2 * Copyright (C) 2017 Julien Desfossez <jdesfossez@efficios.com>
3 * Copyright (C) 2018 Jérémie Galarneau <jeremie.galarneau@efficios.com>
5 * SPDX-License-Identifier: GPL-2.0-only
9 #ifndef SESSIOND_TIMER_H
10 #define SESSIOND_TIMER_H
15 #include "session.hpp"
17 struct timer_thread_parameters {
18 struct rotation_thread_timer_queue *rotation_thread_job_queue;
21 int timer_signal_init(void);
23 /* Start a session's rotation pending check timer (one-shot mode). */
24 int timer_session_rotation_pending_check_start(struct ltt_session *session,
25 unsigned int interval_us);
26 /* Stop a session's rotation pending check timer. */
27 int timer_session_rotation_pending_check_stop(struct ltt_session *session);
29 /* Start a session's rotation schedule timer. */
30 int timer_session_rotation_schedule_timer_start(struct ltt_session *session,
31 unsigned int interval_us);
32 /* Stop a session's rotation schedule timer. */
33 int timer_session_rotation_schedule_timer_stop(struct ltt_session *session);
35 bool launch_timer_thread(
36 struct timer_thread_parameters *timer_thread_parameters);
38 #endif /* SESSIOND_TIMER_H */