Skip to contentSkip to conversation

qemu-timer: Remove unused timer functions

PATCH In review [email protected] 2 participants 2 messages Sep 19, 2024 – Sep 26, 2024

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 qemu-timer: Remove unused timer functions

From: "Dr. David Alan Gilbert" <[email protected]>

qemu_clock_get_main_loop_timerlist and timerlist_get_clock have been unused since they were originally added in
ff83c66ecc ("aio / timers: Split QEMUClock into QEMUClock and QEMUTimerList")

Remove them.

---
 include/qemu/timer.h | 21 ---------------------
 util/qemu-timer.c    | 10 ----------
 2 files changed, 31 deletions(-)
include/qemu/timer.h +0 -21
index fa56ec9481..cc167bd825 100644
@@ -190,16 +190,6 @@ bool qemu_clock_use_for_deadline(QEMUClockType type);
  */
 int64_t qemu_clock_deadline_ns_all(QEMUClockType type, int attr_mask);
 
-/**
- * qemu_clock_get_main_loop_timerlist:
- * @type: the clock type
- *
- * Return the default timer list associated with a clock.
- *
- * Returns: the default timer list
- */
-QEMUTimerList *qemu_clock_get_main_loop_timerlist(QEMUClockType type);
-
 /**
  * qemu_clock_nofify:
  * @type: the clock type
@@ -326,17 +316,6 @@ bool timerlist_expired(QEMUTimerList *timer_list);
  */
 int64_t timerlist_deadline_ns(QEMUTimerList *timer_list);
 
-/**
- * timerlist_get_clock:
- * @timer_list: the timer list to operate on
- *
- * Determine the clock type associated with a timer list.
- *
- * Returns: the clock type associated with the
- * timer list.
- */
-QEMUClockType timerlist_get_clock(QEMUTimerList *timer_list);
-
 /**
  * timerlist_run_timers:
  * @timer_list: the timer list to use
util/qemu-timer.c +0 -10
index 213114be68..df9327657a 100644
@@ -286,16 +286,6 @@ int64_t qemu_clock_deadline_ns_all(QEMUClockType type, int attr_mask)
     return deadline;
 }
 
-QEMUClockType timerlist_get_clock(QEMUTimerList *timer_list)
-{
-    return timer_list->clock->type;
-}
-
-QEMUTimerList *qemu_clock_get_main_loop_timerlist(QEMUClockType type)
-{
-    return main_loop_tlg.tl[type];
-}
-
 void timerlist_notify(QEMUTimerList *timer_list)
 {
     if (timer_list->notify_cb) {
Signature · 1 line
2.46.1
Reviewed-by on v2 1/1
#1 lore raw

Am 19. September 2024 14:41:24 UTC schrieb [email protected]:

Quoted 9 lines

From: "Dr. David Alan Gilbert" <[email protected]>

qemu_clock_get_main_loop_timerlist and timerlist_get_clock have been unused since they were originally added in
ff83c66ecc ("aio / timers: Split QEMUClock into QEMUClock and QEMUTimerList")

Remove them.

Quoted 65 lines

---
include/qemu/timer.h | 21 ---------------------
util/qemu-timer.c | 10 ----------

2 files changed, 31 deletions(-)
include/qemu/timer.h +0 -21
index fa56ec9481..cc167bd825 100644
@@ -190,16 +190,6 @@ bool qemu_clock_use_for_deadline(QEMUClockType type);
 */
 int64_t qemu_clock_deadline_ns_all(QEMUClockType type, int attr_mask);
 
-/**
- * qemu_clock_get_main_loop_timerlist:
- * @type: the clock type
- *
- * Return the default timer list associated with a clock.
- *
- * Returns: the default timer list
- */
-QEMUTimerList *qemu_clock_get_main_loop_timerlist(QEMUClockType type);
-
 /**
 * qemu_clock_nofify:
 * @type: the clock type
@@ -326,17 +316,6 @@ bool timerlist_expired(QEMUTimerList *timer_list);
 */
 int64_t timerlist_deadline_ns(QEMUTimerList *timer_list);
 
-/**
- * timerlist_get_clock:
- * @timer_list: the timer list to operate on
- *
- * Determine the clock type associated with a timer list.
- *
- * Returns: the clock type associated with the
- * timer list.
- */
-QEMUClockType timerlist_get_clock(QEMUTimerList *timer_list);
-
 /**
 * timerlist_run_timers:
 * @timer_list: the timer list to use
util/qemu-timer.c +0 -10
index 213114be68..df9327657a 100644
@@ -286,16 +286,6 @@ int64_t qemu_clock_deadline_ns_all(QEMUClockType type, int attr_mask)
    return deadline;
 }
 
-QEMUClockType timerlist_get_clock(QEMUTimerList *timer_list)
-{
-    return timer_list->clock->type;
-}
-
-QEMUTimerList *qemu_clock_get_main_loop_timerlist(QEMUClockType type)
-{
-    return main_loop_tlg.tl[type];
-}
-
 void timerlist_notify(QEMUTimerList *timer_list)
 {
    if (timer_list->notify_cb) {