From patchwork Thu Feb 21 15:26:37 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrey Shinkevich X-Patchwork-Id: 10824181 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 DE40115AC for ; Thu, 21 Feb 2019 15:27:56 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CAB1C2EDB8 for ; Thu, 21 Feb 2019 15:27:56 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id BD14931727; Thu, 21 Feb 2019 15:27:56 +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=-2.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI autolearn=ham version=3.3.1 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.wl.linuxfoundation.org (Postfix) with ESMTPS id 646BB2EDB8 for ; Thu, 21 Feb 2019 15:27:56 +0000 (UTC) Received: from localhost ([127.0.0.1]:33828 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gwqGR-0005Uq-Fo for patchwork-qemu-devel@patchwork.kernel.org; Thu, 21 Feb 2019 10:27:55 -0500 Received: from eggs.gnu.org ([209.51.188.92]:33477) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gwqFN-0004dO-AT for qemu-devel@nongnu.org; Thu, 21 Feb 2019 10:26:49 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gwqFJ-0000dn-52 for qemu-devel@nongnu.org; Thu, 21 Feb 2019 10:26:46 -0500 Received: from relay.sw.ru ([185.231.240.75]:45236) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gwqFI-0000a6-IA; Thu, 21 Feb 2019 10:26:44 -0500 Received: from [172.16.25.136] (helo=localhost.sw.ru) by relay.sw.ru with esmtp (Exim 4.91) (envelope-from ) id 1gwqFD-0000sC-NM; Thu, 21 Feb 2019 18:26:39 +0300 From: Andrey Shinkevich To: qemu-devel@nongnu.org, qemu-block@nongnu.org Date: Thu, 21 Feb 2019 18:26:37 +0300 Message-Id: <1550762799-830661-1-git-send-email-andrey.shinkevich@virtuozzo.com> X-Mailer: git-send-email 1.8.3.1 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 185.231.240.75 Subject: [Qemu-devel] [PATCH 0/2] block-stream: include base into job node list 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: kwolf@redhat.com, vsementsov@virtuozzo.com, berto@igalia.com, mreitz@redhat.com, andrey.shinkevich@virtuozzo.com, den@openvz.org Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP The block-stream job needs to own the base node as the limiter for the copy-on-read operation. So, the base node is included in the job node list by calling to the function block_job_add_bdrv(). Also, the block-stream job would not allow the base node to go away due to the graph modification, e.g. when a filter node is inserted between the bottom node and the base node. For that reason, the flag BLK_PERM_GRAPH_MOD is unset in the shared permission bit mask of the base node. Andrey Shinkevich (2): iotests: 030 TestParallelOps non-shared base node block-stream: include base node into the job protected list block/stream.c | 9 +++++++++ tests/qemu-iotests/030 | 34 ++++++++++++++++++---------------- 2 files changed, 27 insertions(+), 16 deletions(-)