[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 1/1] Make vmport an optional feature at run time
Re: [Qemu-devel] [PATCH 1/1] Make vmport an optional feature at run time.
Sat, 06 Sep 2008 21:24:45 -0500
Thunderbird 22.214.171.124 (X11/20080723)
Todd T. Fries wrote:
Just incase a 'more complete' vmport codeset is useful, here is my
stab at extending it. I haven't extended it far enough yet that
OpenBSD's vmt(4) interface works, but would be more than happy
if someone else were to carry this flag and run with it..
+static uint32_t vmport_cmd_get_time(void *opaque, uint32_t addr)
+ CPUState *env = opaque;
+ struct timeval tv;
+ gettimeofday(&tv, NULL);
+ env->regs[R_EAX] = tv.tv_sec;
+ env->regs[R_EBX] = tv.tv_usec;
+ return tv.tv_sec;
FWIW, this is incorrect. You are presenting the host's version of wall
clock time, not the guest's version.
- Re: [Qemu-devel] [PATCH 1/1] Make vmport an optional feature at run time.,
Anthony Liguori <=