From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wen Congyang Subject: Re: [PATCH v3 COLOPre 21/26] tools/libxl: refactor write stream to support back channel Date: Wed, 1 Jul 2015 13:33:37 +0800 Message-ID: <55937BB1.6020100@cn.fujitsu.com> References: <1435213552-10556-1-git-send-email-yanghy@cn.fujitsu.com> <1435213552-10556-22-git-send-email-yanghy@cn.fujitsu.com> <1435660105.21469.81.camel@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1435660105.21469.81.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 , Yang Hongyang Cc: wei.liu2@citrix.com, andrew.cooper3@citrix.com, yunhong.jiang@intel.com, eddie.dong@intel.com, xen-devel@lists.xen.org, guijianfeng@cn.fujitsu.com, rshriram@cs.ubc.ca, ian.jackson@eu.citrix.com List-Id: xen-devel@lists.xenproject.org On 06/30/2015 06:28 PM, Ian Campbell wrote: > On Thu, 2015-06-25 at 14:25 +0800, Yang Hongyang wrote: >> From: Wen Congyang > > Refactor how? > > (Tip: In general no change can be sufficiently described in just the > subject line unless it is absolutely the most trivial possible one). > > It looks like mostly checkpoint_callback is renamed to > write_records_callback and the type of its argument and that of > completion_callback changed. But why? checkpoint callback just write a record and return to the caller. For back channel, we also write a record from secondary to primary. So I rename it to write_records_callback. In secondary side, there is no libxl__domain_save_state, so I change the argument: use stream instead of dss. The caller can use container_of() to get dss. The back channel only needs this feature: use the read/write stream to read and write record. Thanks Wen Congyang > > > > . >