All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marcelo Tosatti <mtosatti@redhat.com>
To: Amos Kong <akong@redhat.com>
Cc: Gleb Natapov <gleb@redhat.com>,
	seabios@seabios.org, kvm@vger.kernel.org, jasowang@redhat.com,
	alex williamson <alex.williamson@redhat.com>,
	"Michael S. Tsirkin" <mst@redhat.com>
Subject: Re: [SeaBIOS PATCH] hotplug: Add device per func in ACPI DSDT tables
Date: Tue, 20 Sep 2011 08:42:41 -0300	[thread overview]
Message-ID: <20110920114241.GA25141@amt.cnet> (raw)
In-Reply-To: <ba8ba281-812a-4d5a-b85b-85fd6931b85b@zmail05.collab.prod.int.phx2.redhat.com>

On Tue, Sep 20, 2011 at 06:44:54AM -0400, Amos Kong wrote:
> ----- Original Message -----
> > On Mon, Sep 19, 2011 at 01:02:59PM +0300, Michael S. Tsirkin wrote:
> > > On Mon, Sep 19, 2011 at 12:57:33PM +0300, Gleb Natapov wrote:
> > > > On Mon, Sep 19, 2011 at 03:27:38AM -0400, Amos Kong wrote:
> > > > > 
> > > > > Only func 0 is registered to guest driver (we can
> > > > > only found func 0 in slot->funcs list of driver),
> > > > > the other functions could not be cleaned when
> > > > > hot-removing the whole slot. This patch adds
> > > > > device per function in ACPI DSDT tables.
> > > > > 
> > > > You can't unplug a single function. Guest surely knows that.
> > > 
> > > Looking at guest code, it's clear that
> > > at least a Linux guest doesn't know that.
> > 
> > acpiphp_disable_slot function appears to eject all functions.
> >
> > > > > Have tested with linux/winxp/win7, hot-adding/hot-remving,
> > > > > single/multiple function device, they are all fine.
> > > > > 
> > 
> > Does not work for me (FC12 guest).
> 
> what's your problem?  only func 0 can be added?
> I hotplug/hot-remove device by this script(add func 1~7, then add func 0):
> 
> j=6
> for i in `seq 1 7` 0;do
> qemu-img create /tmp/resize$j$i.qcow2 10M -f qcow2
> echo drive_add 0x$j.$i id=drv$j$i,if=none,file=/tmp/resize$j$i.qcow2 | nc -U /tmp/a
> echo device_add virtio-blk-pci,id=dev$j$i,drive=drv$j$i,addr=0x$j.$i,multifunction=on | nc -U /tmp/monitor
> done
> sleep 5;
> echo device_del dev60 | nc -U /tmp/monitor
> 
> > As mentioned previously, Linux driver
> > looks for function 0 when injection request is seen (see
> > enable_device
> > function in acpiphp_glue.c).
> >
> > > > What was not fine before?
> 
> When hot-removing multifunc device, only func 0 can be removed from guest.

Ah OK, musunderstood the patch was aiming for per-function hotplug.


  reply	other threads:[~2011-09-20 11:47 UTC|newest]

