* error while loading state for instance 0x0 of device 'kvmclock'
@ 2009-11-02 8:36 Jan Kiszka
2009-11-02 10:28 ` Jan Kiszka
0 siblings, 1 reply; 6+ messages in thread
From: Jan Kiszka @ 2009-11-02 8:36 UTC (permalink / raw)
To: kvm
[-- Attachment #1: Type: text/plain, Size: 217 bytes --]
Hi,
current qemu-kvm.git gives me the message "qemu: warning: error while
loading state for instance 0x0 of device 'kvmclock'" when I run a simple
"savevm" followed by a "loadvm 1". What's broken here?
Jan
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 257 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: error while loading state for instance 0x0 of device 'kvmclock'
2009-11-02 8:36 error while loading state for instance 0x0 of device 'kvmclock' Jan Kiszka
@ 2009-11-02 10:28 ` Jan Kiszka
2009-11-02 12:29 ` Marcelo Tosatti
2009-11-02 13:36 ` Avi Kivity
0 siblings, 2 replies; 6+ messages in thread
From: Jan Kiszka @ 2009-11-02 10:28 UTC (permalink / raw)
To: Marcelo Tosatti, Glauber Costa; +Cc: kvm
Jan Kiszka wrote:
> Hi,
>
> current qemu-kvm.git gives me the message "qemu: warning: error while
> loading state for instance 0x0 of device 'kvmclock'" when I run a simple
> "savevm" followed by a "loadvm 1". What's broken here?
OK, this is due to "KVM: add flags to kvm_clock_data" (958b0c5497): the
flags field is not cleared on KVM_SET_CLOCK. Will post a fix.
But the above kernel commit is also broken: KVM_GET_CLOCK checks
uninitialized user_ns.flags (probably instead of the user's value). This
raises the question if the caller of KVM_GET_CLOCK is also supposed to
pass kvm_clock_data with flags cleared down to the kernel. Could someone
clarify this so I could fix it accordingly?
Jan
--
Siemens AG, Corporate Technology, CT SE 2
Corporate Competence Center Embedded Linux
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: error while loading state for instance 0x0 of device 'kvmclock'
2009-11-02 10:28 ` Jan Kiszka
@ 2009-11-02 12:29 ` Marcelo Tosatti
2009-11-02 13:36 ` Avi Kivity
1 sibling, 0 replies; 6+ messages in thread
From: Marcelo Tosatti @ 2009-11-02 12:29 UTC (permalink / raw)
To: Jan Kiszka; +Cc: Glauber Costa, kvm
On Mon, Nov 02, 2009 at 11:28:38AM +0100, Jan Kiszka wrote:
> Jan Kiszka wrote:
> > Hi,
> >
> > current qemu-kvm.git gives me the message "qemu: warning: error while
> > loading state for instance 0x0 of device 'kvmclock'" when I run a simple
> > "savevm" followed by a "loadvm 1". What's broken here?
>
> OK, this is due to "KVM: add flags to kvm_clock_data" (958b0c5497): the
> flags field is not cleared on KVM_SET_CLOCK. Will post a fix.
>
> But the above kernel commit is also broken: KVM_GET_CLOCK checks
> uninitialized user_ns.flags (probably instead of the user's value). This
> raises the question if the caller of KVM_GET_CLOCK is also supposed to
> pass kvm_clock_data with flags cleared down to the kernel. Could someone
> clarify this so I could fix it accordingly?
Yes userspace is supposed to clear flags. My bad.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: error while loading state for instance 0x0 of device 'kvmclock'
2009-11-02 10:28 ` Jan Kiszka
2009-11-02 12:29 ` Marcelo Tosatti
@ 2009-11-02 13:36 ` Avi Kivity
2009-11-02 15:37 ` Jan Kiszka
1 sibling, 1 reply; 6+ messages in thread
From: Avi Kivity @ 2009-11-02 13:36 UTC (permalink / raw)
To: Jan Kiszka; +Cc: Marcelo Tosatti, Glauber Costa, kvm
On 11/02/2009 12:28 PM, Jan Kiszka wrote:
> Jan Kiszka wrote:
>
>> Hi,
>>
>> current qemu-kvm.git gives me the message "qemu: warning: error while
>> loading state for instance 0x0 of device 'kvmclock'" when I run a simple
>> "savevm" followed by a "loadvm 1". What's broken here?
>>
> OK, this is due to "KVM: add flags to kvm_clock_data" (958b0c5497): the
> flags field is not cleared on KVM_SET_CLOCK. Will post a fix.
>
> But the above kernel commit is also broken: KVM_GET_CLOCK checks
> uninitialized user_ns.flags (probably instead of the user's value). This
> raises the question if the caller of KVM_GET_CLOCK is also supposed to
> pass kvm_clock_data with flags cleared down to the kernel. Could someone
> clarify this so I could fix it accordingly?
>
I'd make KVM_GET_CLOCK set the flags, not get them. So if we add new
fields, we just set a new bit and userspace can read it.
--
error compiling committee.c: too many arguments to function
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: error while loading state for instance 0x0 of device 'kvmclock'
2009-11-02 13:36 ` Avi Kivity
@ 2009-11-02 15:37 ` Jan Kiszka
2009-11-03 10:54 ` Glauber Costa
0 siblings, 1 reply; 6+ messages in thread
From: Jan Kiszka @ 2009-11-02 15:37 UTC (permalink / raw)
To: Avi Kivity; +Cc: Marcelo Tosatti, Glauber Costa, kvm
Avi Kivity wrote:
> On 11/02/2009 12:28 PM, Jan Kiszka wrote:
>> Jan Kiszka wrote:
>>
>>> Hi,
>>>
>>> current qemu-kvm.git gives me the message "qemu: warning: error while
>>> loading state for instance 0x0 of device 'kvmclock'" when I run a simple
>>> "savevm" followed by a "loadvm 1". What's broken here?
>>>
>> OK, this is due to "KVM: add flags to kvm_clock_data" (958b0c5497): the
>> flags field is not cleared on KVM_SET_CLOCK. Will post a fix.
>>
>> But the above kernel commit is also broken: KVM_GET_CLOCK checks
>> uninitialized user_ns.flags (probably instead of the user's value). This
>> raises the question if the caller of KVM_GET_CLOCK is also supposed to
>> pass kvm_clock_data with flags cleared down to the kernel. Could someone
>> clarify this so I could fix it accordingly?
>>
>
> I'd make KVM_GET_CLOCK set the flags, not get them. So if we add new
> fields, we just set a new bit and userspace can read it.
This makes sense and actually fixes the issue completely. Patch on its
way...
Jan
--
Siemens AG, Corporate Technology, CT SE 2
Corporate Competence Center Embedded Linux
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: error while loading state for instance 0x0 of device 'kvmclock'
2009-11-02 15:37 ` Jan Kiszka
@ 2009-11-03 10:54 ` Glauber Costa
0 siblings, 0 replies; 6+ messages in thread
From: Glauber Costa @ 2009-11-03 10:54 UTC (permalink / raw)
To: Jan Kiszka; +Cc: Avi Kivity, Marcelo Tosatti, kvm
On Mon, Nov 02, 2009 at 04:37:15PM +0100, Jan Kiszka wrote:
> Avi Kivity wrote:
> > On 11/02/2009 12:28 PM, Jan Kiszka wrote:
> >> Jan Kiszka wrote:
> >>
> >>> Hi,
> >>>
> >>> current qemu-kvm.git gives me the message "qemu: warning: error while
> >>> loading state for instance 0x0 of device 'kvmclock'" when I run a simple
> >>> "savevm" followed by a "loadvm 1". What's broken here?
> >>>
> >> OK, this is due to "KVM: add flags to kvm_clock_data" (958b0c5497): the
> >> flags field is not cleared on KVM_SET_CLOCK. Will post a fix.
> >>
> >> But the above kernel commit is also broken: KVM_GET_CLOCK checks
> >> uninitialized user_ns.flags (probably instead of the user's value). This
> >> raises the question if the caller of KVM_GET_CLOCK is also supposed to
> >> pass kvm_clock_data with flags cleared down to the kernel. Could someone
> >> clarify this so I could fix it accordingly?
> >>
> >
> > I'd make KVM_GET_CLOCK set the flags, not get them. So if we add new
> > fields, we just set a new bit and userspace can read it.
>
> This makes sense and actually fixes the issue completely. Patch on its
> way...
agreed. This is the best behaviour I can devise, indeed.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2009-11-03 10:54 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-11-02 8:36 error while loading state for instance 0x0 of device 'kvmclock' Jan Kiszka
2009-11-02 10:28 ` Jan Kiszka
2009-11-02 12:29 ` Marcelo Tosatti
2009-11-02 13:36 ` Avi Kivity
2009-11-02 15:37 ` Jan Kiszka
2009-11-03 10:54 ` Glauber Costa
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.