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

Re: [Xen-devel] [RFC Patch v2 45/45] x86/hvm: Always set pending event injection when loading VMC[BS] state.

At 09:58 -0500 on 27 Aug (1409129888), Aravind Gopalakrishnan wrote:
> On 8/26/2014 7:46 PM, Wen Congyang wrote:
> > At 08/27/2014 12:02 AM, Jan Beulich Write:
> >>>>> On 08.08.14 at 09:01, <wency@xxxxxxxxxxxxxx> wrote:
> >>> In colo mode, secondary vm is running, so VM_ENTRY_INTR_INFO may
> >>> valid before restoring vmcs. If there is no pending event after
> >>> restoring vm, we should clear it.
> >>>
> >>> Signed-off-by: Wen Congyang <wency@xxxxxxxxxxxxxx>
> >>>
> >>> Also clear pending software exceptions.
> >>> Copy the fix to SVM as well.
> >>>
> >>> Signed-off-by: Tim Deegan <tim@xxxxxxx>
> >> I only now realized that it's no surprise we're not getting acks from
> >> the VMX maintainers on this - the majority of them wasn't Cc-ed.
> >> Now done, but please take care to do so yourself in the future.
> >>
> >> As to the SVM maintainers - Ping (I Cc-ed you on an earlier reply)?
> > Thanks for doing this.
> > I have repost it in the bugfix patchset, and cc vmx and svm maintainers
> >
> Hi,
> Apologies for the delay.
> As for the svm changes, the patch seems fairly straightforward and harmless.
> However, I am not familiar with 'colo mode', so I'm not sure I 
> understand the problem..
> Is this a 'fix' we need so that we don't duplicate a pending software 
> interrupt on the secondary VM?

Yes.  The fix is needed for any code that uses the HVM state
restore to overwrite the state of a live vcpu.  If the vcpu had a pending
injection before the restore op it will still be pending afterwards, even
though all the rest of the vcpu state has been reset.

We didn't see it before becasue we only ever load HVM state int a
freshly creadted domain. 

> Is there a way to test this?

No canned test.  You could run a guest that takes a lot of faults and
then restore another guest over it and look for spurious faults in the


Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.