Thread overview: 56+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-19  6:53 [SEABIOS PATCH 0/2] fix of hotplug multi-func device Amos Kong
2011-09-19  6:53 ` [SeaBIOS PATCH 1/2] Fix regression of commit 87b533bf Amos Kong
2011-09-19  7:27   ` [SeaBIOS PATCH 2/2] hotplug: Add device per func in ACPI DSDT tables Amos Kong
2011-09-19  9:57     ` [SeaBIOS] " Gleb Natapov
2011-09-19 10:02       ` Michael S. Tsirkin
2011-09-19 10:12         ` Gleb Natapov
2011-09-19 10:32           ` Gleb Natapov
2011-09-19 12:18             ` [SeaBIOS] " Michael S. Tsirkin
2011-09-19 16:27         ` Marcelo Tosatti
2011-09-19 19:08           ` Michael S. Tsirkin
2011-09-20 10:45             ` [SeaBIOS PATCH v2] " Amos Kong
2011-09-20 11:47               ` Marcelo Tosatti
2011-09-21  1:48               ` Kevin O'Connor
2011-09-21  5:39                 ` Amos Kong
2011-09-21 11:09                   ` Michael S. Tsirkin
2011-09-21 12:47                     ` Kevin O'Connor
2011-09-21 13:14                       ` Michael S. Tsirkin
2011-12-06  5:39                         ` [SeaBIOS PATCH v3] " Amos Kong
2011-12-06 11:36                           ` Michael S. Tsirkin
2011-12-07  0:32                             ` Amos Kong
2011-12-14  1:06                               ` Kevin O'Connor
2011-12-19  8:45                                 ` Amos Kong
2012-05-09  7:24                                 ` [RESEND PATCH v3] hotplug: add " Amos Kong
2012-05-09  7:24                                   ` [Qemu-devel] " Amos Kong
2012-05-09  7:35                                   ` Amos Kong
2012-05-09  8:46                                   ` Michael S. Tsirkin
2012-05-09  8:46                                     ` [Qemu-devel] " Michael S. Tsirkin
2012-05-09  8:59                                     ` Amos Kong
2012-05-09  9:53                                       ` Amos Kong
2012-05-09 13:47                                   ` Alex Williamson
2012-05-09 13:47                                     ` [Qemu-devel] " Alex Williamson
2012-05-09 16:08                                     ` Amos Kong
2012-05-10 16:50                                     ` Jiang Liu
2012-05-10 16:50                                       ` [Qemu-devel] " Jiang Liu
2012-05-10 17:03                                       ` Michael S. Tsirkin
2012-05-10 17:03                                         ` [Qemu-devel] " Michael S. Tsirkin
2012-05-10 17:17                                   ` Jiang Liu
2012-05-10 17:17                                     ` [Qemu-devel] " Jiang Liu
2012-05-10 17:42                                     ` Michael S. Tsirkin
2012-05-10 17:42                                       ` [Qemu-devel] " Michael S. Tsirkin
2012-05-10 17:46                                       ` Jiang Liu
2012-05-10 17:46                                         ` [Qemu-devel] " Jiang Liu
2012-05-10 23:40                                         ` Amos Kong
2012-05-10 23:40                                           ` Amos Kong
2012-05-11 10:14                                         ` [SeaBIOS] " Gleb Natapov
2012-05-11 10:14                                           ` [Qemu-devel] " Gleb Natapov
2012-05-11 15:44                                           ` Jiang Liu
2012-05-11 15:44                                             ` [Qemu-devel] " Jiang Liu
2012-05-11 17:04                                             ` Gleb Natapov
2012-05-11 17:04                                               ` [Qemu-devel] " Gleb Natapov
2011-09-20 10:44           ` [SeaBIOS PATCH] hotplug: Add " Amos Kong
2011-09-20 11:42             ` Marcelo Tosatti [this message]
2011-09-20  8:00   ` [SeaBIOS PATCH v2] Fix regression of commit 87b533bf Amos Kong
2011-09-20 23:52     ` Kevin O'Connor
     [not found] ` <20110919065347.22802.53640.stgit@t>
     [not found]   ` <20110919093644.GC4501@redhat.com>
2011-09-19  9:49     ` [SeaBIOS PATCH 2/2] hotplug: Add device per func in ACPI DSDT tables Michael S. Tsirkin
2011-09-19 10:04     ` Michael S. Tsirkin

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=20110920114241.GA25141@amt.cnet \
    --to=mtosatti@redhat.com \
    --cc=akong@redhat.com \
    --cc=alex.williamson@redhat.com \
    --cc=gleb@redhat.com \
    --cc=jasowang@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=mst@redhat.com \
    --cc=seabios@seabios.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.