Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp11666584rwl; Tue, 3 Jan 2023 02:59:06 -0800 (PST) X-Google-Smtp-Source: AMrXdXvltWYG0bS4E9cX65joPVPFa7kC9ciZwGdox7QtgaXWWVBBJK4oQzFum8CUwpFfub2Y+jGf X-Received: by 2002:a05:6402:3454:b0:47f:ab65:b3f4 with SMTP id l20-20020a056402345400b0047fab65b3f4mr32639037edc.39.1672743546148; Tue, 03 Jan 2023 02:59:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1672743546; cv=none; d=google.com; s=arc-20160816; b=Gelz69qax7vSjNbViS4KqkClXhPTelFb5J2aqWBqw3BG8EADIntA50RqSmtFvLNHPt /cbKr8DI8lbKSt0X3mfvyYkktP6WHa+/Q6qVTC8Gzsae1aNsffw8RkF3BGPpMCEBWRW+ d2xpXb32dMg6uETXFhMaDckh0X/XsGv/Q29MqAfVS0aXLAslGaIT4r995krg5mHWrm9V IZYBZjjoBkcsB8aNq4/J0IwBcpQY2TTP+jhcSp6azyxaWA3jvLHD02HZgClAepvIcwpo 3Y0VPJWR34E30ReEmVPjITV+EHp0EmJ78ry97oHUnWrMzyvr3gHwjN7ZWmJT4gBzPgY3 yfUg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=Po5mA/pVlcaRxgId4g3xaZlUryDT8KhCqLtv1JdVHVg=; b=okE4NV+IJrP2wbSVdh8lWiZD7ANJ9cEIpOvctc+CA7hd/HcaFY8g5xbogvbwNOLfb6 TLm8zR78rj0W/tN+fP8VOAL1lqmqzatzAgQXdbpjK4NG+8tWWOaFmaH/Lhm8qq/gXPL1 eYAVdD77Kh2RAlxeKShTq2zxpeOeL05PythoS/aHv6rNuta3GMEDsFhBNPVujjWa3YOn PFnOt1R5a5csNo8Pe1Ks/PpPtdRvcym6WmN1DcRickTuk6FAJE4XRxKhoJcfrie9KHnu NsLgnF+6abLRZWfxabvg6Abh3XCrIc+FXperJopcCr55qmnQNXbB9QKLxb5s184s/PZj O63Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=WJsjIH2W; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f5-20020aa7d845000000b00477cb6f619csi24495292eds.48.2023.01.03.02.58.51; Tue, 03 Jan 2023 02:59:06 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=WJsjIH2W; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237216AbjACKwC (ORCPT + 61 others); Tue, 3 Jan 2023 05:52:02 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39450 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233201AbjACKv3 (ORCPT ); Tue, 3 Jan 2023 05:51:29 -0500 Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2566C2EB for ; Tue, 3 Jan 2023 02:51:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1672743088; x=1704279088; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=wZIzAnD2Xss5kwfCgAar7pXr1H0VlnByMy323xYAXro=; b=WJsjIH2WiNpXNMCucqncfJd7WgkiJIJ6FdT8okx53lhfJbayz5aWMZW+ oVZ9Rxqyp3ZU4KTmES05IN508MX3Hj381+ApbMhALm5mNZgn3qbKd6S5x jssJr12lE70MsC1UrqL9111q2OvDXJzPigbSvnZ1A2j6fTwHGsl7WKv7J YCzDIZAUyFR71eBc4mPXvNkne8DHUOBGSMpLHfIcPadLifqVBENMw0LZT LpKyiRk3G9hhLTqrZ9eQ/TU9Rk6+uuZdNM7AkzMVM3CLiHWrRRaPPvVMu MCZpZTjxX3yLcaKDU22mooNsKTNW6EZ8/KA0D3FbWjdQaELlRw8Lvk9Zy w==; X-IronPort-AV: E=McAfee;i="6500,9779,10578"; a="301318421" X-IronPort-AV: E=Sophos;i="5.96,296,1665471600"; d="scan'208";a="301318421" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Jan 2023 02:51:27 -0800 X-IronPort-AV: E=McAfee;i="6500,9779,10578"; a="604772632" X-IronPort-AV: E=Sophos;i="5.96,296,1665471600"; d="scan'208";a="604772632" Received: from isobansk-mobl1.ger.corp.intel.com (HELO sboeuf-mobl.home) ([10.252.24.246]) by orsmga003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Jan 2023 02:51:25 -0800 From: sebastien.boeuf@intel.com To: linux-kernel@vger.kernel.org, virtualization@lists.linux-foundation.org Cc: mst@redhat.com, jasowang@redhat.com, eperezma@redhat.com, sebastien.boeuf@intel.com Subject: [PATCH v6 0/4] vdpa: Add resume operation Date: Tue, 3 Jan 2023 11:51:04 +0100 Message-Id: X-Mailer: git-send-email 2.37.2 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,LOTS_OF_MONEY, RCVD_IN_DNSWL_MED,SPF_HELO_PASS,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Sebastien Boeuf This series introduces a new operation for vdpa devices. It allows them to be resumed after they have been suspended. A new feature bit is introduced for devices to advertise their ability to be resumed after they have been suspended. This feature bit is different from the one advertising the ability to be suspended, meaning a device that can be suspended might not have the ability to be resumed. Even if it is already possible to restore a device that has been suspended, which is very convenient for live migrating virtual machines, there is a major drawback as the device must be fully reset. There is no way to resume a device that has been suspended without having to configure the device again and without having to recreate the IOMMU mappings. This new operation aims at filling this gap by allowing the device to resume processing the virtqueue descriptors without having to reset it. This is particularly useful for performing virtual machine offline migration, also called snapshot/restore, as it allows a virtual machine to resume to a running state after it was paused and a snapshot of the entire system was taken. Sebastien Boeuf (4): vdpa: Add resume operation vhost-vdpa: Introduce RESUME backend feature bit vhost-vdpa: uAPI to resume the device vdpa_sim: Implement resume vdpa op drivers/vdpa/vdpa_sim/vdpa_sim.c | 29 +++++++++++++++++++++++++++ drivers/vdpa/vdpa_sim/vdpa_sim.h | 1 + drivers/vhost/vdpa.c | 34 +++++++++++++++++++++++++++++++- include/linux/vdpa.h | 6 +++++- include/uapi/linux/vhost.h | 8 ++++++++ include/uapi/linux/vhost_types.h | 2 ++ 6 files changed, 78 insertions(+), 2 deletions(-) -- 2.37.2 --------------------------------------------------------------------- Intel Corporation SAS (French simplified joint stock company) Registered headquarters: "Les Montalets"- 2, rue de Paris, 92196 Meudon Cedex, France Registration Number: 302 456 199 R.C.S. NANTERRE Capital: 5 208 026.16 Euros This e-mail and any attachments may contain confidential material for the sole use of the intended recipient(s). Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies.