From: Julien Grall <julien.grall@citrix.com>
To: Stefano Stabellini <Stefano.Stabellini@eu.citrix.com>
Cc: "christian.limpach@gmail.com" <christian.limpach@gmail.com>,
"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
"xen-devel@lists.xen.org" <xen-devel@lists.xen.org>
Subject: Re: [Qemu-devel] [QEMU][RFC V2 06/10] xen-pci: register PCI device in Xen and handle IOREQ_TYPE_PCI_CONFIG
Date: Fri, 24 Aug 2012 13:59:08 +0100 [thread overview]
Message-ID: <50377A9C.7090500@citrix.com> (raw)
In-Reply-To: <alpine.DEB.2.02.1208231455010.15568@kaball.uk.xensource.com>
On 08/23/2012 03:41 PM, Stefano Stabellini wrote:
> On Wed, 22 Aug 2012, Julien Grall wrote:
>
>> With QEMU disaggregation QEMU needs to specify which PCI device it's able to
>> handle. It will use the device place in the topology (domain, bus, device,
>> function).
>> When Xen will trap an access for the config space, it will forge a new
>> ioreq and forward it to the right QEMU.
>>
>> Signed-off-by: Julien Grall<julien.grall@citrix.com>
>> ---
>> hw/pci.c | 6 ++++++
>> hw/xen.h | 1 +
>> xen-all.c | 38 ++++++++++++++++++++++++++++++++++++++
>> xen-stub.c | 5 +++++
>> 4 files changed, 50 insertions(+), 0 deletions(-)
>>
>> diff --git a/hw/pci.c b/hw/pci.c
>> index 4d95984..0112edf 100644
>> --- a/hw/pci.c
>> +++ b/hw/pci.c
>> @@ -33,6 +33,7 @@
>> #include "qmp-commands.h"
>> #include "msi.h"
>> #include "msix.h"
>> +#include "xen.h"
>>
>> //#define DEBUG_PCI
>> #ifdef DEBUG_PCI
>> @@ -781,6 +782,11 @@ static PCIDevice *do_pci_register_device(PCIDevice *pci_dev, PCIBus *bus,
>> pci_dev->devfn = devfn;
>> pstrcpy(pci_dev->name, sizeof(pci_dev->name), name);
>> pci_dev->irq_state = 0;
>> +
>> + if (xen_enabled()&& xen_register_pcidev(pci_dev)) {
>> + return NULL;
>>
> Is this an error condition? If so we should print an error message,
> right?
>
Yes, it means that the BDF is already registered by another QEMU.
next prev parent reply other threads:[~2012-08-24 12:58 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-22 12:30 [Qemu-devel] [QEMU][RFC V2 00/10] QEMU disaggregation in Xen environment Julien Grall
2012-08-22 12:30 ` [Qemu-devel] [QEMU][RFC V2 01/10] xen: add new machine options to support " Julien Grall
2012-08-23 14:40 ` Stefano Stabellini
2012-08-22 12:30 ` [Qemu-devel] [QEMU][RFC V2 02/10] xen: modify QEMU status path in XenStore Julien Grall
2012-08-22 12:30 ` [Qemu-devel] [QEMU][RFC V2 03/10] xen: add wrappers for new Xen disaggregation hypercalls Julien Grall
2012-08-22 12:30 ` [Qemu-devel] [QEMU][RFC V2 04/10] xen-hvm: register qemu as ioreq server and retrieve shared pages Julien Grall
2012-08-22 12:30 ` [Qemu-devel] [QEMU][RFC V2 05/10] xen-memory: register memory/IO range in Xen Julien Grall
2012-08-23 14:41 ` Stefano Stabellini
2012-08-23 17:18 ` Julien Grall
2012-08-22 12:30 ` [Qemu-devel] [QEMU][RFC V2 06/10] xen-pci: register PCI device in Xen and handle IOREQ_TYPE_PCI_CONFIG Julien Grall
2012-08-23 14:41 ` Stefano Stabellini
2012-08-24 12:59 ` Julien Grall [this message]
2012-08-22 12:30 ` [Qemu-devel] [QEMU][RFC V2 07/10] xen: specify which device is part of default devices Julien Grall
2012-08-23 14:42 ` Stefano Stabellini
2012-08-22 12:30 ` [Qemu-devel] [QEMU][RFC V2 08/10] xen: audio is not a " Julien Grall
2012-08-23 14:42 ` Stefano Stabellini
2012-08-22 12:30 ` [Qemu-devel] [QEMU][RFC V2 09/10] xen-memory: handle node "device_model" for physical mapping Julien Grall
2012-08-22 12:30 ` [Qemu-devel] [QEMU][RFC V2 10/10] xen: emulate IDE outside default device set Julien Grall
2012-08-23 14:43 ` Stefano Stabellini
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=50377A9C.7090500@citrix.com \
--to=julien.grall@citrix.com \
--cc=Stefano.Stabellini@eu.citrix.com \
--cc=christian.limpach@gmail.com \
--cc=qemu-devel@nongnu.org \
--cc=xen-devel@lists.xen.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.