mc146818rtc: add rtc-reset-reinjection QMP command

It is necessary to reset RTC interrupt reinjection backlog if
guest time is synchronized via a different mechanism, such as
QGA's guest-set-time command.

Failing to do so causes both corrections to be applied (summed),
resulting in an incorrect guest time.

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
Marcelo Tosatti 2014-06-24 18:55:11 -03:00 committed by Michael S. Tsirkin
parent fa118d1f8b
commit f2ae8abf1f
4 changed files with 60 additions and 0 deletions

View file

@ -5441,3 +5441,10 @@ QemuOptsList qemu_mon_opts = {
{ /* end of list */ }
},
};
#ifndef TARGET_I386
void qmp_rtc_reset_reinjection(Error **errp)
{
error_set(errp, QERR_FEATURE_DISABLED, "rtc-reset-reinjection");
}
#endif