diff options
author | bellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162> | 2006-05-01 13:28:36 +0000 |
---|---|---|
committer | bellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162> | 2006-05-01 13:28:36 +0000 |
commit | 29e3055c370c2fae64470cdce213607d4fa4d85c (patch) | |
tree | e1a5b961a32df8c925873b6420b525f11fed9e98 /vl.c | |
parent | 06d9f2f7d468d8ffdae107f33bc0391e42f4c6b7 (diff) |
workaround: force /dev/rtc usage on Linux
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1886 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'vl.c')
-rw-r--r-- | vl.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -1023,7 +1023,11 @@ static void init_timers(void) getitimer(ITIMER_REAL, &itv); #if defined(__linux__) - if (itv.it_interval.tv_usec > 1000) { + /* XXX: force /dev/rtc usage because even 2.6 kernels may not + have timers with 1 ms resolution. The correct solution will + be to use the POSIX real time timers available in recent + 2.6 kernels */ + if (itv.it_interval.tv_usec > 1000 || 1) { /* try to use /dev/rtc to have a faster timer */ if (start_rtc_timer() < 0) goto use_itimer; |