Srujan Kotikela
2011-Jun-20 16:13 UTC
[Xen-users] Converting a HVM Guest into a PV-on-HVM Guest
Hi, I have a HVM guest with CentOs (i386) 5.6. My Dom0 has xen-3.4.3 (from source and some custom changes) running on the same kernel (2.6.18-238.12.1.el5). I would like to know what should I do in the Dom0 and/or DomU to convert it to a PV-on-HVM domain so that I can have privcmd interface to do hypercalls. I tried copying the xen libraries from my Dom0 to invoke my custom hypercall, but I get an error "PRIV-CMD interface: file or directory not found". If it''s easier to create a new PV-on-HVM than converting the HVM, I would prefer building PV-on-HVM from scratch. -- Srujan D. Kotikela _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Todd Deshane
2011-Jun-20 16:37 UTC
Re: [Xen-users] Converting a HVM Guest into a PV-on-HVM Guest
On Mon, Jun 20, 2011 at 12:13 PM, Srujan Kotikela <ksrujandas@gmail.com> wrote:> Hi, > > I have a HVM guest with CentOs (i386) 5.6. My Dom0 has xen-3.4.3 (from > source and some custom changes) running on the same kernel > (2.6.18-238.12.1.el5). > > I would like to know what should I do in the Dom0 and/or DomU to convert it > to a PV-on-HVM domain so that I can have privcmd interface to do hypercalls. > I tried copying the xen libraries from my Dom0 to invoke my custom > hypercall, but I get an error "PRIV-CMD interface: file or directory not > found". > > If it''s easier to create a new PV-on-HVM than converting the HVM, I would > prefer building PV-on-HVM from scratch. >Some information here: http://wiki.xensource.com/xenwiki/XenLinuxPVonHVMdrivers> -- > Srujan D. Kotikela > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users >-- Todd Deshane http://www.linkedin.com/in/deshantm http://www.xen.org/products/cloudxen.html http://runningxen.com/ _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Srujan Kotikela
2011-Jun-20 18:44 UTC
Re: [Xen-users] Converting a HVM Guest into a PV-on-HVM Guest
Just to make sure, PV-on-HVM drivers are neccessary and/or sufficient to make hypercalls from a HVM domain, right? -- Srujan D. Kotikela On Mon, Jun 20, 2011 at 11:37 AM, Todd Deshane <todd.deshane@xen.org> wrote:> On Mon, Jun 20, 2011 at 12:13 PM, Srujan Kotikela <ksrujandas@gmail.com> > wrote: > > Hi, > > > > I have a HVM guest with CentOs (i386) 5.6. My Dom0 has xen-3.4.3 (from > > source and some custom changes) running on the same kernel > > (2.6.18-238.12.1.el5). > > > > I would like to know what should I do in the Dom0 and/or DomU to convert > it > > to a PV-on-HVM domain so that I can have privcmd interface to do > hypercalls. > > I tried copying the xen libraries from my Dom0 to invoke my custom > > hypercall, but I get an error "PRIV-CMD interface: file or directory not > > found". > > > > If it''s easier to create a new PV-on-HVM than converting the HVM, I would > > prefer building PV-on-HVM from scratch. > > > > Some information here: > http://wiki.xensource.com/xenwiki/XenLinuxPVonHVMdrivers > > > -- > > Srujan D. Kotikela > > > > _______________________________________________ > > Xen-users mailing list > > Xen-users@lists.xensource.com > > http://lists.xensource.com/xen-users > > > > > > -- > Todd Deshane > http://www.linkedin.com/in/deshantm > http://www.xen.org/products/cloudxen.html > http://runningxen.com/ >_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Todd Deshane
2011-Jun-21 01:54 UTC
Re: [Xen-users] Converting a HVM Guest into a PV-on-HVM Guest
On Mon, Jun 20, 2011 at 2:44 PM, Srujan Kotikela <ksrujandas@gmail.com> wrote:> Just to make sure, > > PV-on-HVM drivers are neccessary and/or sufficient to make hypercalls from a > HVM domain, right? >I''m not sure. A quick search indicates that there is some HVM hypercall code: http://xen.markmail.org/search/?q=hvm+hypercall http://xen.markmail.org/search/?q=hypercall_hvm_op#query:hypercall_hvm_op+page:1+mid:bozac75eaw4jrgof+state:results http://lxr.xensource.com/lxr/source/xen/arch/x86/hvm/hvm.c I don''t know the details. You may considering taking a look at: http://wiki.xensource.com/xenwiki/AskingXenDevelQuestions Thanks, Todd _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Srujan Kotikela
2011-Jun-21 02:23 UTC
Re: [Xen-users] Converting a HVM Guest into a PV-on-HVM Guest
forgot to cc, earlier. On Mon, Jun 20, 2011 at 9:22 PM, Srujan Kotikela <ksrujandas@gmail.com>wrote:> Hi Todd, > > Thanks for the reply. > > I am trying to invoke a hypercall from the HVM guest. The only way I did > hypercalls from DomU till now (on PV guests) is use the libxc > library do_xen_hypercall (which in turn uses do_privcmd which in turn uses > ioctl). > > Now I have a added a custom hypercall to xen and I am trying to invoke it > from HVM guest. As the HVM guest is not xenified (-linux) it doesn''t have > the privcmd interface (/proc/xen/privcmd). So I am looking for a way to > invoke the custom hypercall from HVM. While in this try, I found that > pv-on-hvm will enable hypercalls from HVM guest. However I also read that it > may not allow all the hypercalls (correct me if I am wrong). > > While looking at the other posts I found this, > http://xen.1045712.n5.nabble.com/hypercalls-from-HVM-guest-on-XEN-3-4-3-td4454566.html which > recommends to look into tools/firmware/hvmloader. There is some code in > hypercall.h in the hvmloader directory ( > http://rswiki.csie.org/lxr/http/source/tools/firmware/hvmloader/hypercall.h?v=xen-4.0.0;a=ppc > ). I am figuring out how to make use of this. Will update once I figure it > out. > > Sorry for not being unclear, earlier. > > -- > Srujan D. Kotikela > > > > On Mon, Jun 20, 2011 at 8:54 PM, Todd Deshane <todd.deshane@xen.org>wrote: > >> On Mon, Jun 20, 2011 at 2:44 PM, Srujan Kotikela <ksrujandas@gmail.com> >> wrote: >> > Just to make sure, >> > >> > PV-on-HVM drivers are neccessary and/or sufficient to make hypercalls >> from a >> > HVM domain, right? >> > >> >> I''m not sure. >> >> A quick search indicates that there is some HVM hypercall code: >> >> http://xen.markmail.org/search/?q=hvm+hypercall >> >> http://xen.markmail.org/search/?q=hypercall_hvm_op#query:hypercall_hvm_op+page:1+mid:bozac75eaw4jrgof+state:results >> http://lxr.xensource.com/lxr/source/xen/arch/x86/hvm/hvm.c >> >> I don''t know the details. You may considering taking a look at: >> http://wiki.xensource.com/xenwiki/AskingXenDevelQuestions >> >> Thanks, >> Todd >> > >_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Todd Deshane
2011-Jun-21 02:51 UTC
Re: [Xen-users] Converting a HVM Guest into a PV-on-HVM Guest
On Mon, Jun 20, 2011 at 10:23 PM, Srujan Kotikela <ksrujandas@gmail.com> wrote:>> Hi Todd, >> Thanks for the reply. >> I am trying to invoke a hypercall from the HVM guest. The only way I did >> hypercalls from DomU till now (on PV guests) is use the libxc >> library do_xen_hypercall (which in turn uses do_privcmd which in turn uses >> ioctl). >> Now I have a added a custom hypercall to xen and I am trying to invoke it >> from HVM guest. As the HVM guest is not xenified (-linux) it doesn''t have >> the privcmd interface (/proc/xen/privcmd). So I am looking for a way to >> invoke the custom hypercall from HVM. While in this try, I found that >> pv-on-hvm will enable hypercalls from HVM guest. However I also read that it >> may not allow all the hypercalls (correct me if I am wrong). >> While looking at the other posts I found >> this, http://xen.1045712.n5.nabble.com/hypercalls-from-HVM-guest-on-XEN-3-4-3-td4454566.html which >> recommends to look into tools/firmware/hvmloader. There is some code in >> hypercall.h in the hvmloader directory >> (http://rswiki.csie.org/lxr/http/source/tools/firmware/hvmloader/hypercall.h?v=xen-4.0.0;a=ppc). >> I am figuring out how to make use of this. Will update once I figure it out. >> Sorry for not being unclear, earlier.I do think that you are getting into the territory where you might want to read this [1] and then ask on xen-devel for clarification. [1] http://wiki.xensource.com/xenwiki/AskingXenDevelQuestions _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users