[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Xen-devel] [PATCH v6 COLO 02/15] secondary vm suspend/resume/checkpoint code
- To: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>, Wei Liu <wei.liu2@xxxxxxxxxx>
- From: Yang Hongyang <yanghy@xxxxxxxxxxxxxx>
- Date: Mon, 15 Jun 2015 10:10:52 +0800
- Cc: ian.campbell@xxxxxxxxxx, wency@xxxxxxxxxxxxxx, andrew.cooper3@xxxxxxxxxx, yunhong.jiang@xxxxxxxxx, eddie.dong@xxxxxxxxx, xen-devel@xxxxxxxxxxxxx, guijianfeng@xxxxxxxxxxxxxx, rshriram@xxxxxxxxx
- Delivery-date: Mon, 15 Jun 2015 02:11:17 +0000
- List-id: Xen developer discussion <xen-devel.lists.xen.org>
Hi Ian J, Wei,
On 06/12/2015 10:51 PM, Ian Jackson wrote:
Wei Liu writes ("Re: [Xen-devel] [PATCH v6 COLO 02/15] secondary vm
suspend/resume/checkpoint code"):
On Mon, Jun 08, 2015 at 11:45:46AM +0800, Yang Hongyang wrote:
From: Wen Congyang <wency@xxxxxxxxxxxxxx>
+ crcs->status = LIBXL_COLO_RESUMED;
+
+ /* avoid calling libxl__xc_domain_restore_done() more than once */
+ if (crs->saved_cb) {
+ dcs->callback = crs->saved_cb;
+ crs->saved_cb = NULL;
I have a feeling that this trick should be avoided. But I'm not an
expert on this so I will defer judgement to Ian J.
Yes, this trick should be avoided. It will make the resulting
control flow very confusing.
I agree that this part is a bit of tricky. I will try to find another
way to do this. Maybe add another state variable to indicate what stage
we are in, the first boot or under checkpoint.
Ian.
.
--
Thanks,
Yang.
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel
|