From patchwork Thu Apr 11 14:41:08 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Beno=C3=AEt_Canet?= X-Patchwork-Id: 235775 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id EFF092C00C0 for ; Fri, 12 Apr 2013 00:42:31 +1000 (EST) Received: from localhost ([::1]:32860 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UQIhq-0005rc-5A for incoming@patchwork.ozlabs.org; Thu, 11 Apr 2013 10:42:30 -0400 Received: from eggs.gnu.org ([208.118.235.92]:37939) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UQIg0-0003iA-Jf for qemu-devel@nongnu.org; Thu, 11 Apr 2013 10:40:39 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UQIfw-0001nF-Ml for qemu-devel@nongnu.org; Thu, 11 Apr 2013 10:40:36 -0400 Received: from nodalink.pck.nerim.net ([62.212.105.220]:43180 helo=paradis.irqsave.net) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UQIfw-0001n4-Cn for qemu-devel@nongnu.org; Thu, 11 Apr 2013 10:40:32 -0400 Received: by paradis.irqsave.net (Postfix, from userid 1002) id 9C94687432C; Thu, 11 Apr 2013 16:40:31 +0200 (CEST) Received: from localhost.localdomain (unknown [192.168.77.1]) by paradis.irqsave.net (Postfix) with ESMTP id 2AA0287434E; Thu, 11 Apr 2013 16:39:59 +0200 (CEST) From: =?UTF-8?q?Beno=C3=AEt=20Canet?= To: qemu-devel@nongnu.org Date: Thu, 11 Apr 2013 16:41:08 +0200 Message-Id: <1365691268-18036-4-git-send-email-benoit@irqsave.net> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1365691268-18036-1-git-send-email-benoit@irqsave.net> References: <1365691268-18036-1-git-send-email-benoit@irqsave.net> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 62.212.105.220 Cc: peter.maydell@linaro.org, pbonzini@redhat.com, =?UTF-8?q?Beno=C3=AEt=20Canet?= , aneesh.kumar@linux.vnet.ibm.com, quintela@redhat.com Subject: [Qemu-devel] [PATCH V2 3/3] virtio-9p: Remove migration blockers. X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Signed-off-by: Benoit Canet --- hw/9pfs/virtio-9p.c | 23 ----------------------- hw/9pfs/virtio-9p.h | 2 -- 2 files changed, 25 deletions(-) diff --git a/hw/9pfs/virtio-9p.c b/hw/9pfs/virtio-9p.c index 66322ee..d81087b 100644 --- a/hw/9pfs/virtio-9p.c +++ b/hw/9pfs/virtio-9p.c @@ -404,19 +404,6 @@ static int put_fid(V9fsPDU *pdu, V9fsFidState *fidp) * Don't free the fid if it is in reclaim list */ if (!fidp->ref && fidp->clunked) { - if (fidp->fid == pdu->s->root_fid) { - /* - * if the clunked fid is root fid then we - * have unmounted the fs on the client side. - * delete the migration blocker. Ideally, this - * should be hooked to transport close notification - */ - if (pdu->s->migration_blocker) { - migrate_del_blocker(pdu->s->migration_blocker); - error_free(pdu->s->migration_blocker); - pdu->s->migration_blocker = NULL; - } - } return free_fid(pdu, fidp); } return 0; @@ -1053,16 +1040,6 @@ static void v9fs_attach(void *opaque) err += offset; trace_v9fs_attach_return(pdu->tag, pdu->id, qid.type, qid.version, qid.path); - /* - * disable migration if we haven't done already. - * attach could get called multiple times for the same export. - */ - if (!s->migration_blocker) { - s->root_fid = fid; - error_set(&s->migration_blocker, QERR_VIRTFS_FEATURE_BLOCKS_MIGRATION, - s->ctx.fs_root ? s->ctx.fs_root : "NULL", s->tag); - migrate_add_blocker(s->migration_blocker); - } out: put_fid(pdu, fidp); out_nofid: diff --git a/hw/9pfs/virtio-9p.h b/hw/9pfs/virtio-9p.h index 604502a..acd6703 100644 --- a/hw/9pfs/virtio-9p.h +++ b/hw/9pfs/virtio-9p.h @@ -223,8 +223,6 @@ typedef struct V9fsState * on rename. */ CoRwlock rename_lock; - int32_t root_fid; - Error *migration_blocker; } V9fsState; typedef struct V9fsStatState {