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

Re: [Xen-devel] Save paused cpu ctx



>>> On 19.09.18 at 14:37, <rcojocaru@xxxxxxxxxxxxxxx> wrote:
> On 9/19/18 3:13 PM, Jan Beulich wrote:
>>>>> On 19.09.18 at 13:11, <rcojocaru@xxxxxxxxxxxxxxx> wrote:
>>> The scenario is that we are trying to query the state of a VCPU (please
>>> note: just query). That means that we're only interested in getting some
>>> coherent VCPU state via the XEN_DOMCTL_gethvmcontext_partial domctl.
>>>
>>> We don't care if said state ends up being saved for the migration stream
>>> or not, so in that respect the answer to Roger's question is: no size
>>> increase or difference whatsoever.
>> 
>> "We don't care" is too little. _We_ care that state for offline vCPU-s does
>> not make it into the migration stream. And at this point I think you mean
>> "no size increase or difference whatsoever _intended_", since removing
>> the check in question would result in a size increase afaict.
> 
> Yes, of course. We don't intend any size increase or difference in the
> code, nor do we want to unconditionally remove the check. We were
> thinking of adding an extra bool parameter to hvm_save_one() to
> differentiate between the query case and everything else.

Okay, but we'll have to settle on the "makes sense" part (below) first.

>>> All we want to do is to be able to query the state of any VCPU in the
>>> valid range of VCPUs assigned to the domain, online or not. We believe
>>> being able to query them is reasonable, and the SDM states that they do
>>> have a state (whatever it happens to be: the init state, after reset, etc.).
>> 
>> I didn't know the SDM stated anything about offline vCPU-s. There's
>> (according to my way of looking at things) no bare hardware equivalent
>> to this state, which means whatever the SDM says is not applicable.
> 
> Please see page 311:
> 
> https://software.intel.com/sites/default/files/managed/a4/60/325384-sdm-vol- 
> 3abcd.pdf
> 
> The section is indeed called "Processor State After Reset" which is
> clearly not great for the purposes of this discussion, but the important
> part is "Table 9-1. IA-32 and Intel 64 Processor States Following
> Power-up, Reset, or INIT", which I believe illustrates the processor
> states we were talking about.

I did not question the existence of this description in the manual. What
I continue to question is the presence of something talking about
_virtual_ CPU state. You pointing me to hardware state descriptions
won't change my view that the state of an offline vCPU (note the v!)
is simply undefined, and hence querying it makes no sense.

>>> For example, please look at this XenServer-only patch:
>>>
>>> https://github.com/xenserver/xen.pg/blob/XS-7.1.x/master/x86-domctl-Don-t-pa
>>>  
> 
>>> use-the-whole-domain-if-only-gett.patch
>> 
>> That's what iirc Alexandru's series started from.
> 
> Indeed. What we've missed initially is that there were two parts to it:
> the one that got in with the series (the not pausing the whole domain if
> not strictly necessary) and the query part.

Which is a good sign that from (almost) the very beginning this should
have been separate patches.

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®.