From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49082) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZoT2I-00023e-AG for qemu-devel@nongnu.org; Tue, 20 Oct 2015 05:16:51 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZoT2F-0005F8-3y for qemu-devel@nongnu.org; Tue, 20 Oct 2015 05:16:50 -0400 Received: from e06smtp07.uk.ibm.com ([195.75.94.103]:46219) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZoT2E-0005EX-QE for qemu-devel@nongnu.org; Tue, 20 Oct 2015 05:16:47 -0400 Received: from localhost by e06smtp07.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 20 Oct 2015 10:16:44 +0100 Received: from b06cxnps3075.portsmouth.uk.ibm.com (d06relay10.portsmouth.uk.ibm.com [9.149.109.195]) by d06dlp01.portsmouth.uk.ibm.com (Postfix) with ESMTP id 85B0B17D8063 for ; Tue, 20 Oct 2015 10:16:51 +0100 (BST) Received: from d06av05.portsmouth.uk.ibm.com (d06av05.portsmouth.uk.ibm.com [9.149.37.229]) by b06cxnps3075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id t9K9GhF234472080 for ; Tue, 20 Oct 2015 09:16:43 GMT Received: from d06av05.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av05.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id t9K9Ggbl000419 for ; Tue, 20 Oct 2015 03:16:42 -0600 From: Greg Kurz Date: Tue, 20 Oct 2015 11:16:40 +0200 Message-ID: <20151020091640.25419.99985.stgit@bahia.huguette.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] [PATCH v3 0/5] virtio-9p: hotplug and migration support List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Cornelia Huck , "Michael S. Tsirkin" , Alexander Graf , Andreas =?utf-8?q?F=C3=A4rber?= , aneesh.kumar@linux.vnet.ibm.com We already have a blocker to prevent migration of an active virtio-9p device. But in fact, there is no migration support at all for 9p, even if the device is considered to be quiescent (when the VirtFS share is not mounted): migration succeeds but the device is lost in the restarted guest. Hotunplug of a virtio-9p device is not supported either (no unrealize handler) and leads to a QEMU crash on the source node, if one unplugs and migrates. This series tries to fix that and brings hotplug and migration support of *quiescent* virtio-9p devices. v2->v3: - renamed QDEV handler @unpluggable to @unplug_is_blocked (patches 2/5 and 3/5) v1->v2: - introduced unplug blocker (patches 2/5 and 3/5) - moved fixes to separate patches (see individual changelogs) --- Greg Kurz (5): virtio-9p-coth: fix init function qdev: add the @unplug_is_blocked handler virtio-9p: block hot-unplug when device is active virtio-9p: add unrealize handler virtio-9p: add savem handlers hw/9pfs/virtio-9p-coth.c | 22 ++++++++++++++++++---- hw/9pfs/virtio-9p-coth.h | 2 ++ hw/9pfs/virtio-9p-device.c | 24 ++++++++++++++++++++++++ hw/9pfs/virtio-9p.c | 14 ++++++++++++++ hw/9pfs/virtio-9p.h | 2 ++ hw/core/qdev.c | 4 ++++ hw/s390x/virtio-ccw.c | 8 ++++++++ hw/virtio/virtio-pci.c | 8 ++++++++ include/hw/qdev-core.h | 4 ++++ 9 files changed, 84 insertions(+), 4 deletions(-)