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

Re: [Xen-devel] [PATCH v2 20/27] tools/libxl: Infrastructure for writing a v2 stream



On Thu, 2015-07-09 at 19:26 +0100, Andrew Cooper wrote:
> From: Ross Lagerwall <ross.lagerwall@xxxxxxxxxx>
> 
> This contains the event machinary and state machines to write non-checkpointed

"machinery"

> /* Helper to set up reading some data from the stream. */
> +static void write_done(libxl__egc *egc,
> +                       libxl__datacopier_state *dc,
> +                       int rc, int onwrite, int errnoval)
> +{
> +    libxl__stream_write_state *stream = CONTAINER_OF(dc, *stream, dc);
> +    STATE_AO_GC(stream->ao);
> +    sws_record_done_cb cb = stream->record_done_callback;
> +
> +    stream->record_done_callback = NULL;
> +
> +    if (onwrite || errnoval) {
> +        LOG(ERROR, "rc %d, onwrite %d, errnoval %d", rc, onwrite, errnoval);

As with saving, I think the dc has logged.

> +void libxl__stream_write_start(libxl__egc *egc,
> +                               libxl__stream_write_state *stream)
> +{
> +    libxl__datacopier_state *dc = &stream->dc;
> +    STATE_AO_GC(stream->ao);
> +    struct libxl__sr_hdr hdr = { 0 };
> +    int ret = 0;
> +
> +    assert(!stream->running);

I think we both know what I'm going to say here ;-)

Ian.


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


 


Rackspace

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