From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DCB11C04AAF for ; Thu, 16 May 2019 12:28:38 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A7E8020848 for ; Thu, 16 May 2019 12:28:38 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A7E8020848 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([127.0.0.1]:53878 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hRFUz-00009t-Rp for qemu-devel@archiver.kernel.org; Thu, 16 May 2019 08:28:37 -0400 Received: from eggs.gnu.org ([209.51.188.92]:48765) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hRFLg-0000BQ-KW for qemu-devel@nongnu.org; Thu, 16 May 2019 08:19:03 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hRFLc-0001d2-Rw for qemu-devel@nongnu.org; Thu, 16 May 2019 08:18:59 -0400 Received: from mail-qt1-f178.google.com ([209.85.160.178]:44358) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hRFLc-0001cV-PL for qemu-devel@nongnu.org; Thu, 16 May 2019 08:18:56 -0400 Received: by mail-qt1-f178.google.com with SMTP id f24so3511079qtk.11 for ; Thu, 16 May 2019 05:18:56 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=CpsnX50FvethOzWJ3djTyRAM8ldWob1tvvlTZoMS0wc=; b=jlHAgvEA9+cumeozCmu/YoJHJ/XlZZPd1pre7uQi1V9kgsNZvpABZKlLG8TPAr9pju +818mXNwfN1IB8wbqN+ne0cV7BKw5mOHNNJ1dTY3cr4Pd4y+D4YonUHPn1idHYcgZNrU DtaN24xPqX8gLhuhRwKYoThrMTHbjYjZe0vmlUKqC72NrY82eo9RatieljeiZJ00oqf2 zwqLYtlV9BSkxSYi0njZIHXrL1m+J2EuWfhCxYv5Uhfsr1obMBICAlaRG3YiW5uOWvHj EBB4iQRxdDS1EwxjsADhgVb2MJBmKavltwyVhC/kWxBiTy7pEq9VOSkjjVQ92YORvuAR Y7kw== X-Gm-Message-State: APjAAAX/63zheGixonaauxvGwnBvA+IxkfLJPpXBJWn2kUP8KexLGd7i 2iOYpB1M7kaKSF4fDFiCwyzYSM5Mzr4= X-Google-Smtp-Source: APXvYqzkmamseeeF2ZNRoXyafyrxcl1n3VGjzSKCzf4n1ncG7v5+MoQ/gnwzdKsKNIsLT9h0PHOW9Q== X-Received: by 2002:a0c:9e55:: with SMTP id z21mr39731123qve.45.1558009136021; Thu, 16 May 2019 05:18:56 -0700 (PDT) Received: from redhat.com ([185.54.206.10]) by smtp.gmail.com with ESMTPSA id f127sm2871871qkb.53.2019.05.16.05.18.54 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Thu, 16 May 2019 05:18:55 -0700 (PDT) Date: Thu, 16 May 2019 08:18:52 -0400 From: "Michael S. Tsirkin" To: qemu-devel@nongnu.org Message-ID: <20190320112646.3712-8-xieyongji@baidu.com> References: <20190515121146.7248-1-mst@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190515121146.7248-1-mst@redhat.com> X-Mailer: git-send-email 2.17.1.1206.gb667731e2e.dirty X-Mutt-Fcc: =sent X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.85.160.178 Subject: [Qemu-devel] [PULL 10/37] contrib/vhost-user-blk: enable inflight I/O tracking 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: Peter Maydell , Xie Yongji , Zhang Yu Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" From: Xie Yongji This patch enables inflight I/O tracking for vhost-user-blk backend so that we could restart it safely. Signed-off-by: Xie Yongji Signed-off-by: Zhang Yu Message-Id: <20190320112646.3712-8-xieyongji@baidu.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- 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 43583f2659..86a3987744 100644 --- a/contrib/vhost-user-blk/vhost-user-blk.c +++ b/contrib/vhost-user-blk/vhost-user-blk.c @@ -398,7 +398,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 -- MST From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B65A4C04AAC for ; Mon, 20 May 2019 23:15:47 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 88EB92171F for ; Mon, 20 May 2019 23:15:47 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 88EB92171F Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([127.0.0.1]:43391 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hSrVS-0002WY-Ke for qemu-devel@archiver.kernel.org; Mon, 20 May 2019 19:15:46 -0400 Received: from eggs.gnu.org ([209.51.188.92]:44900) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hSrQg-00074I-LP for qemu-devel@nongnu.org; Mon, 20 May 2019 19:10:51 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hSrQf-00080N-LL for qemu-devel@nongnu.org; Mon, 20 May 2019 19:10:50 -0400 Received: from mail-qk1-f178.google.com ([209.85.222.178]:41326) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hSrQf-0007zu-Gs for qemu-devel@nongnu.org; Mon, 20 May 2019 19:10:49 -0400 Received: by mail-qk1-f178.google.com with SMTP id m18so91617qki.8 for ; Mon, 20 May 2019 16:10:49 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=CpsnX50FvethOzWJ3djTyRAM8ldWob1tvvlTZoMS0wc=; b=FAZvXbV+fMwH5eFffkJSyj/jUkOTbDXRMuGR6dOgayeauED3VRRrluLoAsopItRkLO 3AILasMWrvwJk5volzZBWx0MIKbkp8/GG6Xl8Lgds7553CAeD5CVhKUtdUSTPrWiETL5 SCBF6r1SPNk5X44ilBfuAw6H4h3WzaMGo924on/bfjlsWYXtZC4bWk/1bziRAIVjreGC zofIBlIZB1x/rNjEOzhtsTxdHtPC9AYhsVX1yCnOJNI1vy2O6ax75ddF+NcTckISI9GC Y62ZdSiAHNeR3ERZuB0PttQ++0eRsl/xB5SzJ3MiVc1Td8FEv8BbeQvvgy4GWyAdBgJh JvbA== X-Gm-Message-State: APjAAAVdxjRhq5YTP6wNaxf8AL05HqczNHzug/8yhQCENhhQI5QvQJK4 xUi+RTCKxCiivIET4Bpli2WlILYQOSE= X-Google-Smtp-Source: APXvYqwcJG7drmG1kULlno37AjXYV51bcFabQtN5QFzcVl1n9YgBWIEJ9HtV5xegOJmV6YBlrsDRVg== X-Received: by 2002:a37:4c1:: with SMTP id 184mr21630128qke.322.1558393848690; Mon, 20 May 2019 16:10:48 -0700 (PDT) Received: from redhat.com (pool-173-76-105-71.bstnma.fios.verizon.net. [173.76.105.71]) by smtp.gmail.com with ESMTPSA id v13sm8822809qkj.3.2019.05.20.16.10.47 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Mon, 20 May 2019 16:10:48 -0700 (PDT) Date: Mon, 20 May 2019 19:10:46 -0400 From: "Michael S. Tsirkin" To: qemu-devel@nongnu.org Message-ID: <20190320112646.3712-8-xieyongji@baidu.com> References: <20190520231008.20140-1-mst@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Disposition: inline In-Reply-To: <20190520231008.20140-1-mst@redhat.com> X-Mailer: git-send-email 2.17.1.1206.gb667731e2e.dirty X-Mutt-Fcc: =sent X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.85.222.178 Subject: [Qemu-devel] [PULL v2 10/36] contrib/vhost-user-blk: enable inflight I/O tracking 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: Peter Maydell , Xie Yongji , Zhang Yu Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" Message-ID: <20190520231046.mdfiJI4HcxpYHETHWX9sUFlUoBI8OreaZeGZW-De5Cg@z> From: Xie Yongji This patch enables inflight I/O tracking for vhost-user-blk backend so that we could restart it safely. Signed-off-by: Xie Yongji Signed-off-by: Zhang Yu Message-Id: <20190320112646.3712-8-xieyongji@baidu.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- 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 43583f2659..86a3987744 100644 --- a/contrib/vhost-user-blk/vhost-user-blk.c +++ b/contrib/vhost-user-blk/vhost-user-blk.c @@ -398,7 +398,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 -- MST