Re: [PATCH] kvm: fix poison overwritten caused by using wrong xstate size

2010-08-15 Thread H. Peter Anvin
Feel free to add my ack. "Avi Kivity" wrote: > On 08/14/2010 12:03 AM, H. Peter Anvin wrote: >> Avi, do you want to take this one or should I? > >I will, thanks. > >-- >error compiling committee.c: too many arguments to function > -- Sent from my mobile phone. Please pardon any lack of form

Re: [PATCH] kvm: fix poison overwritten caused by using wrong xstate size

2010-08-15 Thread Avi Kivity
On 08/14/2010 12:03 AM, H. Peter Anvin wrote: Avi, do you want to take this one or should I? I will, thanks. -- error compiling committee.c: too many arguments to function -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger.kernel.org

Re: [PATCH] kvm: fix poison overwritten caused by using wrong xstate size

2010-08-15 Thread Avi Kivity
On 08/13/2010 10:19 AM, Xiaotian Feng wrote: fpu.state is allocated from task_xstate_cachep, the size of task_xstate_cachep is xstate_size. xstate_size is set from cpuid instruction, which is often smaller than sizeof(struct xsave_struct). kvm is using sizeof(struct xsave_struct) to fill in/out

Re: [PATCH] kvm: fix poison overwritten caused by using wrong xstate size

2010-08-13 Thread H. Peter Anvin
Avi, do you want to take this one or should I? -hpa On 08/13/2010 12:19 AM, Xiaotian Feng wrote: > fpu.state is allocated from task_xstate_cachep, the size of task_xstate_cachep > is xstate_size. xstate_size is set from cpuid instruction, which is often > smaller than sizeof(struct xsave_

Re: [PATCH] kvm: fix poison overwritten caused by using wrong xstate size

2010-08-13 Thread Sheng Yang
On Friday 13 August 2010 15:19:11 Xiaotian Feng wrote: > fpu.state is allocated from task_xstate_cachep, the size of > task_xstate_cachep is xstate_size. xstate_size is set from cpuid > instruction, which is often smaller than sizeof(struct xsave_struct). kvm > is using sizeof(struct xsave_struct)

[PATCH] kvm: fix poison overwritten caused by using wrong xstate size

2010-08-13 Thread Xiaotian Feng
fpu.state is allocated from task_xstate_cachep, the size of task_xstate_cachep is xstate_size. xstate_size is set from cpuid instruction, which is often smaller than sizeof(struct xsave_struct). kvm is using sizeof(struct xsave_struct) to fill in/out fpu.state.xsave, as what we allocated for fpu.s