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

Re: [Xen-devel] [PATCH for-4.10 1/2] tools/libxc: Fix precopy_policy() to not pass a structure by value



On Mon, Oct 16, 2017 at 02:51:54PM +0100, Andrew Cooper wrote:
> On 16/10/17 14:40, Wei Liu wrote:
> > On Fri, Oct 13, 2017 at 06:32:18PM +0100, Andrew Cooper wrote:
> >> c/s 4d69b3495 "Introduce migration precopy policy" uses bogus reasoning to
> >> justify passing precopy_stats by value.
> >>
> >> Under no circumstances can the precopy callback ever be executing in a
> >> separate address space.
> >>
> > The callback is not executed in a separate address space. 
> >
> > Have you checked
> > <1506365735-133776-4-git-send-email-Jennifer.Herbert@xxxxxxxxxx>?
> >
> > The open source toolstack spawns another process to save vm image. In
> > order to let libxl control the process (in the future) there is
> > information passed across process boundary.
> >
> > Your code might work for now because Joshua's patch is not yet applied.
> 
> I'm perfectly aware of that discussion, and it is factually incorrect. 
> Nothing, not even Joshua's patch, can cause the callback to be executed
> in a separate address space.
> 
> With Joshua's patch in place, the implementer of this callback is the
> code generated by libxl_save_msgs_gen.pl, which is the aformentioned
> extra process.  Passing by pointer or value has nothing to do with the
> fact that the automatically generated code needs to know how to
> serialise/deserialise the data to feed it back to the main process.
> 

Right. I agree with you here after going back to the old thread.

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

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