On 01/31/2014 03:29 AM, Michal Privoznik wrote: > As the description to the guest-set-time states, the command is > there to ease time synchronization after resume. If guest was > suspended for longer period of time, its system time can go off > so badly, that even NTP refuses to set it. That's why the command > was invented: to give users chance to set the time (not > necessarily 100% correct). However, there's is no real need for > us to require users to pass an arbitrary time. Especially if we > can read the correct value from RTC (boiling down to reading > host's time). Hence this commit enables logic: > > guest-set-time() == guest-set-time($now_from_rtc) > > Signed-off-by: Michal Privoznik <mpriv...@redhat.com> > --- > diff to v1: > -Fix checkpatch.pl warnings > > qga/commands-posix.c | 41 +++++++++++++++++++++++++---------------- > qga/commands-win32.c | 34 +++++++++++++++++++++++----------- > qga/qapi-schema.json | 9 +++++---- > 3 files changed, 53 insertions(+), 31 deletions(-)
Reviewed-by: Eric Blake <ebl...@redhat.com> Conversion from mandatory to optional is backward-compatible. I'm not sure if it worth some sort of annotation when it was made optional; maybe: # @time: (#optional since 2.0) time of nanoseconds, relative to the # Epoch of 1970-01-01 in UTC. we don't have much precedent for that sort of change, but documenting it may make it more obvious to a user that older agents require an argument. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature