From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kai Luo Subject: Questions about the mapping from gpfn to mfn when live migration Date: Sat, 1 Jun 2013 23:19:25 -0700 (PDT) Message-ID: <1315453738.1404628.1370153965900.JavaMail.root@vmware.com> References: <787044279.1400842.1370151885282.JavaMail.root@vmware.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2674492019016728981==" Return-path: In-Reply-To: <787044279.1400842.1370151885282.JavaMail.root@vmware.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: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org --===============2674492019016728981== Content-Type: multipart/alternative; boundary="----=_Part_1404627_737457225.1370153965900" ------=_Part_1404627_737457225.1370153965900 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi everyone:=20 I am reading code of live migration process of hvm domain now.My question i= s that I can't find the transformation position that transform hvm domain= =E2=80=98s gpfn to mfn.That is,the method ,in file xc_linux_osdep.c, linux_= privcmd_map_foreign_bulk( xc_interface *xch, xc_osdep_handle h, uint32_t do= m, int prot, const xen_pfn_t *arr, int *err, unsigned int num) ,the list of= xen_pfn_t contains the list of guest's mfns(gpfns in xen),for para-virtual= ization guests they are thransformed by the pfn_to_mfn() before assignment(= in xc_domain_save())=EF=BC=8Cfor hvm guests however=EF=BC=8CI can not find = a similar conversion process,they are directly conveyed to the dom's kernel= directly without any transformation.So I continued to follow the process,f= inding the following key functions:=20 privcmd_ioctl (struct file *file, unsigned int cmd, unsigned long data)=20 ->privcmd_ioctl_mmap_batch(udata, 2)=20 ->-> traverse_pages(mmapcmd.num, sizeof(struct privcmd_mmap_entry), &pageli= st, mmap_mfn_range, &state);=20 Still no clue for the thransformation process,could you give any sugguestio= ns?=20 My second question is that is it possible that I give a list of hvm's mfns(= not gpfns) and then get the contents held in memory in dom0?Does xen have a= ny function of this kind?=20 Thank you all!=20 Jone=20 ------=_Part_1404627_737457225.1370153965900 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable
Hi everyone:
  &n= bsp; I am reading code of live migration process of hvm domain now.My quest= ion is that I can't find the transformation position that transform hv= m domain=E2=80=98s gpfn to mfn.That is,the method ,in file xc_linux_os= dep.c,linux_privcmd_map_foreign_bulk(xc_interface *xch, xc_osdep_handle h,<= span style=3D"font-size: 12pt;" data-mce-style=3D"font-size: 12pt;">uint32_= t dom, int prot,const xen_pf= n_t *arr, int *err, unsigned int num),the list of xen_pfn_t contains= the list of guest's mfns(gpfns in xen),for para-virtualization guests they= are thransformed by the pfn_to_mfn() before assignment(in xc_domain_save()= )=EF=BC=8Cfor hvm guests however=EF=BC=8CI can not find a similar conversio= n process,they are directly conveyed to the dom's kernel directly without a= ny transformation.So I continued to follow the process,finding the followin= g key functions:
    privcmd_ioctl= (struct file *file,unsigned int cmd, unsigned long data) <= /div>
 &n= bsp;   ->privcmd_ioctl_mmap_batch(udata, 2)=
=      ->->  traverse_pages(mmapcmd.num, sizeof(struct privcmd_mmap= _entry),&pagelist,mmap_mfn_range, &state);
    Still no clue for the thran= sformation process,could you give any sugguestions?
    My second question is that is it p= ossible that I give a list of hvm's mfns(not gpfns) and then get the c= ontents held in memory in dom0?Does xen have any function of this kind?
Thank you all!
<= div>Jone    
------=_Part_1404627_737457225.1370153965900-- --===============2674492019016728981== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --===============2674492019016728981==--