From patchwork Thu Dec 6 06:35:52 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yongji Xie X-Patchwork-Id: 10715315 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B615C13AF for ; Thu, 6 Dec 2018 06:41:20 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A50EE2E357 for ; Thu, 6 Dec 2018 06:41:20 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 983F22E3DC; Thu, 6 Dec 2018 06:41:20 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.7 required=2.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 4DAE52E357 for ; Thu, 6 Dec 2018 06:41:20 +0000 (UTC) Received: from localhost ([::1]:39112 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gUnLb-0005MM-He for patchwork-qemu-devel@patchwork.kernel.org; Thu, 06 Dec 2018 01:41:19 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52945) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gUnHW-0001cT-Mo for qemu-devel@nongnu.org; Thu, 06 Dec 2018 01:37:10 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gUnHR-0003di-Iv for qemu-devel@nongnu.org; Thu, 06 Dec 2018 01:37:04 -0500 Received: from mail-pl1-x630.google.com ([2607:f8b0:4864:20::630]:40888) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gUnHP-0003ZV-Sg for qemu-devel@nongnu.org; Thu, 06 Dec 2018 01:37:01 -0500 Received: by mail-pl1-x630.google.com with SMTP id u18so11311148plq.7 for ; Wed, 05 Dec 2018 22:36:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=fo/iI2H+MPlzFNyjQ45gXFXk6RlXN6p3eD6WGRIUyeY=; b=X7IWaLpwtKfcvyYrMW83JAlyV9LqezQlM5RaS8FF6p/y+KXVAZfWYdbiZgRDsZhMsc KavA9uJlBCybgfi8H+S63uRBR4gvg7z6FumDxQCX/HS2a9GBmTLifZfmwQOmmjgVNGX5 dTJYDxiBd603o+y5nzG7D0zo4BkPvrue2BGpsiA/jrogQhm8Wg2de9OcIZg0oaKSWVKS 37WdOjpseRzUHOIIh//5J/Q1OEbNGKWgs1pdMO5K0jxSerTU1cuvZqJVroquMD18lGl5 zjwgb8qqHKFnqUXB4ehaZmxQ9ZMnFVrcwLlRPamWvigX0BlSViMSkWyBjTnXP7YyvnkG jHMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=fo/iI2H+MPlzFNyjQ45gXFXk6RlXN6p3eD6WGRIUyeY=; b=i4VLzaK6TYz7ZCuc8kGsvmgNBmClQDHTBB9sMTrsOogl4QbfIvfZlWJPrrTci9i/51 4XsvW7dLBKpOgscAmooQ9GT3oB3oBxXosLkU8H7KE/mw+9nZlsBWGItJUxECKZi3Vdsk /8atA1MKcnnk2dau298DitEFPCuRZV8KWTC1Btw3ho+qPNsCpNmrJLLB1bs5xN14FrQc Gl4aQNmLK+eA/87j/cyf/UVz7Igr8s3UjcMAYvVgE2XdeEv+86M7biaEKhnA4VJiSLqB LhVa4HlGoLYXkxp1+A2ivXMFnoneOQn2RPtkMYwnLli90AoMt531/j2kk2UqQ0lrJbCS umsg== X-Gm-Message-State: AA+aEWYMzTKD+JI90wmdo8s1kGRzowXOMK9BfnxRV5QBn06AtqDQR7Om l1yOb6XmlB2Kg0A5vvquNxelChd69PA= X-Google-Smtp-Source: AFSGD/X5Fau1hyqHBamG6jPJ5FUhXfJMyGWs19nsKO5Hh6bZp5o1pDWuWPaAAyuOEz63smGvAPKM8A== X-Received: by 2002:a17:902:4c85:: with SMTP id b5mr25937391ple.226.1544078216605; Wed, 05 Dec 2018 22:36:56 -0800 (PST) Received: from yongji-Ubuntu.internal.baidu.com ([116.247.112.152]) by smtp.gmail.com with ESMTPSA id x186sm26175249pfb.59.2018.12.05.22.36.54 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 05 Dec 2018 22:36:56 -0800 (PST) From: elohimes@gmail.com X-Google-Original-From: xieyongji@baidu.com To: mst@redhat.com, marcandre.lureau@redhat.com Date: Thu, 6 Dec 2018 14:35:52 +0800 Message-Id: <20181206063552.6701-7-xieyongji@baidu.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20181206063552.6701-1-xieyongji@baidu.com> References: <20181206063552.6701-1-xieyongji@baidu.com> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::630 Subject: [Qemu-devel] [PATCH for-4.0 6/6] contrib/vhost-user-blk: enable inflight I/O recording X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: nixun@baidu.com, qemu-devel@nongnu.org, lilin24@baidu.com, zhangyu31@baidu.com, chaiwen@baidu.com, Xie Yongji Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Xie Yongji This patch tells qemu that we now support inflight I/O recording so that qemu could offer shared memory to it. Signed-off-by: Xie Yongji Signed-off-by: Zhang Yu --- contrib/vhost-user-blk/vhost-user-blk.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/contrib/vhost-user-blk/vhost-user-blk.c b/contrib/vhost-user-blk/vhost-user-blk.c index 571f114a56..f87f9de8cd 100644 --- a/contrib/vhost-user-blk/vhost-user-blk.c +++ b/contrib/vhost-user-blk/vhost-user-blk.c @@ -328,7 +328,8 @@ vub_get_features(VuDev *dev) static uint64_t vub_get_protocol_features(VuDev *dev) { - return 1ull << VHOST_USER_PROTOCOL_F_CONFIG; + return 1ull << VHOST_USER_PROTOCOL_F_CONFIG | + 1uLL << VHOST_USER_PROTOCOL_F_INFLIGHT_SHMFD; } static int