[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [RFC] [PATCHv8 01/30] aio / timers: Rename qemu_new_clock a
From: |
Alex Bligh |
Subject: |
[Qemu-devel] [RFC] [PATCHv8 01/30] aio / timers: Rename qemu_new_clock and expose clock types |
Date: |
Thu, 8 Aug 2013 22:41:58 +0100 |
Rename qemu_new_clock to qemu_clock_new.
Expose clock types.
Signed-off-by: Alex Bligh <address@hidden>
---
include/qemu/timer.h | 4 ++++
qemu-timer.c | 12 ++++--------
2 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/include/qemu/timer.h b/include/qemu/timer.h
index 9dd206c..45c745b 100644
--- a/include/qemu/timer.h
+++ b/include/qemu/timer.h
@@ -11,6 +11,10 @@
#define SCALE_US 1000
#define SCALE_NS 1
+#define QEMU_CLOCK_REALTIME 0
+#define QEMU_CLOCK_VIRTUAL 1
+#define QEMU_CLOCK_HOST 2
+
typedef struct QEMUClock QEMUClock;
typedef void QEMUTimerCB(void *opaque);
diff --git a/qemu-timer.c b/qemu-timer.c
index b2d95e2..2d97a13 100644
--- a/qemu-timer.c
+++ b/qemu-timer.c
@@ -40,10 +40,6 @@
/***********************************************************/
/* timers */
-#define QEMU_CLOCK_REALTIME 0
-#define QEMU_CLOCK_VIRTUAL 1
-#define QEMU_CLOCK_HOST 2
-
struct QEMUClock {
QEMUTimer *active_timers;
@@ -231,7 +227,7 @@ QEMUClock *rt_clock;
QEMUClock *vm_clock;
QEMUClock *host_clock;
-static QEMUClock *qemu_new_clock(int type)
+static QEMUClock *qemu_clock_new(int type)
{
QEMUClock *clock;
@@ -433,9 +429,9 @@ void qemu_unregister_clock_reset_notifier(QEMUClock *clock,
Notifier *notifier)
void init_clocks(void)
{
if (!rt_clock) {
- rt_clock = qemu_new_clock(QEMU_CLOCK_REALTIME);
- vm_clock = qemu_new_clock(QEMU_CLOCK_VIRTUAL);
- host_clock = qemu_new_clock(QEMU_CLOCK_HOST);
+ rt_clock = qemu_clock_new(QEMU_CLOCK_REALTIME);
+ vm_clock = qemu_clock_new(QEMU_CLOCK_VIRTUAL);
+ host_clock = qemu_clock_new(QEMU_CLOCK_HOST);
}
}
--
1.7.9.5
- [Qemu-devel] [RFC] [PATCHv8 00/30] aio / timers: Add AioContext timers and use ppoll, Alex Bligh, 2013/08/08
- [Qemu-devel] [RFC] [PATCHv8 03/30] aio / timers: Consistent treatment of disabled clocks for deadlines, Alex Bligh, 2013/08/08
- [Qemu-devel] [RFC] [PATCHv8 04/30] aio / timers: add ppoll support with qemu_poll_ns, Alex Bligh, 2013/08/08
- [Qemu-devel] [RFC] [PATCHv8 05/30] aio / timers: Add prctl(PR_SET_TIMERSLACK, 1, ...) to reduce timer slack, Alex Bligh, 2013/08/08
- [Qemu-devel] [RFC] [PATCHv8 01/30] aio / timers: Rename qemu_new_clock and expose clock types,
Alex Bligh <=
- [Qemu-devel] [RFC] [PATCHv8 06/30] aio / timers: Make qemu_run_timers and qemu_run_all_timers return progress, Alex Bligh, 2013/08/08
- [Qemu-devel] [RFC] [PATCHv8 09/30] aio / timers: Add QEMUTimerListGroup and helper functions, Alex Bligh, 2013/08/08
- Re: [Qemu-devel] [RFC] [PATCHv8 09/30] aio / timers: Add QEMUTimerListGroup and helper functions, Paolo Bonzini, 2013/08/09
- Re: [Qemu-devel] [RFC] [PATCHv8 09/30] aio / timers: Add QEMUTimerListGroup and helper functions, Alex Bligh, 2013/08/09
- Re: [Qemu-devel] [RFC] [PATCHv8 09/30] aio / timers: Add QEMUTimerListGroup and helper functions, Paolo Bonzini, 2013/08/09
- Re: [Qemu-devel] [RFC] [PATCHv8 09/30] aio / timers: Add QEMUTimerListGroup and helper functions, Alex Bligh, 2013/08/09
- Re: [Qemu-devel] [RFC] [PATCHv8 09/30] aio / timers: Add QEMUTimerListGroup and helper functions, Paolo Bonzini, 2013/08/09
- Re: [Qemu-devel] [RFC] [PATCHv8 09/30] aio / timers: Add QEMUTimerListGroup and helper functions, Alex Bligh, 2013/08/10
- Re: [Qemu-devel] [RFC] [PATCHv8 09/30] aio / timers: Add QEMUTimerListGroup and helper functions, Paolo Bonzini, 2013/08/11
- Re: [Qemu-devel] [RFC] [PATCHv8 09/30] aio / timers: Add QEMUTimerListGroup and helper functions, Alex Bligh, 2013/08/11