[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] Save paused cpu ctx
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. Sorry for not making that clear sooner. >> 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. >> 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. >> Now about the "the agent should do something else if the VCPU is down" >> objection, that's not possible with the current Xen code: -ENOENT is >> returned both when the VCPU is down _and_ when the VCPU index is out of >> bounds (so if I query the state of VCPU 10 on a 2-VCPUs guest). > > If there are no other ways to inquire vCPU state, I'm sure we can > provide some. I also don't view disambiguating the error code as > an impossible thing to do. Of course, and if it's inacceptable to upstream the possibility of querying the state of an offline VCPU we'll do that. Thanks, Razvan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |