From patchwork Mon Jul 31 16:21:53 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anton Nefedov X-Patchwork-Id: 9872431 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 A4EBE603B4 for ; Mon, 31 Jul 2017 16:26:47 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 936F128068 for ; Mon, 31 Jul 2017 16:26:47 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8848428111; Mon, 31 Jul 2017 16:26:47 +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 D823D28068 for ; Mon, 31 Jul 2017 16:26:46 +0000 (UTC) Received: from localhost ([::1]:60527 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dcDWn-0007Ih-MR for patchwork-qemu-devel@patchwork.kernel.org; Mon, 31 Jul 2017 12:26:45 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:39353) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dcDSj-0004nr-Bg for qemu-devel@nongnu.org; Mon, 31 Jul 2017 12:22:34 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dcDSg-0005Ng-Er for qemu-devel@nongnu.org; Mon, 31 Jul 2017 12:22:33 -0400 Received: from mail-eopbgr10104.outbound.protection.outlook.com ([40.107.1.104]:11934 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 1dcDSg-0005Kw-6N; Mon, 31 Jul 2017 12:22:30 -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=QPefchG+Iy99D+VxXYH0lD3GL9AaU+unTmxUj5FvBac=; b=B1GcQzMRSbgeM8OVWoAdpdTHLix5huJ9mI2cStj7K/Fv8dMXWBSApZ9xbZ8S3YR/QZqd9UQAN/j3BA+38r1ES1glPOAmJr5CPovnx7SttV+JkKKTCasnEPxMapr9+JAZ7WYoGK5X36betOdP8/bVlYxI5ZQpfrxMP9dYm/UEDJg= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=anton.nefedov@virtuozzo.com; Received: from xantnef-ws.sw.ru (195.214.232.6) by AM5PR0801MB1987.eurprd08.prod.outlook.com (2603:10a6:203:4b::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.1.1304.22; Mon, 31 Jul 2017 16:22:24 +0000 From: Anton Nefedov To: qemu-devel@nongnu.org Date: Mon, 31 Jul 2017 19:21:53 +0300 Message-Id: <1501518125-29851-2-git-send-email-anton.nefedov@virtuozzo.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1501518125-29851-1-git-send-email-anton.nefedov@virtuozzo.com> References: <1501518125-29851-1-git-send-email-anton.nefedov@virtuozzo.com> MIME-Version: 1.0 X-Originating-IP: [195.214.232.6] X-ClientProxiedBy: VI1PR08CA0217.eurprd08.prod.outlook.com (2603:10a6:802:15::26) To AM5PR0801MB1987.eurprd08.prod.outlook.com (2603:10a6:203:4b::14) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 5e5c138c-ca6a-4a0f-9278-08d4d8305467 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(2017030254152)(300000503095)(300135400095)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); SRVR:AM5PR0801MB1987; X-Microsoft-Exchange-Diagnostics: 1; AM5PR0801MB1987; 3:99I16V28BnxJnHb7ngfhoFWiCz5CH1R+79kCoO7FRzhoxO/aIMwpTlIqy1XxNu9X2g51wJI1AJCVbek0xKIdTvDKPVx7FoJ+YpKh094M6PR0EvtRLvsfey5WFlDHaeUwTHryf7p78Fhhpmsh74fMmNkthFqToq2UZWJiPUJCN745i3NvBUeQJ1IqFXtfhMzMV5FHQGBeOsw0+9zgZWt5BJM/Y979GjlAwRWAw2GE6/UMrJrDg1YUJwJJdFn8pOpNd8jZEpzHMzrkNGtFONhbPblBVHVGnKgxF4ul7bbO6Wxf08vmkTTbMOPiwRCThkuAKHCPvXrEGLosae5EwRB2nXWpG5L4d76vzWAiqNefz9uFUfTzEgNPf5glcycoOw5d8GvDFI3xSSbvCw50hEWOHj4drd8ktncG+PAVNO29VWYRualjyGlPEs+q9wxgz0zp/gXkvYnB9HqXTC+6D7ESrm3JH1B5+N5jFaRQ0fsGJuoYE5QrMj8hU0ImybbT3HrrX3uf+8Pg5yJTRNdzUzMmhCxVlnN7ZxKxwkpbIk/iLfMxCL7Vri0RfmXH5BQkn2bJhfiTlbIxg5eJ3+iE/2rpb3WgenHMdqT7YNoCEyZgdayhcYyMWCHnS5hZiU8+yW1fSuscIk1cs8kvlmBNACaU8ErIt6L8oR8X1HVLv7nBdUrzFYKqG4gERs02uVNziwJL78fgzC73A1GSxUJjhZr4gzrTedUzZWfmEesdBCOprsUGcIAVmkL5MIVxUbrppL/L25ilpYid7EUQ6ppZ89YySAI1gwk6idlJI1zHF4p5YpEH1ueC7yWam5e4dKasf8AC X-MS-TrafficTypeDiagnostic: AM5PR0801MB1987: X-Microsoft-Exchange-Diagnostics: 1; AM5PR0801MB1987; 25:cTcWYT9Q4GZsYAcx+42oOGjWCk/ETmPARR3JBox8geQ7kJsgH0LP+WC90BjKQag2LQRrBui0SgN4sAlxiwT7BVMyFC5hkak/71gn9iXZnZLUA9Auzh+aM2jvc9qnx2t489xHXH3up20EQzAdcjEkl6YgQUKC7aJy00co7VqW0PB59sN/BtTGNJvo+lwvgUQViwn6JmhbRugjZk1LwpPZnGxlbL5k6pliL3ufe9aAvHgW8xnFWxVA5CfFMoYJxtgUBad+AiS43VW6bbHWs1mM6rpeHNv9NbDMcUiHWZNpzlShbEcVoYRHvEvyULJyJGsCz1jk1K9M688rjkvahJqbkXFp4p26ZysBVAaGp4Gl6Fj5e4Y5r7zHBndYdMHgHncdbSVPfwXavHO80sIsxryb00ko08J43cupMm5uksfQXQ9GXfIbYFwlTASKszbVHGaCK8CWh8YVF2S8BymUmxlsTJfQnJZVeoQh9YhGiGNMWcJhHbkAuNF1Tu4UGosnbllfxQI/HrI7RwlnKIxPmH12ZIRPWOh/uKEPtmIkefvzS9tIk0xPe1MNlNuQ/+ZbsV/+cDaEgi/sWjmaSqL87MZpg55VI2PvrdxFzWBo5PXeAwTs/SsBHbx5P4tCbLYNeJEbGR9HU5wWMbNjsdj172zh4R4BlSNuADFHNhRpNZcsCw3l3o4D5aQ0cqda6L0zpMbwRsrmOApZrMd7bttDL/No4FmgoUQYInOaGOW17p1cGQVZtgnOK/k8WsiL4ynIj5AsN+j55ANwadMOoIIhtmC4wQEpCxZkya9tyjd0cqIRbjcT5aq+2vpZq2MeEqUW6yKdsZZy0Sn/tPif+3Yft+1eliWtMJ0SOi1RqwinBu1gYt6vA43Lj25x7AKwGPmwDXn27AXOBUnm5+SsLs6bLDgTvUHRR8BDgYAlyft5TJvutx4= X-Microsoft-Exchange-Diagnostics: 1; AM5PR0801MB1987; 31:sgk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dDGknXlQQ2ejao3EDyxZBayU/S+62rafhlBlDyBu+WBeiC4HbKoaTR3XVnqRUN+vWJTnDOWo4tskc= X-Exchange-Antispam-Report-Test: UriScan:; X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(8121501046)(5005006)(3002001)(10201501046)(100000703101)(100105400095)(93006095)(93001095)(6041248)(20161123558100)(20161123564025)(20161123560025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123562025)(20161123555025)(6072148)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:AM5PR0801MB1987; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:AM5PR0801MB1987; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; AM5PR0801MB1987; 4:ks6saOUv371eVDIJxxseqz8Gtj7WEdpt5oKd9Y6q?= =?us-ascii?Q?50tgjwluUGHVHpYwbdnQjN2HabZ5FvdjnwzM0eruUcj9UtSmkn+saVFkCp05?= =?us-ascii?Q?zSvB5scuQyQIuuyzrzauSK1ikbZewwTKQZy6/4QqN21F2SR/fJf2zumO3rB9?= =?us-ascii?Q?8FaxjIhXhWbDJgwyQpUuVGGVJo22dPbZVoN0ZKyop0bVv7wINOEEdvABuF7D?= =?us-ascii?Q?cNwkho+7gpdD2KRNOajJrngFZjG9prWNnTJ7RH+rygesz/EPyiroOy7aGHO4?= =?us-ascii?Q?ry1Zr16Fq0BnFT0OB+lZfJzRlrtNrHmhnQLOfu1jXgrsZ3XlbnBIRkaYeOU1?= =?us-ascii?Q?QeBTqLgUIQV2l7wLyDGtV0zeuXi7HgwZ4T7cV6MffY9I0wbQcmzSx6eE3lWp?= =?us-ascii?Q?qRSDGpc+TMQWztfMFuOHDz9LNJ0KuWd/mRKSnHL4ZcnM16/omnwL6w+w6Bu2?= =?us-ascii?Q?jAFw0XP7/mn1uAM4PXe8qBymN08bDJQlXsVQ2pgO+nKaX3HB/P03PJGep20g?= =?us-ascii?Q?ySumsShsb9nRjNDu6EYX5RZdG0T+ZQJZVi0FN4AM+HzyS9q0L4219idG1Qlm?= =?us-ascii?Q?HwfW3T5Mk2JrWreB/rUijUjVGdm24zwiwYrE9jGN39fRR9/ZuPMMfoGrpn2Y?= =?us-ascii?Q?umehBJmYoreGbsQIOvsSz2szopqSc62sYGw36mcMr5NvvvYYzeukh/W1m2dX?= =?us-ascii?Q?bBjYpyUrm+4xWx6krkJJimJAWc9krTe+gm+VHfuUkkWrrhDbnGUV3ob5vMs+?= =?us-ascii?Q?FRofwZtizLXoeQjMCh8f/ySmsle1NbPoEd+76FQjipgUK2blit6IcpYD+JKy?= =?us-ascii?Q?3Tx1JoMPVFCwMN7G8pS0U3Rt1HvxCefkVwMSRUkPv8QfvqY71O+FPMqy2Qn7?= =?us-ascii?Q?D1I/FASquyztsuPu9vxIomac8Q1Cdyab0OKhONrhlGV6jQ4rxtIi781d8T1g?= =?us-ascii?Q?Xk6j2RmlVmY31J7nb3UU/bIeR2B2SnvipnKKzr201D26J5QpoEXpycipyIXR?= =?us-ascii?Q?X9CNC+baEtTEyrxI422geRwvVbD1RSG/yulSSVgLfz4uW5Gc0oGrNxu+uPLG?= =?us-ascii?Q?gU3kyFNoUd8lATHsPWh8ZsCrc2HWcHNahvAwez/qUnI+dWTVnArX193PZ9Ro?= =?us-ascii?Q?5waiRh+hsMthHsXHlcBuzEkk5ictRmps?= X-Forefront-PRVS: 03853D523D X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(7370300001)(4630300001)(6009001)(39400400002)(39410400002)(39840400002)(39450400003)(199003)(189002)(5003940100001)(66066001)(47776003)(81166006)(53936002)(48376002)(101416001)(81156014)(50466002)(6506006)(36756003)(8676002)(305945005)(2950100002)(69596002)(189998001)(6486002)(4326008)(7350300001)(6666003)(2906002)(97736004)(50226002)(107886003)(110136004)(38730400002)(105586002)(25786009)(106356001)(53416004)(478600001)(6916009)(68736007)(2351001)(42186005)(2361001)(86362001)(7736002)(33646002)(76176999)(50986999)(3846002)(6116002)(5660300001)(6512007); DIR:OUT; SFP:1102; SCL:1; SRVR:AM5PR0801MB1987; 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; AM5PR0801MB1987; 23:YRPi1MDWzS79HP7U7J/eOSPU+4wGZCckfsGMIZa?= =?us-ascii?Q?m/T6+n8BUvjr312+pGYgA2OJIJcAdOmfTY/q/KRzhvys2gKgbe/G8feMcOo8?= =?us-ascii?Q?YmerUQUX1/FVj5M8alUPkiH8XfdN2P0WWeqMQXijS6Vtk5l4Q1SSYQ7+Xe+m?= =?us-ascii?Q?AqzXhJMgn5nOMqtSGHnjkVvQk8hlrVIAftv6MlDLgN5lE660GNMdnBLX076f?= =?us-ascii?Q?l+ETdjkK3Oa42yOSLeNz3/uqaW0FKNyQtG9T0+VzzdACrfmCsN+B0K71+Qs/?= =?us-ascii?Q?SCnpJONRHKZw119JxQOatMVwNGD/uJiBM6uppibE/Lfz4WXxJt+0WvRNBef6?= =?us-ascii?Q?lytXMehOtl+SRb2GnXa5N22Lf2g8BQOy7poDfM+CtU3twJtuYQACsy8XRHh3?= =?us-ascii?Q?70hVORI3ZZcRgHeFONYTJR9AQrB6ZoEbJW3PqqwVUkI0RJeRnyIPK7ElTAFz?= =?us-ascii?Q?/e26EjPtOBlOiwKGAaFkQz0/vbvooOBwsPdqkLsMCt02VY8TO/CF+zWKr4Rw?= =?us-ascii?Q?DNch8hkJgO2AIzXdaq1fVkM8xQFYVyQo0r5LrFciEIw6O5/iz6SmfrOtfo13?= =?us-ascii?Q?wmp2UcxWfkyI5MZlF6aFMSsgBSLITEp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wExOIR7TpFEf?= =?us-ascii?Q?IbU=3D?= X-Microsoft-Exchange-Diagnostics: 1; AM5PR0801MB1987; 5:l+XgugjSH5YDZSi8WzehhxJpURSVmQLo1uEin//MYUMUHaV+auJwyp0ei8RjwzpK8VNToWo8m/CaFjBTYCO/3wCaFew9TSBEHycrBYr0lr5xhyPuQcuGTAYNCAk52vmb3lDch2XMrmCfZUMEEEHFpiJcCiWoBVErzALUuLl2cU2Zw7owuo0CS6Gndqetpe+bafWtuj6DGIVM8eJK8Soa+C8F5Ym85VQCM3QSfdhErD+HPm3K73DZDY8RO/Q0xTX02wnAUIvMdnwrEOQZhumcWT3nMljUeFiqZdP7CSsc1FahgY7mxKYgta9/LRiikMJhfAK4c/5gEn+N+E/zy+bM6Y7E/jDkfRjymWm0texisu8KrVLo5RDg6Nx7YDtotJv1LiS6xbSBhP+VFpWz3hofZYPpZ98BessuB53nPeFkwdhpGAOcKom0Nkp0MBhIankMGeNCHPgNpeNnntVURoK/n41xzak7svljpmioF7m3CQs1tb1pVzXxy5rfczP1SODM; 24:q6WhLOBVdECuq2jX8F9F2+ZSMNKx5S71AX9KkxGUfm8w3uuVO8R0aRG9AGQT31eRwaan7rngjddBwXuWquABLet3a09Wgu7+SLIxfjXG70I= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; AM5PR0801MB1987; 7:Nd0xWp5SSRUNdslxbbPDHaUA7jOUPWXPVmuiEG2elLSQM106vxVOreHlvVLaBCaWgGXyke7ml1b/TQhJ+Z7oQLxkI0UaOV6f816rSbA1cfjZEQea5V0WPC2ytLdKa88uzvdnWb9oevWNdgEpAZq9zA1vAsuSvvQFfDMvTfu5yL+Bsmtfmw1kC2iHiz7YzpsbRftbrnViHMx24FDT7yYk9E1K76n32MffNXfkqK6jlkAa8Y2MSo9EcAxeGmWRm+kdQ2dnuiIrQ7+HFYFQwD426ioIySdlkudspaDS2boEgRZ57GhpduQ2K2zar54v0IMvbQhRZS1Ayp2C1yZPRFE5zQdsyefMoz+HJUOdMeewUqfm9bnjgz6vQ69gHWeLWZXiOiOXsNgC3Q+HYTXBqmdh23LSr+cIGSDZ/MvWNZ7oYhbd00onJ9E70uY5Oe49dw6e+9tTDZystE+hePqNGdgYZTZ5jbt+6tuFTAMnkn8/cINALd5FgQ/ZSsuma50hXbSIPd7q8Xs4Pa3NtqxdpIojf6H1n2v/20ksCYY1hqJJERWdT0G+m96eMcj7WlGu4kHFixgGNQLip8R83iQaXqAiEAXSjQJdTCkH4ZZi/u3sdIpVJAOaEoJOu6EAlf2Rh0ZpXfWjnfwZCGOwfkjuDrdm+iFZ2VfMslcWxVpo4BAApw60z3qy477G2YYAMGS7Myklc5xCWhP1r4PiJNxPPkuvFNsu+VRLYQRKAUZUXfLLxRg9xF5aPYIxbQ9N0S1YGm0aUR+aScGTzDzsKyYmKdRvEKmMxmhRzjtBw18AHS2OfKI= X-Microsoft-Exchange-Diagnostics: 1; AM5PR0801MB1987; 20:HNlyDZj9up9Vkek4oPCH94b9WB+2AtJMWgGJA8SuCU2BcIo+ve/WmthfU1G0QUPq2UXFqACUfRniMv5neE1lxHNVFmR2wCUh+JMdSLBhK3pQHVA+2FUQW8hdtCVtkjw74mdKPs5yIO3gfFYPOYqzh04wbrPOrBzS4ApCBJVJ8rI= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 31 Jul 2017 16:22:24.4686 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM5PR0801MB1987 X-detected-operating-system: by eggs.gnu.org: Windows 7 or 8 [fuzzy] X-Received-From: 40.107.1.104 Subject: [Qemu-devel] [PATCH v3 01/13] block: introduce BDRV_REQ_ALLOCATE flag 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 , 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 The flag is supposed to indicate that the region of the disk image has to be sufficiently allocated so it reads as zeroes. The call with the flag set has to return -ENOTSUP if allocation cannot be done efficiently (i.e. without falling back to writing actual buffers) Signed-off-by: Anton Nefedov --- include/block/block.h | 6 +++++- include/block/block_int.h | 2 +- block/io.c | 20 +++++++++++++++++--- block/trace-events | 1 + 4 files changed, 24 insertions(+), 5 deletions(-) diff --git a/include/block/block.h b/include/block/block.h index 34770bb..dbce3c9 100644 --- a/include/block/block.h +++ b/include/block/block.h @@ -65,9 +65,13 @@ typedef enum { BDRV_REQ_NO_SERIALISING = 0x8, BDRV_REQ_FUA = 0x10, BDRV_REQ_WRITE_COMPRESSED = 0x20, + /* The BDRV_REQ_ALLOCATE flag is used to indicate that the driver has to + * efficiently allocate the space so it reads as zeroes, or return an error. + */ + BDRV_REQ_ALLOCATE = 0x40, /* Mask of valid flags */ - BDRV_REQ_MASK = 0x3f, + BDRV_REQ_MASK = 0x7f, } BdrvRequestFlags; typedef struct BlockSizes { diff --git a/include/block/block_int.h b/include/block/block_int.h index d4f4ea7..1883143 100644 --- a/include/block/block_int.h +++ b/include/block/block_int.h @@ -578,7 +578,7 @@ struct BlockDriverState { /* Flags honored during pwrite (so far: BDRV_REQ_FUA) */ unsigned int supported_write_flags; /* Flags honored during pwrite_zeroes (so far: BDRV_REQ_FUA, - * BDRV_REQ_MAY_UNMAP) */ + * BDRV_REQ_MAY_UNMAP, BDRV_REQ_ALLOCATE) */ unsigned int supported_zero_flags; /* the following member gives a name to every node on the bs graph. */ diff --git a/block/io.c b/block/io.c index d9dc822..b3f9d61 100644 --- a/block/io.c +++ b/block/io.c @@ -1275,7 +1275,7 @@ static int coroutine_fn bdrv_co_do_pwrite_zeroes(BlockDriverState *bs, assert(!bs->supported_zero_flags); } - if (ret == -ENOTSUP) { + if (ret == -ENOTSUP && !(flags & BDRV_REQ_ALLOCATE)) { /* Fall back to bounce buffer if write zeroes is unsupported */ BdrvRequestFlags write_flags = flags & ~BDRV_REQ_ZERO_WRITE; @@ -1362,8 +1362,8 @@ static int coroutine_fn bdrv_aligned_pwritev(BdrvChild *child, ret = notifier_with_return_list_notify(&bs->before_write_notifiers, req); if (!ret && bs->detect_zeroes != BLOCKDEV_DETECT_ZEROES_OPTIONS_OFF && - !(flags & BDRV_REQ_ZERO_WRITE) && drv->bdrv_co_pwrite_zeroes && - qemu_iovec_is_zero(qiov)) { + !(flags & BDRV_REQ_ZERO_WRITE) && !(flags & BDRV_REQ_ALLOCATE) && + drv->bdrv_co_pwrite_zeroes && qemu_iovec_is_zero(qiov)) { flags |= BDRV_REQ_ZERO_WRITE; if (bs->detect_zeroes == BLOCKDEV_DETECT_ZEROES_OPTIONS_UNMAP) { flags |= BDRV_REQ_MAY_UNMAP; @@ -1441,6 +1441,9 @@ static int coroutine_fn bdrv_co_do_zero_pwritev(BdrvChild *child, assert(flags & BDRV_REQ_ZERO_WRITE); if (head_padding_bytes || tail_padding_bytes) { + if (flags & BDRV_REQ_ALLOCATE) { + return -ENOTSUP; + } buf = qemu_blockalign(bs, align); iov = (struct iovec) { .iov_base = buf, @@ -1539,6 +1542,9 @@ int coroutine_fn bdrv_co_pwritev(BdrvChild *child, return ret; } + /* allocation request with qiov provided doesn't make much sense */ + assert(!(qiov && flags & BDRV_REQ_ALLOCATE)); + bdrv_inc_in_flight(bs); /* * Align write if necessary by performing a read-modify-write cycle. @@ -1670,6 +1676,14 @@ int coroutine_fn bdrv_co_pwrite_zeroes(BdrvChild *child, int64_t offset, { trace_bdrv_co_pwrite_zeroes(child->bs, offset, bytes, flags); + assert(!(flags & BDRV_REQ_MAY_UNMAP && flags & BDRV_REQ_ALLOCATE)); + + if (flags & BDRV_REQ_ALLOCATE && + !(child->bs->supported_zero_flags & BDRV_REQ_ALLOCATE)) + { + return -ENOTSUP; + } + if (!(child->bs->open_flags & BDRV_O_UNMAP)) { flags &= ~BDRV_REQ_MAY_UNMAP; } diff --git a/block/trace-events b/block/trace-events index 8d10a82..b9746a7 100644 --- a/block/trace-events +++ b/block/trace-events @@ -12,6 +12,7 @@ blk_co_pwritev(void *blk, void *bs, int64_t offset, unsigned int bytes, int flag bdrv_co_readv(void *bs, int64_t sector_num, int nb_sector) "bs %p sector_num %"PRId64" nb_sectors %d" bdrv_co_writev(void *bs, int64_t sector_num, int nb_sector) "bs %p sector_num %"PRId64" nb_sectors %d" bdrv_co_pwrite_zeroes(void *bs, int64_t offset, int count, int flags) "bs %p offset %"PRId64" count %d flags %#x" +bdrv_co_allocate(void *bs, int64_t offset, int count) "bs %p offset %"PRId64" count %d" bdrv_co_do_copy_on_readv(void *bs, int64_t offset, unsigned int bytes, int64_t cluster_offset, unsigned int cluster_bytes) "bs %p offset %"PRId64" bytes %u cluster_offset %"PRId64" cluster_bytes %u" # block/stream.c