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

Re: [Xen-devel] [PATCH v1] x86/hvm: Generic instruction re-execution mechanism for execute faults



>>> On 22.11.18 at 10:50, <aisaila@xxxxxxxxxxxxxxx> wrote:
> On 21.11.2018 20:55, Razvan Cojocaru wrote:
>>> +            if ( a == v )
>>> +                continue;
>>> +
>>> +            /* Pause, synced. */
>>> +            while ( !a->arch.in_host )
>> Why not use a->is_running as a way to know whether the vCPU is
>> running?
>> 
>> I think the logic of using vcpu_pause and expecting the running vcpu
>> to take a vmexit and thus set in_host is wrong because a vcpu that
>> wasn't running when vcpu_pause_nosync is called won't get scheduled
>> anymore, thus not taking a vmexit and this function will lockup.
> 
> We can resolve this by using while ( !vcpu_runnable(a) && 
> !a->arch.in_host ), if this is suitable.

Only if you can fully explain why the current infrastructure doesn't
work and can't be made work without the custom in_host flag.
From prior work I know things are subtle in some cases where one
would want to use ->is_running, but so far all issues could be
resolved without custom additions.

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

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