qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Don Slutz <dslutz@verizon.com>
To: Rishi Ranjan <rishi.rranjan@gmail.com>,
	Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Cc: xen-devel@lists.xensource.com, Anthony.Perard@citrix.comm,
	qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] bind interdomain ioctl error xen-kvm.c
Date: Mon, 05 Jan 2015 18:58:25 -0500	[thread overview]
Message-ID: <54AB2521.3030607@terremark.com> (raw)
In-Reply-To: <CAGontdL3B9M+QZJDYqi4JuTv6QuayP8yTaK5bEfqbZSa=74y=w@mail.gmail.com>

On 01/05/15 14:10, Rishi Ranjan wrote:
> Hi Stefano,
>                  Please find my answers inline. 
> 
>>>>> However Anthony (CC'ed) should have some patches for it.
> Anthony, can you please share any patch that can help me with this?
> 
> 
>>>>> Can you post the full output of the logs?
> I have attached the output of "sudo xl -v create /etc/xen/qemu-pv.cfg"
> as xl_create.txt. I have also enabled DEBUG_XEN_HVM in xen-hvm.c and
> pasted output of "sudo ./x86_64-softmmu/qemu-system-x86_64  -machine
> q35,accel=xen -cpu qemu64 -xen-domid 13" below: 
> 

The output of "sudo xl -vvv create /etc/xen/qemu-pv.cfg" will help
since it includes how xen invokes qemu.

> 
> xen: shared page at pfn feffd
> xen: buffered io page at pfn feffb
> bind interdomain ioctl error 22
> xen hardware virtual machine initialisation failed


This says that where you are reporting the error is not
correct.

The message "buffered io page at pfn feffb" is output
after the code that contains shared_vmport_page.

Also posting the data in /var/log/xen/qemu-dm-qemu-hvm.log
will help.


It looks like you are re-starting QEMU on a domain.  This is not
supported as far as I know (and not clear that you are starting the same
version that xen tried).


> 
> 
>>>>> What is the Xen version that you are running?
> 
> I am using XEN 4.4.1 as this is the default on Ubuntu 14.04. I have
> attached the output of "xl info" command as xl_info.txt. 
> 

You are running QEMU 2.2.0 or later based on having
shared_vmport_page in the code.


>>>>>Did you execute the xencommons init script at boot time?
> On Ubuntu I don't see /etc/init.d/xencommon but there is a
> /etc/init.d/xen script which starts xenstored and xenconsoled. I did
> confirm from ps aufx that both the daemons are running. I have attched
> log for "ps aufx" as ps_aufx_grep_xen.txt .
> 
> 
> 
> 
> 
> 
> On Mon, Jan 5, 2015 at 4:48 AM, Stefano Stabellini
> <stefano.stabellini@eu.citrix.com
> <mailto:stefano.stabellini@eu.citrix.com>> wrote:
> 
>     On Tue, 30 Dec 2014, Rishi Ranjan wrote:
>     > I am trying to use Xen as accelerator for my Qemu machine. I have created a guest domain with following xl config: 
>     > builder = "hvm"
>     > name = "qemu-hvm"
>     > memory = "512"
>     > vcpus = 1
>     > vif = ['']
>     > vnc = 1
>     > boot="c"
>     >
>     >
>     > When I try to run with following parameters: 
>     >
>     > -machine q35,accel=xen -cpu qemu64 -bios ./pc-bios/bios-256k.bin -xen-domid "Domain id of guest"
> 
>     You should know that q35 emulation is not fully working on Xen yet.
>     However Anthony (CC'ed) should have some patches for it.
> 
>     That said, it does not look like this error has something to do with
>     q35.
> 
> 
>     > I am getting follwing error from xen-hvm.c: 
>     >
>     > "bind interdomain ioctl error" in xen_hvm_init while calling         state->shared_vmport_page =
>     >             xc_map_foreign_range(xen_xc, xen_domid, XC_PAGE_SIZE,
>     >                                  PROT_READ|PROT_WRITE, ioreq_pfn); 

To get here, xen_get_vmport_regs_pfn() needs to return 0.

In include/hw/xen/xen_common.h:


#ifdef HVM_PARAM_VMPORT_REGS_PFN
static inline int xen_get_vmport_regs_pfn(XenXC xc, domid_t dom,
                                          unsigned long *vmport_regs_pfn)
{
    return xc_get_hvm_param(xc, dom, HVM_PARAM_VMPORT_REGS_PFN,
                            vmport_regs_pfn);
}
#else
static inline int xen_get_vmport_regs_pfn(XenXC xc, domid_t dom,
                                          unsigned long *vmport_regs_pfn)
{
    return -ENOSYS;
}
#endif


requires HVM_PARAM_VMPORT_REGS_PFN to be defined before it will return
0.

I am sure that xen 4.4.1 does not define this (patch that does is
waiting for xen 4.6 to open up).


   -Don Slutz

>     >
>     > Can someone help me get this working? 
> 
>     Can you post the full output of the logs?
>     What is the Xen version that you are running?
>     Did you execute the xencommons init script at boot time?
> 
> 

  reply	other threads:[~2015-01-05 23:58 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-30 23:35 [Qemu-devel] bind interdomain ioctl error xen-kvm.c Rishi Ranjan
2015-01-05 12:48 ` Stefano Stabellini
2015-01-05 19:10   ` Rishi Ranjan
2015-01-05 23:58     ` Don Slutz [this message]
2015-01-06 10:44     ` [Qemu-devel] [Xen-devel] " Ian Campbell
2015-01-06 11:11     ` [Qemu-devel] " Anthony PERARD
2015-01-06 11:32       ` Anthony PERARD

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=54AB2521.3030607@terremark.com \
    --to=dslutz@verizon.com \
    --cc=Anthony.Perard@citrix.comm \
    --cc=qemu-devel@nongnu.org \
    --cc=rishi.rranjan@gmail.com \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=xen-devel@lists.xensource.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).