From patchwork Wed Mar 9 08:46:37 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wen Congyang X-Patchwork-Id: 8544091 Return-Path: X-Original-To: patchwork-xen-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id E896AC0553 for ; Wed, 9 Mar 2016 08:48:51 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E24AA20211 for ; Wed, 9 Mar 2016 08:48:50 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 8E23E201FE for ; Wed, 9 Mar 2016 08:48:45 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xen.org with esmtp (Exim 4.84) (envelope-from ) id 1adZkY-0004FK-H8; Wed, 09 Mar 2016 08:45:46 +0000 Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.84) (envelope-from ) id 1adZkW-0004FE-RH for xen-devel@lists.xen.org; Wed, 09 Mar 2016 08:45:44 +0000 Received: from [85.158.139.211] by server-15.bemta-5.messagelabs.com id 4D/39-25514-8B2EFD65; Wed, 09 Mar 2016 08:45:44 +0000 X-Env-Sender: wency@cn.fujitsu.com X-Msg-Ref: server-10.tower-206.messagelabs.com!1457513140!10556808!1 X-Originating-IP: [59.151.112.132] X-SpamReason: No, hits=0.0 required=7.0 tests= X-StarScan-Received: X-StarScan-Version: 8.11; banners=-,-,- X-VirusChecked: Checked Received: (qmail 3351 invoked from network); 9 Mar 2016 08:45:42 -0000 Received: from cn.fujitsu.com (HELO heian.cn.fujitsu.com) (59.151.112.132) by server-10.tower-206.messagelabs.com with SMTP; 9 Mar 2016 08:45:42 -0000 X-IronPort-AV: E=Sophos;i="5.22,518,1449504000"; d="scan'208";a="4387631" Received: from unknown (HELO cn.fujitsu.com) ([10.167.33.5]) by heian.cn.fujitsu.com with ESMTP; 09 Mar 2016 16:45:27 +0800 Received: from G08CNEXCHPEKD01.g08.fujitsu.local (unknown [10.167.33.80]) by cn.fujitsu.com (Postfix) with ESMTP id C204D42B55E4; Wed, 9 Mar 2016 16:45:26 +0800 (CST) Received: from G08FNSTD140052.g08.fujitsu.local (10.167.226.52) by G08CNEXCHPEKD01.g08.fujitsu.local (10.167.33.89) with Microsoft SMTP Server (TLS) id 14.3.181.6; Wed, 9 Mar 2016 16:45:26 +0800 From: Wen Congyang To: xen devel , Andrew Cooper , Wei Liu Date: Wed, 9 Mar 2016 16:46:37 +0800 Message-ID: <1457513197-21022-2-git-send-email-wency@cn.fujitsu.com> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1457513197-21022-1-git-send-email-wency@cn.fujitsu.com> References: <1457513197-21022-1-git-send-email-wency@cn.fujitsu.com> MIME-Version: 1.0 X-Originating-IP: [10.167.226.52] X-yoursite-MailScanner-ID: C204D42B55E4.A707C X-yoursite-MailScanner: Found to be clean X-yoursite-MailScanner-From: wency@cn.fujitsu.com X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Cc: Ian Jackson , Ian Campbell , Wen Congyang Subject: [Xen-devel] [PATCH v2 2/2] tools: change checkpointed_stream's type from int to xc_migration_stream_t X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Wen Congyang Acked-by: Wei Liu --- tools/libxc/include/xenguest.h | 4 ++-- tools/libxc/xc_nomigrate.c | 4 ++-- tools/libxc/xc_sr_restore.c | 2 +- tools/libxc/xc_sr_save.c | 2 +- tools/libxl/libxl_save_helper.c | 38 +++++++++++++++++++------------------- 5 files changed, 25 insertions(+), 25 deletions(-) diff --git a/tools/libxc/include/xenguest.h b/tools/libxc/include/xenguest.h index 973e5a6..029082d 100644 --- a/tools/libxc/include/xenguest.h +++ b/tools/libxc/include/xenguest.h @@ -93,7 +93,7 @@ typedef enum { int xc_domain_save(xc_interface *xch, int io_fd, uint32_t dom, uint32_t max_iters, uint32_t max_factor, uint32_t flags /* XCFLAGS_xxx */, struct save_callbacks* callbacks, int hvm, - int checkpointed_stream); + xc_migration_stream_t checkpointed_stream); /* callbacks provided by xc_domain_restore */ struct restore_callbacks { @@ -131,7 +131,7 @@ int xc_domain_restore(xc_interface *xch, int io_fd, uint32_t dom, domid_t store_domid, unsigned int console_evtchn, unsigned long *console_mfn, domid_t console_domid, unsigned int hvm, unsigned int pae, int superpages, - int checkpointed_stream, + xc_migration_stream_t checkpointed_stream, struct restore_callbacks *callbacks); /** diff --git a/tools/libxc/xc_nomigrate.c b/tools/libxc/xc_nomigrate.c index c9124df..77db59c 100644 --- a/tools/libxc/xc_nomigrate.c +++ b/tools/libxc/xc_nomigrate.c @@ -23,7 +23,7 @@ int xc_domain_save(xc_interface *xch, int io_fd, uint32_t dom, uint32_t max_iters, uint32_t max_factor, uint32_t flags, struct save_callbacks* callbacks, int hvm, - int checkpointed_stream) + xc_migration_stream_t checkpointed_stream) { errno = ENOSYS; return -1; @@ -34,7 +34,7 @@ int xc_domain_restore(xc_interface *xch, int io_fd, uint32_t dom, domid_t store_domid, unsigned int console_evtchn, unsigned long *console_mfn, domid_t console_domid, unsigned int hvm, unsigned int pae, int superpages, - int checkpointed_stream, + xc_migration_stream_t checkpointed_stream, struct restore_callbacks *callbacks) { errno = ENOSYS; diff --git a/tools/libxc/xc_sr_restore.c b/tools/libxc/xc_sr_restore.c index d4d33fd..b2a3558 100644 --- a/tools/libxc/xc_sr_restore.c +++ b/tools/libxc/xc_sr_restore.c @@ -725,7 +725,7 @@ int xc_domain_restore(xc_interface *xch, int io_fd, uint32_t dom, domid_t store_domid, unsigned int console_evtchn, unsigned long *console_gfn, domid_t console_domid, unsigned int hvm, unsigned int pae, int superpages, - int checkpointed_stream, + xc_migration_stream_t checkpointed_stream, struct restore_callbacks *callbacks) { struct xc_sr_context ctx = diff --git a/tools/libxc/xc_sr_save.c b/tools/libxc/xc_sr_save.c index e258b7c..fc51f60 100644 --- a/tools/libxc/xc_sr_save.c +++ b/tools/libxc/xc_sr_save.c @@ -830,7 +830,7 @@ static int save(struct xc_sr_context *ctx, uint16_t guest_type) int xc_domain_save(xc_interface *xch, int io_fd, uint32_t dom, uint32_t max_iters, uint32_t max_factor, uint32_t flags, struct save_callbacks* callbacks, int hvm, - int checkpointed_stream) + xc_migration_stream_t checkpointed_stream) { struct xc_sr_context ctx = { diff --git a/tools/libxl/libxl_save_helper.c b/tools/libxl/libxl_save_helper.c index 6bdcf13..5503311 100644 --- a/tools/libxl/libxl_save_helper.c +++ b/tools/libxl/libxl_save_helper.c @@ -246,14 +246,14 @@ int main(int argc, char **argv) if (!strcmp(mode,"--save-domain")) { - io_fd = atoi(NEXTARG); - uint32_t dom = strtoul(NEXTARG,0,10); - uint32_t max_iters = strtoul(NEXTARG,0,10); - uint32_t max_factor = strtoul(NEXTARG,0,10); - uint32_t flags = strtoul(NEXTARG,0,10); - int hvm = atoi(NEXTARG); - unsigned cbflags = strtoul(NEXTARG,0,10); - int checkpointed_stream = strtoul(NEXTARG,0,10); + io_fd = atoi(NEXTARG); + uint32_t dom = strtoul(NEXTARG,0,10); + uint32_t max_iters = strtoul(NEXTARG,0,10); + uint32_t max_factor = strtoul(NEXTARG,0,10); + uint32_t flags = strtoul(NEXTARG,0,10); + int hvm = atoi(NEXTARG); + unsigned cbflags = strtoul(NEXTARG,0,10); + xc_migration_stream_t checkpointed_stream = strtoul(NEXTARG,0,10); assert(!*++argv); helper_setcallbacks_save(&helper_save_callbacks, cbflags); @@ -267,17 +267,17 @@ int main(int argc, char **argv) } else if (!strcmp(mode,"--restore-domain")) { - io_fd = atoi(NEXTARG); - uint32_t dom = strtoul(NEXTARG,0,10); - unsigned store_evtchn = strtoul(NEXTARG,0,10); - domid_t store_domid = strtoul(NEXTARG,0,10); - unsigned console_evtchn = strtoul(NEXTARG,0,10); - domid_t console_domid = strtoul(NEXTARG,0,10); - unsigned int hvm = strtoul(NEXTARG,0,10); - unsigned int pae = strtoul(NEXTARG,0,10); - int superpages = strtoul(NEXTARG,0,10); - unsigned cbflags = strtoul(NEXTARG,0,10); - int checkpointed = strtoul(NEXTARG,0,10); + io_fd = atoi(NEXTARG); + uint32_t dom = strtoul(NEXTARG,0,10); + unsigned store_evtchn = strtoul(NEXTARG,0,10); + domid_t store_domid = strtoul(NEXTARG,0,10); + unsigned console_evtchn = strtoul(NEXTARG,0,10); + domid_t console_domid = strtoul(NEXTARG,0,10); + unsigned int hvm = strtoul(NEXTARG,0,10); + unsigned int pae = strtoul(NEXTARG,0,10); + int superpages = strtoul(NEXTARG,0,10); + unsigned cbflags = strtoul(NEXTARG,0,10); + xc_migration_stream_t checkpointed = strtoul(NEXTARG,0,10); assert(!*++argv); helper_setcallbacks_restore(&helper_restore_callbacks, cbflags);