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

RE: [Xen-devel] resume of HVM guest without PV drivers



> 
> >>> Keir Fraser <keir.fraser@xxxxxxxxxxxxx> 07.08.09 12:53 >>>
> >On 07/08/2009 11:35, "Jan Beulich" <JBeulich@xxxxxxxxxx> wrote:
> >
> >> Besides that, doing hypercalls here also requires that I'll be able
to re-
> >> setup the hypercall (or the hypercall page) in case I got migrated
> >> between VMX and SVM. While this could certainly be done in a fixup
> >> handler invoked from #UD (a little tricky for the hypercall page
case), I
> >> find it preferable to synchronously fix things up beforehand.
> >
> >Won't you always have a race between checking for migration and then
> >entering the cpu-specific hypercall stub?
> 
> Indeed. However, the fixup handler in this case can be trivial - it
just
> needs to restart the whole operation (including the
have-I-been-resumed
> check).
> 

What if it happens this way:
if (just_been_resumed)
  restore_hypercall_page();
/* suspend/resume happens here */
do_hypercall(...);

suddenly do_hypercall() jumps into empty space.

The chance of it happening isn't even that small if there is a lot of
spinning going on.

You could resolve it by having an MSR or something that you could write
to to tell Xen you are in a critical section and it can't do a suspend
right now, but suddenly you're doing more work than if you'd just put a
xenbus driver in in the first place.

James


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

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