From patchwork Mon Mar 12 10:16:51 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anton Nefedov X-Patchwork-Id: 10275905 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B3ACA60467 for ; Mon, 12 Mar 2018 10:19:08 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BA69228CAC for ; Mon, 12 Mar 2018 10:19:08 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id AED6328CE6; Mon, 12 Mar 2018 10:19:08 +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=-6.8 required=2.0 tests=BAD_ENC_HEADER,BAYES_00, DKIM_SIGNED, RCVD_IN_DNSWL_HI, T_DKIM_INVALID 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 2CB9E28CAC for ; Mon, 12 Mar 2018 10:19:07 +0000 (UTC) Received: from localhost ([::1]:57492 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1evKXp-0004Cm-Tb for patchwork-qemu-devel@patchwork.kernel.org; Mon, 12 Mar 2018 06:19:05 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33556) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1evKWG-0002iv-1z for qemu-devel@nongnu.org; Mon, 12 Mar 2018 06:17:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1evKWC-0006bB-7Z for qemu-devel@nongnu.org; Mon, 12 Mar 2018 06:17:27 -0400 Received: from mail-eopbgr10121.outbound.protection.outlook.com ([40.107.1.121]:6708 helo=EUR02-HE1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1evKWB-0006Rl-V2; Mon, 12 Mar 2018 06:17:24 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=l04CULP2N96xPdMjnSCBU9E+8nhX4a9z06uAeZKwMwM=; b=S35WhydIAOZLfcFRvrzZhUUHmMaYtU5N42yh2mzd2hQAjxVE5sChrhlNA/DhPugnyRKK0MTD/SMfI2W9F3t0/UxWc+Wal4DnhCTa5QoavNgEIUdlvpzX7XZ3LaEYiW4srIbFv2Kpsn6dRCyRqS+ri+48jM3YlFUVg1uztf8VLzk= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=anton.nefedov@virtuozzo.com; Received: from xantnef-ws.sw.ru (195.214.232.6) by DB6PR0801MB1991.eurprd08.prod.outlook.com (2603:10a6:4:76::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.567.14; Mon, 12 Mar 2018 10:17:21 +0000 From: Anton Nefedov To: qemu-devel@nongnu.org Date: Mon, 12 Mar 2018 13:16:51 +0300 Message-Id: <1520849818-6915-3-git-send-email-anton.nefedov@virtuozzo.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1520849818-6915-1-git-send-email-anton.nefedov@virtuozzo.com> References: <1520849818-6915-1-git-send-email-anton.nefedov@virtuozzo.com> MIME-Version: 1.0 X-Originating-IP: [195.214.232.6] X-ClientProxiedBy: HE1PR06CA0148.eurprd06.prod.outlook.com (2603:10a6:7:16::35) To DB6PR0801MB1991.eurprd08.prod.outlook.com (2603:10a6:4:76::8) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 7103e49f-e183-4e4a-896a-08d58802719a X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4604075)(4534165)(7168020)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:DB6PR0801MB1991; X-Microsoft-Exchange-Diagnostics: 1; DB6PR0801MB1991; 3:LuTVQSWhRLNHzjeqOb9GSh9kpFdI2tB3552EoJsqram3F6up4881KR59XHKe5mY0OkDdjEHxaTbpzKL8Or91HfYt0mrMhMHamZf9WEEBWaBAYkXaXj4Lw7AG6WnuOMxmKc7YJMDV5k7Qm6cVgfeSNm/kPkbYHQu+RU3J0zA0ArQ4uDNM1suzQpvi532ywsapuTFNLvoWIaUpVjb8jZzPjI0NSgj4Ni5ug2aIWl/wF8O34OlWOnaIm2dHz6qx+riN; 25:Nt4CXHL/YRVXzfVpxCtU73PkDoL/9WQZFi3z6GczIX3RxxH/OYHogh7RpZy+BDtthC+aGNaySK0rE79RONtjOe39VOB/aP/nZNS4YdoZeOeAoVvJ6fUHVo92908lplzveYS0vnvW13Sad+4+qp14vZH9e93o8GoasNDRndt9NgwJwG2dGy85kCH5Wcc4e0KIfYzSEXsS1rLfmdxR1d1U3oJJMnr6eP1/KgvOWpeUDtKbsI9H6CYaKjW2aRI/+LU2mglTj0cbUguPm5pgyRrviUbH+qgol4j8VzKdt5sFhdxLu6HR3VwAgtc64SQLUD/rj2HsMtDhcr94pguPJ+W/jw==; 31:Lq72BrMqppvwCQ2FMshYXGVXqUa0Hb6HCZYh+rFJhv2IMoe1PAGxa3Nfb7/zLRE74x5BwNuc/WKCjZ7MOHQJwDuWUAqk3UQS0mvgMUlEGdUlJHl0SjgeZJ9LumLQ3szQFmd2PbnnSRyIBqbMOI4QAdW5LxLxMc4r+IaY9Mu0ux4j6JyZrRoC9OlqAEmLEwqpG3cfdZIIiha1R1xhl5ADH/nHx90+IF/dqbXG3JDC/EA= X-MS-TrafficTypeDiagnostic: DB6PR0801MB1991: X-Microsoft-Exchange-Diagnostics: 1; DB6PR0801MB1991; 20:/t3axrNmICSi/3Tj58JEqg7PzxStZvzuRDrcE5NBm0es/kLQ+S1dWFLVfYtmJOY4apTSI4kVChkGPP0gGN8OUB4rPmHMaqwB1MPuaCFZJGJHsUeP/57zQCy6xDyJWObL2bIo7tQEus+7k/4FxKbx/FKaQ47YVJ5HUOZcGqnmek34KGPtjjL61U6Qb2oDAiJgJRLTHcpbApRDBzJcJV80LuR3Mgc4pGcRZTj7+CWw/zwXsdv7/2W3qLOzXgS4DxDb5zSu5E6hYJNog81XpScz8g2K8vMPZWGXzkpytDMzaa06TEjO5MRoMDMKJ9nb5FsE0idULSEbN5hGMkhViMgqJC5oMnL4/8EGq3kuqgkcgUa608tc6iTp/AMJ5QgIydAKI2VjmOgrnAJ2vLyuhm4TRwzNHBYJh9JvaasusMWZfKc0axOC4GsRB0iEaK9baEomHsiHdkjwC1x9LSvrxiwfjXqCzpEJyn6OgHDoUbHn4JvtpvBFK2djmXqFjlxXllY2; 4:HapQb1NxFOM5QqPrwXFouNZe52yHmkIv2MKWwQXbPCNEuwVS1B9GQ1tyRfMpBlmGN84pJQkllbd3uEj1t+9v23xrSHWC2c8bORZsa1sSMQRmxcwUr0vq2Y1dxjhY3A3HEmVaG89SwFJkD9ehDmlzDJ+B708n+qcXEKMYViioyQGeT6aomFhqTSE8gB510m4nD2hZrL1XyqdtELncGWQBgTLzMJuQFuxqpdiiBSDC0GFWwpiDtiYDrziLfBb69HgkoDxZs4iluXreZ0xrZSlVUw== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040522)(2401047)(8121501046)(5005006)(3002001)(93006095)(93001095)(10201501046)(3231220)(944501244)(52105095)(6041310)(20161123564045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123562045)(20161123560045)(20161123558120)(6072148)(201708071742011); SRVR:DB6PR0801MB1991; BCL:0; PCL:0; RULEID:; SRVR:DB6PR0801MB1991; X-Forefront-PRVS: 06098A2863 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(39840400004)(366004)(346002)(39380400002)(376002)(396003)(199004)(189003)(47776003)(106356001)(4326008)(81166006)(16586007)(107886003)(8676002)(69596002)(6116002)(68736007)(3846002)(105586002)(50226002)(386003)(6506007)(81156014)(8936002)(55236004)(2906002)(36756003)(478600001)(2351001)(2361001)(25786009)(316002)(6486002)(53416004)(76176011)(97736004)(52116002)(51416003)(66066001)(48376002)(50466002)(6916009)(6666003)(6512007)(2950100002)(5660300001)(26005)(86362001)(53936002)(16526019)(7736002)(186003)(305945005); DIR:OUT; SFP:1102; SCL:1; SRVR:DB6PR0801MB1991; H:xantnef-ws.sw.ru; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: virtuozzo.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DB6PR0801MB1991; 23:xGXPrEzMhN/u8Cm3RgJOUl2qdvnzxxC/+dVwLs5?= =?us-ascii?Q?FppfAJiztX0ESlRFznTeLRwJcCI9CtOt8chiDqBKmt65BJVnSdZ8B2n0tQDH?= =?us-ascii?Q?5yWaaWBqhQ84Df6dupN8wvUzVl+HqAPjQYQx4tD7s5Bnx7clbiURq76niMOc?= =?us-ascii?Q?cXFnpfUK9lN8l7vagP39yotmu1031SaSKsZ8iRoZEdlusD8f2fVIdj6HSZlP?= =?us-ascii?Q?XZIEJBNNjWSupx0/St0AEz3/cUmU75ZCiV/zicM5OzBTKslLgd0oZQtzkpAY?= =?us-ascii?Q?/TZhuc+I3oKA/p9ORzZbruwjuvE6UORLflPsA22wzHpsBhV0do9ngkQfzjTB?= =?us-ascii?Q?S2d+HvSlOLTxUUZrMeLiBX7idzE4XWam9387sL08DwwcciJBW19TN9gWmHUp?= =?us-ascii?Q?JEyjs+R0FVNtXxG7c0gy6py8nxtuki3uN0USMC4d0PaJP4Lnzrsb++biGjn6?= =?us-ascii?Q?y3848vIDrrSsrOJm5HuUx5QQP2Iy6bIkFXdXbuPxjUBK/qNL9QgoS8F54Q59?= =?us-ascii?Q?lPj/fwCmsoMP3UBzqxO3tf+HwkGQJ3d7Y1LcMgug0rwXVZgKy7AhBr6gml19?= =?us-ascii?Q?YTZXEoJ5MqQBr36WAgvQBtVY3cF01YflEmbOludlEfFkoMEdXTQPt8QRWuzO?= =?us-ascii?Q?ZBB6mBSTmRDuN/DgbNn8OOoiaF0PDNHH1OYPepDC6EWC3OX1MT3nNwGFC9iI?= =?us-ascii?Q?WCDCynULLWQky70y0fDqiBfT9oUfGWagqdi05e6A/PIMACNtPuPTsDpg/sCK?= =?us-ascii?Q?9W8ZdO9C0qRYfnA7xvb7DZ7jVIabAAj1/P7wkKQYvnHlHzGh55VDr4i6YJbP?= =?us-ascii?Q?F5M/G93XftNVqhtsfmZMbzuDLrBJYNFN+c03YG1wSzPPn53J+70eog5MteR/?= =?us-ascii?Q?e+dbvviTspunH4ZChMnywTLp0k3q7o4TGByGhOk5bFQ89Qv4LZzotaGOI1db?= =?us-ascii?Q?y9dVRnawXm0J/7J1PKmYA7BT3KxV4hUuXnqYoaYh/P2uMR748MfP0GeMP/Wi?= =?us-ascii?Q?4HP3o+VDNH6QH+xSwGPp3QzvZU7GnhtyGiIVfHQJO2TDWGUTzvpl2snn264Y?= =?us-ascii?Q?lOFSpbBHO9isnbAKb4UZD6z0CttJ2lWWZJR4j9VpxRd9DdOFpjUScAzkz2pu?= =?us-ascii?Q?jCOEO1FAi/5TLSaz/FBhil10LDoE2UrFo0b8g6vM8KPjHMb1YufbhBdS9Uug?= =?us-ascii?Q?unPqVpR7LKIK16P+o6iBHlODE2mOTY+EDXAe0536BQmVIhOXdPGLW103mFw?= =?us-ascii?Q?=3D=3D?= X-Microsoft-Antispam-Message-Info: sgNB4MulLooQ21cO6sTi03SMPIBp4/ct6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gR4YfqnGYE8a/i4pAj6v+hbZ0v4ydXe/YJW9CdT9MM SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; DB6PR0801MB1991; 20:M6g8186342VN3f12PoCXQmbNq55E1CgZFzb/duxH0d9VKT+N7tbF2x3NjcJD6k34O0l7FqUz5sUDLDCS6fKNPhfTTUv2Ldary6T8As1dusNr/vUEp5z8Y7GCn9Grd4grz5YFPNaJ9YrCzq9cs5bJpA+jPI68cxjKx7ZY/ef+wM4= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Mar 2018 10:17:21.2245 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 7103e49f-e183-4e4a-896a-08d58802719a X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR0801MB1991 X-detected-operating-system: by eggs.gnu.org: Windows 7 or 8 [fuzzy] X-Received-From: 40.107.1.121 Subject: [Qemu-devel] [PATCH v8 2/9] blkverify: set supported write/zero flags 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, Anton Nefedov , berto@igalia.com, den@virtuozzo.com, qemu-block@nongnu.org, mreitz@redhat.com Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Anton Nefedov Reviewed-by: Alberto Garcia Reviewed-by: Max Reitz --- block/blkverify.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/block/blkverify.c b/block/blkverify.c index 331365b..de2fdc1 100644 --- a/block/blkverify.c +++ b/block/blkverify.c @@ -141,6 +141,15 @@ static int blkverify_open(BlockDriverState *bs, QDict *options, int flags, goto fail; } + bs->supported_write_flags = BDRV_REQ_FUA & + bs->file->bs->supported_write_flags & + s->test_file->bs->supported_write_flags; + + bs->supported_zero_flags = + (BDRV_REQ_FUA | BDRV_REQ_MAY_UNMAP) & + bs->file->bs->supported_zero_flags & + s->test_file->bs->supported_zero_flags; + ret = 0; fail: qemu_opts_del(opts);