xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@web.de>
To: Julien Grall <julien.grall@citrix.com>
Cc: xen-devel@lists.xensource.com, qemu-devel@nongnu.org,
	Stefano.Stabellini@eu.citrix.com, julian.pidancet@citrix.com
Subject: Re: [QEMU][RFC PATCH 4/6] xen-pci: Register PCI in Xen
Date: Thu, 22 Mar 2012 18:47:44 +0100	[thread overview]
Message-ID: <4F6B65C0.40801@web.de> (raw)
In-Reply-To: <5071f24e827d5948ed3de7f53991b148b4ef38e9.1332430835.git.julien.grall@citrix.com>

[-- Attachment #1: Type: text/plain, Size: 1353 bytes --]

On 2012-03-22 17:01, Julien Grall wrote:
> QEMU will now register PCI in Xen. It will usefull to forward
> IO config space to the right QEMU.
> 
> Before to register a PCI device, QEMU will check with XenStore if it is
> autorized to register the PCI associate to a given BDF.
> 
> Signed-off-by: Julien Grall <julien.grall@citrix.com>
> ---
>  hw/pci.c  |    6 +++++
>  xen-all.c |   70 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  2 files changed, 76 insertions(+), 0 deletions(-)
> 
> diff --git a/hw/pci.c b/hw/pci.c
> index bf046bf..4df4449 100644
> --- a/hw/pci.c
> +++ b/hw/pci.c
> @@ -31,6 +31,7 @@
>  #include "loader.h"
>  #include "range.h"
>  #include "qmp-commands.h"
> +#include "xen.h"
>  
>  //#define DEBUG_PCI
>  #ifdef DEBUG_PCI
> @@ -764,6 +765,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;
> +    }
> +

That is doomed to break as QEMU evolves. What magical code is supposed
to be above, what below this ha^Whook?

>      pci_config_alloc(pci_dev);
>  
>      pci_config_set_vendor_id(pci_dev->config, pc->vendor_id);

Jan


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 262 bytes --]

  reply	other threads:[~2012-03-22 17:47 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-22 16:01 [QEMU][RFC PATCH 0/6] QEMU disaggregation Julien Grall
2012-03-22 16:01 ` [QEMU][RFC PATCH 1/6] option: Add -xen-dmid Julien Grall
2012-03-22 17:36   ` Jan Kiszka
2012-03-23 10:42     ` Stefano Stabellini
2012-03-22 16:01 ` [QEMU][RFC PATCH 2/6] xen: Add functions to register PCI and IO in Xen Julien Grall
2012-03-23 10:44   ` Stefano Stabellini
2012-03-22 16:01 ` [QEMU][RFC PATCH 3/6] memory: Add xen memory hook Julien Grall
2012-03-22 17:44   ` Jan Kiszka
2012-03-23 15:08     ` Julien Grall
2012-03-23 16:37       ` Jan Kiszka
2012-03-25 10:44         ` Avi Kivity
2012-03-26 11:01           ` Stefano Stabellini
2012-03-26 11:02             ` Avi Kivity
2012-03-26 11:24               ` Julien Grall
2012-03-26 13:13                 ` Avi Kivity
2012-03-23 16:47   ` Anthony Liguori
2012-03-22 16:01 ` [QEMU][RFC PATCH 4/6] xen-pci: Register PCI in Xen Julien Grall
2012-03-22 17:47   ` Jan Kiszka [this message]
2012-03-22 19:58   ` Anthony Liguori
2012-03-23 11:02     ` Stefano Stabellini
2012-03-25 12:09       ` Avi Kivity
2012-03-26 11:45         ` Stefano Stabellini
2012-03-26 11:57           ` Avi Kivity
2012-03-26 12:20             ` Stefano Stabellini
2012-03-26 12:33               ` Avi Kivity
2012-03-26 13:56                 ` Stefano Stabellini
2012-03-22 16:01 ` [QEMU][RFC PATCH 5/6] xen-io: Handle the new ioreq type IOREQ_TYPE_PCI_CONFIG Julien Grall
2012-03-22 16:01 ` [QEMU][RFC PATCH 6/6] xen: handle qemu disaggregation Julien Grall
2012-03-23 11:07   ` 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=4F6B65C0.40801@web.de \
    --to=jan.kiszka@web.de \
    --cc=Stefano.Stabellini@eu.citrix.com \
    --cc=julian.pidancet@citrix.com \
    --cc=julien.grall@citrix.com \
    --cc=qemu-devel@nongnu.org \
    --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).