From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Cooper Subject: Re: [PATCH v8 --for 4.6 COLO 15/25] send store mfn and console mfn to xl before resuming secondary vm Date: Wed, 15 Jul 2015 19:15:15 +0100 Message-ID: <55A6A333.7020605@citrix.com> References: <1436951936-3447-1-git-send-email-yanghy@cn.fujitsu.com> <1436951936-3447-16-git-send-email-yanghy@cn.fujitsu.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1436951936-3447-16-git-send-email-yanghy@cn.fujitsu.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: Yang Hongyang , xen-devel@lists.xen.org Cc: wei.liu2@citrix.com, ian.campbell@citrix.com, wency@cn.fujitsu.com, guijianfeng@cn.fujitsu.com, yunhong.jiang@intel.com, eddie.dong@intel.com, rshriram@cs.ubc.ca, ian.jackson@eu.citrix.com List-Id: xen-devel@lists.xenproject.org On 15/07/15 10:18, Yang Hongyang wrote: > From: Wen Congyang > > We will call libxl__xc_domain_restore_done() to rebuild secondary vm. But > we need store mfn and console mfn when rebuilding secondary vm. So make > restore_results a function pointer in callback struct and struct > {save,restore}_callbacks, and use this callback to send store mfn and > console mfn to xl. > > Signed-off-by: Wen Congyang > Signed-off-by: Yang Hongyang > CC: Andrew Cooper > --- > tools/libxc/include/xenguest.h | 8 ++++++++ > tools/libxc/xc_sr_restore.c | 7 +++++-- > tools/libxl/libxl_colo_restore.c | 5 ----- > tools/libxl/libxl_create.c | 2 ++ > tools/libxl/libxl_save_msgs_gen.pl | 2 +- > 5 files changed, 16 insertions(+), 8 deletions(-) > > diff --git a/tools/libxc/include/xenguest.h b/tools/libxc/include/xenguest.h > index 1e7e1bb..d7bdfb5 100644 > --- a/tools/libxc/include/xenguest.h > +++ b/tools/libxc/include/xenguest.h > @@ -140,6 +140,14 @@ struct restore_callbacks { > */ > int (*should_checkpoint)(void* data); > > + /* > + * callback to send store mfn and console mfn to xl > + * if we want to resume vm before xc_domain_save() > + * exits. > + */ > + void (*restore_results)(unsigned long store_mfn, unsigned long console_mfn, > + void *data); These need to be xen_pfn_t to be usable in arm. Also, they are gfn's, not mfn's A whole lot of terminology in this area is wrong. The top of xen/include/xen/mm.h is the authoritative description of terms, starting from c/s e758ed1 ~Andrew