qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] replacing gettimeofday with clock_gettime in hw


From: Anthony Liguori
Subject: Re: [Qemu-devel] [PATCH] replacing gettimeofday with clock_gettime in hw/serial
Date: Wed, 30 Jul 2008 09:15:14 -0500
User-agent: Thunderbird 2.0.0.14 (X11/20080501)

Paul Brook wrote:
On Wednesday 30 July 2008, Stefano Stabellini wrote:
This patch substitutes gettimeofday with clock_gettime in hw/serial.c.

gettimeofday is unsafe because can lead to incorrect behaviors if the user
changes the system's date.

This code is just plain wrong to start with. Devices should not depend on host time.

Because host time continues even when the guest is stopped. It should instead be based on the vm_clock.

I don't think it works either. I still have gotten messages in the guest about too many interrupts on the serial port.

Regards,

Anthony Liguori

Paul







reply via email to

[Prev in Thread] Current Thread [Next in Thread]