qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: stefano.stabellini@eu.citrix.com
Cc: Anthony.Perard@citrix.com, xen-devel@lists.xensource.com,
	qemu-devel@nongnu.org, agraf@suse.de
Subject: Re: [Qemu-devel] [PATCH 2/3] pci: export pci_unplug_device
Date: Mon, 20 Jun 2011 11:48:56 +0300	[thread overview]
Message-ID: <20110620084856.GB22456@redhat.com> (raw)
In-Reply-To: <1308240319-13949-2-git-send-email-stefano.stabellini@eu.citrix.com>

On Thu, Jun 16, 2011 at 05:05:18PM +0100, stefano.stabellini@eu.citrix.com wrote:
> From: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
> 
> pci_unplug_device is needed by the xen_platform device to perfom dynamic
> nic unplug.
> 
> Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>

I think it's better to go through qdev, pci_unplug_device
was intended as an internal API.

> ---
>  hw/pci.c |    2 +-
>  hw/pci.h |    1 +
>  2 files changed, 2 insertions(+), 1 deletions(-)
> 
> diff --git a/hw/pci.c b/hw/pci.c
> index 1d297d6..679e976 100644
> --- a/hw/pci.c
> +++ b/hw/pci.c
> @@ -1692,7 +1692,7 @@ static int pci_qdev_init(DeviceState *qdev, DeviceInfo *base)
>      return 0;
>  }
>  
> -static int pci_unplug_device(DeviceState *qdev)
> +int pci_unplug_device(DeviceState *qdev)
>  {
>      PCIDevice *dev = DO_UPCAST(PCIDevice, qdev, qdev);
>      PCIDeviceInfo *info = container_of(qdev->info, PCIDeviceInfo, qdev);
> diff --git a/hw/pci.h b/hw/pci.h
> index 0d288ce..868f793 100644
> --- a/hw/pci.h
> +++ b/hw/pci.h
> @@ -452,6 +452,7 @@ typedef struct {
>  
>  void pci_qdev_register(PCIDeviceInfo *info);
>  void pci_qdev_register_many(PCIDeviceInfo *info);
> +int pci_unplug_device(DeviceState *qdev);
>  
>  PCIDevice *pci_create_multifunction(PCIBus *bus, int devfn, bool multifunction,
>                                      const char *name);
> -- 
> 1.7.2.3
> 

  reply	other threads:[~2011-06-20  8:48 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-16 16:04 [Qemu-devel] [PATCH 0/3] xen: support PV on HVM guests Stefano Stabellini
2011-06-16 16:05 ` [Qemu-devel] [PATCH RESEND 1/3] xen: Add the Xen platform pci device stefano.stabellini
2011-06-26 13:14   ` Michael S. Tsirkin
2011-06-16 16:05 ` [Qemu-devel] [PATCH 2/3] pci: export pci_unplug_device stefano.stabellini
2011-06-20  8:48   ` Michael S. Tsirkin [this message]
2011-06-23 13:12     ` Stefano Stabellini
2011-06-16 16:05 ` [Qemu-devel] [PATCH 3/3] xen: implement unplug protocol in xen_platform stefano.stabellini
2011-06-17 13:46   ` [Qemu-devel] [Xen-devel] " Anthony PERARD
2011-06-23 13:11     ` Stefano Stabellini
2011-06-20  8:47   ` [Qemu-devel] " Michael S. Tsirkin
     [not found]   ` <7424DA76-FD02-479F-B72A-D0B6EBBDE7DF@suse.de>
2011-06-20  8:59     ` Kevin Wolf
2011-06-23 13:16       ` Stefano Stabellini
2011-06-27  8:26         ` Kevin Wolf
2011-06-27 15:34           ` Stefano Stabellini
2011-06-27 15:46             ` Kevin Wolf
2011-06-28 11:27               ` 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=20110620084856.GB22456@redhat.com \
    --to=mst@redhat.com \
    --cc=Anthony.Perard@citrix.com \
    --cc=agraf@suse.de \
    --cc=qemu-devel@nongnu.org \
    --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).