From nobody Mon Feb 9 09:34:58 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1661281056; cv=none; d=zohomail.com; s=zohoarc; b=NgyE208shKtUmKXpTd61qzaXSbF35CXxKpA8SyV7xknH6agHDevajuSr1MrWMfAKSY3uoUspShb/VXVDLGPhX/dGqY2V3cuSDIhn/1bWb8IpbQdIfBhA4awxPiH8OwIx+C9zSiCNfM6Cfvzrtv/iHcm2wACshY9wGnmlw3ZaU6E= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1661281056; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=H6UNOTTwjb9/JGAV61+drQA/RK8go9Kptgh7fY2TS9c=; b=Q8PbxwMNUyYlorV4+IRZhxokfzSDx12ZwLqdS+aR+KquND8L3r2uUbrXYtr7zUgl4sNKWk8elBzhVVqN5JpxmqnsxI2bV2TEYWLMRJUjtRq8huFXHHkGD3cYsim8bclsTIpqyFqiUNGcbiovQOCor6LwRmfSEg5cODF0raLL0fc= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1661281056179146.59998679706177; Tue, 23 Aug 2022 11:57:36 -0700 (PDT) Received: from localhost ([::1]:52074 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oQZ5j-0004KN-2o for importer@patchew.org; Tue, 23 Aug 2022 14:57:35 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:44814) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oQYgq-0000QK-3c for qemu-devel@nongnu.org; Tue, 23 Aug 2022 14:31:54 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.129.124]:33091) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oQYgl-0004WC-U2 for qemu-devel@nongnu.org; Tue, 23 Aug 2022 14:31:50 -0400 Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-397-H2uAHNXfN8uRzvn8xJoaKw-1; Tue, 23 Aug 2022 14:31:30 -0400 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.rdu2.redhat.com [10.11.54.8]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id D9D988039CF; Tue, 23 Aug 2022 18:31:28 +0000 (UTC) Received: from eperezma.remote.csb (unknown [10.39.195.112]) by smtp.corp.redhat.com (Postfix) with ESMTP id E5096C15BB3; Tue, 23 Aug 2022 18:31:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1661279494; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=H6UNOTTwjb9/JGAV61+drQA/RK8go9Kptgh7fY2TS9c=; b=XxjCYzRY40uj4Sj3n5TR3eXVo5GyPPQysLLAxHh+oUvK1x8UQVurUdjauFmiK/WaDHiEZa L/13Pet4dhWTP5NbV2V74r1Iq4X08Ih73sXfQ5vRjrowEAVHDUzpjPTCoKEXnorH45AyWD xPAPW4bs5hIF6FwJKrIKxuEN+tub/78= X-MC-Unique: H2uAHNXfN8uRzvn8xJoaKw-1 From: =?UTF-8?q?Eugenio=20P=C3=A9rez?= To: qemu-devel@nongnu.org Cc: Laurent Vivier , Parav Pandit , Liuxiangdong , Markus Armbruster , Stefan Hajnoczi , Eric Blake , Zhu Lingshan , Paolo Bonzini , "Gonglei (Arei)" , Eli Cohen , Cornelia Huck , Gautam Dawar , Jason Wang , Stefano Garzarella , "Michael S. Tsirkin" , Harpreet Singh Anand , Cindy Lu Subject: [PATCH v10 12/12] vdpa: Delete CVQ migration blocker Date: Tue, 23 Aug 2022 20:30:37 +0200 Message-Id: <20220823183037.98470-13-eperezma@redhat.com> In-Reply-To: <20220823183037.98470-1-eperezma@redhat.com> References: <20220823183037.98470-1-eperezma@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Scanned-By: MIMEDefang 2.85 on 10.11.54.8 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=170.10.129.124; envelope-from=eperezma@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1661281058314100001 We can restore the device state in the destination via CVQ now. Remove the migration blocker. Signed-off-by: Eugenio P=C3=A9rez Acked-by: Jason Wang --- include/hw/virtio/vhost-vdpa.h | 1 - hw/virtio/vhost-vdpa.c | 15 --------------- net/vhost-vdpa.c | 2 -- 3 files changed, 18 deletions(-) diff --git a/include/hw/virtio/vhost-vdpa.h b/include/hw/virtio/vhost-vdpa.h index d10a89303e..1111d85643 100644 --- a/include/hw/virtio/vhost-vdpa.h +++ b/include/hw/virtio/vhost-vdpa.h @@ -35,7 +35,6 @@ typedef struct vhost_vdpa { bool shadow_vqs_enabled; /* IOVA mapping used by the Shadow Virtqueue */ VhostIOVATree *iova_tree; - Error *migration_blocker; GPtrArray *shadow_vqs; const VhostShadowVirtqueueOps *shadow_vq_ops; void *shadow_vq_ops_opaque; diff --git a/hw/virtio/vhost-vdpa.c b/hw/virtio/vhost-vdpa.c index 23ae5ef48b..7468e44b87 100644 --- a/hw/virtio/vhost-vdpa.c +++ b/hw/virtio/vhost-vdpa.c @@ -1033,13 +1033,6 @@ static bool vhost_vdpa_svqs_start(struct vhost_dev *= dev) return true; } =20 - if (v->migration_blocker) { - int r =3D migrate_add_blocker(v->migration_blocker, &err); - if (unlikely(r < 0)) { - return false; - } - } - for (i =3D 0; i < v->shadow_vqs->len; ++i) { VirtQueue *vq =3D virtio_get_queue(dev->vdev, dev->vq_index + i); VhostShadowVirtqueue *svq =3D g_ptr_array_index(v->shadow_vqs, i); @@ -1082,10 +1075,6 @@ err: vhost_svq_stop(svq); } =20 - if (v->migration_blocker) { - migrate_del_blocker(v->migration_blocker); - } - return false; } =20 @@ -1101,10 +1090,6 @@ static void vhost_vdpa_svqs_stop(struct vhost_dev *d= ev) VhostShadowVirtqueue *svq =3D g_ptr_array_index(v->shadow_vqs, i); vhost_vdpa_svq_unmap_rings(dev, svq); } - - if (v->migration_blocker) { - migrate_del_blocker(v->migration_blocker); - } } =20 static int vhost_vdpa_dev_start(struct vhost_dev *dev, bool started) diff --git a/net/vhost-vdpa.c b/net/vhost-vdpa.c index 640434d1ea..6ce68fcd3f 100644 --- a/net/vhost-vdpa.c +++ b/net/vhost-vdpa.c @@ -555,8 +555,6 @@ static NetClientState *net_vhost_vdpa_init(NetClientSta= te *peer, =20 s->vhost_vdpa.shadow_vq_ops =3D &vhost_vdpa_net_svq_ops; s->vhost_vdpa.shadow_vq_ops_opaque =3D s; - error_setg(&s->vhost_vdpa.migration_blocker, - "Migration disabled: vhost-vdpa uses CVQ."); } ret =3D vhost_vdpa_add(nc, (void *)&s->vhost_vdpa, queue_pair_index, n= vqs); if (ret) { --=20 2.31.1