From mboxrd@z Thu Jan 1 00:00:00 1970 From: Yang Hongyang Subject: Re: [PATCH] libxl/remus: fix the return value of the checkpoint callback Date: Wed, 15 Jul 2015 20:30:33 +0800 Message-ID: <55A65269.6040504@cn.fujitsu.com> References: <1436956363-4217-1-git-send-email-yanghy@cn.fujitsu.com> <1436962410.32371.25.camel@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1436962410.32371.25.camel@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Campbell Cc: Wei Liu , Ian Jackson , xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org On 07/15/2015 08:13 PM, Ian Campbell wrote: > On Wed, 2015-07-15 at 18:32 +0800, Yang Hongyang wrote: >> In checkpoint callback, we wait for the interval and then start >> another checkpoint, so the ERROR_TIMEDOUT should be intended >> and should not treat as error. >> >> This patch is based on >> [PATCH v8 --for 4.6 COLO 00/25] COarse-grain LOck-stepping Virtual Machines for Non-stop Service > > Does that mean it won't apply to current staging? No. This can apply on top of colo pre series. > > I think we probably want this fix ASAP rather than waiting for that > series? I can resubmit the patch apply to staging, but the colo pre series will need to be rebased... > >> Signed-off-by: Yang Hongyang >> CC: Ian Jackson >> CC: Ian Campbell >> CC: Wei Liu >> --- >> tools/libxl/libxl_remus.c | 11 +++++++---- >> 1 file changed, 7 insertions(+), 4 deletions(-) >> >> diff --git a/tools/libxl/libxl_remus.c b/tools/libxl/libxl_remus.c >> index 46dcc3c..ffc92a7 100644 >> --- a/tools/libxl/libxl_remus.c >> +++ b/tools/libxl/libxl_remus.c >> @@ -355,11 +355,14 @@ static void remus_next_checkpoint(libxl__egc *egc, libxl__ev_time *ev, >> * (xc_domain_save.c). in order to continue executing the infinite loop >> * (suspend, checkpoint, resume) in xc_domain_save(). >> */ >> - >> - if (rc) >> + if (rc == ERROR_TIMEDOUT) { >> + /* This is intended, we set the timeout and start another checkpoint */ >> + libxl__xc_domain_saverestore_async_callback_done(egc, &dss->sws.shs, 1); > > Please wrap this (slightly) overlong line (and probably the comment too > which is borderline AFAICT). > >> + } else { >> dss->rc = rc; >> - >> - libxl__xc_domain_saverestore_async_callback_done(egc, &dss->sws.shs, !rc); >> + libxl__xc_domain_saverestore_async_callback_done(egc, >> + &dss->sws.shs, !rc); >> + } >> } >> >> /*---------------------- remus callbacks (restore) -----------------------*/ > > > . > -- Thanks, Yang.