[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [RFC] [PATCHv6 01/16] aio / timers: add qemu-timer.c ut
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [RFC] [PATCHv6 01/16] aio / timers: add qemu-timer.c utility functions |
Date: |
Tue, 6 Aug 2013 15:59:11 +0200 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
On Tue, Aug 06, 2013 at 01:30:18PM +0100, Alex Bligh wrote:
> --On 6 August 2013 14:02:18 +0200 Stefan Hajnoczi
> <address@hidden> wrote:
> My preference would be to move these to qemu_clock_deadline_ns (without
> the INT32_MAX check) and delete the old qemu_clock_deadline routine
> entirely, but I don't really understand the full set of circumstances
> in which the qtest routines are meant to work.
Okay, that's excellent. It would be great to move to a single function.
The way qtest works is that it executes QEMU in a mode that does not run
guest code. Instead of running guest code it listens for commands over
a socket. The wire protocol can peek/poke memory, notify of interrupts,
and warp the clock.
There are test cases that use qtest to test emulated devices.
When qtest either steps the clock or sets it to a completely new value
using qtest_clock_warp() it runs all vm_clock timers that should expire
before the new time.
Does this help?
> >Please include
> >an explanation of why qemu_timeout_ns_to_ms() will be needed in the
> >future (there are no callers in this patch).
>
> You mean in the commit text as well as the following?
>
> +/* Transition function to convert a nanosecond timeout to ms
> + * This is used where a system does not support ppoll
> + */
Usually a doc comment is enough since it explains what the function
does. If it's a low-level function is may be necessary to give more
context in the commit description.
Stefan
- [Qemu-devel] [RFC] [PATCHv6 06/16] aio / timers: Untangle include files, (continued)
- [Qemu-devel] [RFC] [PATCHv6 09/16] aio / timers: Add a notify callback to QEMUTimerList, Alex Bligh, 2013/08/06
- Re: [Qemu-devel] [RFC] [PATCHv6 09/16] aio / timers: Add a notify callback to QEMUTimerList, Stefan Hajnoczi, 2013/08/06
- Re: [Qemu-devel] [RFC] [PATCHv6 09/16] aio / timers: Add a notify callback to QEMUTimerList, Alex Bligh, 2013/08/06
- [Qemu-devel] [RFC] [PATCHv6 01/16] aio / timers: add qemu-timer.c utility functions, Alex Bligh, 2013/08/06
- Re: [Qemu-devel] [RFC] [PATCHv6 01/16] aio / timers: add qemu-timer.c utility functions, Stefan Hajnoczi, 2013/08/06
- Re: [Qemu-devel] [RFC] [PATCHv6 01/16] aio / timers: add qemu-timer.c utility functions, Alex Bligh, 2013/08/06
- Re: [Qemu-devel] [RFC] [PATCHv6 01/16] aio / timers: add qemu-timer.c utility functions,
Stefan Hajnoczi <=
- Re: [Qemu-devel] [RFC] [PATCHv6 01/16] aio / timers: add qemu-timer.c utility functions, Alex Bligh, 2013/08/06
- Re: [Qemu-devel] [RFC] [PATCHv6 01/16] aio / timers: add qemu-timer.c utility functions, Stefan Hajnoczi, 2013/08/07
- Re: [Qemu-devel] [RFC] [PATCHv6 01/16] aio / timers: add qemu-timer.c utility functions, Alex Bligh, 2013/08/07
- [Qemu-devel] [RFC] [PATCHv6 11/16] aio / timers: Convert aio_poll to use AioContext timers' deadline, Alex Bligh, 2013/08/06
- [Qemu-devel] [RFC] [PATCHv6 12/16] aio / timers: Convert mainloop to use timeout, Alex Bligh, 2013/08/06
- [Qemu-devel] [RFC] [PATCHv6 13/16] aio / timers: On timer modification, qemu_notify or aio_notify, Alex Bligh, 2013/08/06
- [Qemu-devel] [RFC] [PATCHv6 14/16] aio / timers: Use all timerlists in icount warp calculations, Alex Bligh, 2013/08/06
- [Qemu-devel] [RFC] [PATCHv6 16/16] aio / timers: Add test harness for AioContext timers, Alex Bligh, 2013/08/06
- [Qemu-devel] [RFC] [PATCHv6 02/16] aio / timers: add ppoll support with qemu_poll_ns, Alex Bligh, 2013/08/06
- [Qemu-devel] [RFC] [PATCHv6 15/16] aio / timers: Remove alarm timers, Alex Bligh, 2013/08/06