From patchwork Thu Dec 23 16:01:26 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698467 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CAF18C433EF for ; Thu, 23 Dec 2021 16:04:09 +0000 (UTC) Received: from localhost ([::1]:47902 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0QZc-0007y5-Bv for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:04:08 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43008) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXd-00050I-7y; Thu, 23 Dec 2021 11:02:05 -0500 Received: from mail-eopbgr70094.outbound.protection.outlook.com ([40.107.7.94]:61158 helo=EUR04-HE1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXb-0005KZ-7N; Thu, 23 Dec 2021 11:02:04 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kMwBdgZ2OUXfKwh4i0iDTyLtZqzC2oOJ9tUk7LqEMS5S+1fqw3RqtBI0kDBRh7QhL40xTMekgnBSZnEgA3sVxSDRlEmX4BDsF/B7v7qqKdOo0dNcbXpmVSP3arWxhciyJDExovvnX5eOg+Sni90dDL+efhrEdIpd+UJSrLsF3+Ur2g5EtrwKXBU3qC9sB1mSHlSwWqZ/7FE8Qwv7+0mrRB4hng4VM3hXCtsOQo3/X7HatYI7aGfGuffR/MsAd9hTYLwMu/zouqlghG1MrMBaHm0hECo1rLFUZC5YTpQhrrktmtupUydEa9tVI+0E+3IgUsPu1ngtxYFGE3QXjii3jA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=04/nOXA0pTZ9jUmwK4jLfeALXKT0Ap5/s2cSQZArKkE=; b=i3OVoV8Z7YqN3UTTJjZ3tTGHc6E7j283vgZKxPXUbBtyLAkn2BuUjHwpDA2by1PpKfGFan+DuXu7+roaBpaYgO2vzyppxk8rsqoUyk9agwmJOzs0JpGPG90yMQPKPYkb6rp+V13A6n685taJG/BDURgwaipF0ShRG2nRkeRwcpyxmmWET2hxT0MpjNqulm0LyFmDxIaPYw8o+p6WjJaAYLF+knPcgT1KD434cQLRO2WoDI9YO8HUtro0XlDaXRB2XWmyxIn3295aTdBGWEkcQ5xlG31GynVw5qePZh8ikwZoNpHQDyFbqYE8LM9tuWzYbIPOBdO+4DjMxVWiU6qhDw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=04/nOXA0pTZ9jUmwK4jLfeALXKT0Ap5/s2cSQZArKkE=; b=Fnr5PLFAvJXkWi0FgDBGki/DaM+cwMTizUKpaTPIe1EUV4HvDJQMGzxVMEwhD/HgsWT0DFs1TZYc3/1wepV9vHBn1YTltNqeFAjyWEQ48BLP1wvZNFTIpwnuDnDxEC5uXkeT9zrCNdqlXbPTqeswzLQlUmlD7ycYX2yERun5nNE= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:54 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:54 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com, Max Reitz Subject: [PATCH v5 01/19] iotests.py: img_info_log(): rename imgopts argument Date: Thu, 23 Dec 2021 17:01:26 +0100 Message-Id: <20211223160144.1097696-2-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: fc110c4b-9ca3-40fd-5afc-08d9c62d8a49 X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:400; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: hLKUdPcvMDB8E1aNou7jiwTLmAizbI0IQcflZzHtUMxeAL73P6uNbgdwXzlnIQERsXFXdvOHaPPAi/3LbHp1ax4dpCj59jjpFzFfN4TuId94uy/X453u4eVFeIvjPv60wzk/lwEDgLABWE96q/X7MF7XsH0L724FZVZk/tckTsfi3SEabqkuWOpt8VOzO8rEgw5/aUD2e48VB/Y1VYv/fT5XO5rZgq+OO6wPK0T7TJrXCzpUxJgbmP09ax99QPHcOgLnhdQF7S9zAswyFTPdksG6/8QWGvDfOPCyV1joMcdyvzlSnudGlj1hynibDxO3NKL2kR6zLscJCRt7cbHXORnMLZqHI+ZgS88g0e0clVWVLUMlKpvN6Q4TEMSqilLPb0WqdE8JvBqITfiekeTki1MB9UYVlvtFdSGo5tWZgMGWv6b3BA4gfA8/2nhbb19ay++nOQF1jZ+G8IL9ORjGEA2rN58CduFz0jvFECJQWn57YWPQt7TGKXjbNOwfOTqGIjENUj8rE99UFEW170xZycTwpOn6BpC5UvwXADv5qpi6Fj8ZlkrDJqBagmQpEJ/Q2F/Xxbw9/ho4Rb3tUSKpn65jgx/G1F+yKh/1GbWiirDwvLKfoFSqJrHX9N5dUT5B2+vpa7IOAeWiOeKGUfJaFjoFJB00hktLWJ0fRsFod4UcUCY/NNVao91bOh8i2ZQDEDftBNpq0Tk6Rv8bK+8qZw== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: eEQn68D6he9IeiSxfBeLpFhKdpndcf9HHsXId3Z50RWq1J685d3wa8lJBTa7XeoM4tWGSWoGdaYOEFmGpzOuFL94hIVhjKFRZJWYVlO0+CaBRV76WZ+zSt3Z0XDz62yufw2NOje6kxmuaJXaAY4b7HMH0PbjCBRGKp+cq1tXV68hNf63wUOV3GEhDehnsvU4T6Lyz/6kDzAlwppBHU4fbGTk3T37KvF3lcy/vVT4IjDlP68QQcn0JpC0iZ0PxJtky5OXT0H69yjzCZ9YFDUVirFr8rUYwjdCElhX57EXOjyLXctQ1emlJrhqdYJaU6wF4pRqpuR5hvHexFudKku74JOPlbagR/B8aYFoNYQGjzCnCzj1kJFuw7ZDoIPMLTVfbqFI2rTa3OWKo5867DxUZY5ADL9jBcoQTMRzHV69xQ5ha+3V/Z2sIoa4Siari/W9ii8dLRLW8tB2uvQLUBX1CVAA4fIkDnCfLLk+tXtoZlPbsQf1H2eMh/6C3vcKF8i19RJN1eF0VIzr7WoQE6fJr5T6N7+sIkPodI142ErHYCNu99olJ00UCe2lLO0GtWmk/esoK1TxSNMFY+M9Zz54t13POwgiAd8URCWllMTJ0hMn8F/pw6YumO+SQMj7TQuOrudqCRrZRMxVqgMtKnJmPJbHZnNscpOBbrxCaA6dduLjvM/c3AsDdKQABzeENKUGHfeVCDEbKMiVL/g0TkS5oP+07MxSiL4iKSnimMBPTqyCfMyJR6Sp1syhIsj6S1RlxkxMRrBz3MZIy3j7xveszJfsXAWO3gQa3Y0Cxan7+W8+5DqWHb7TFDKzB0MqFZeJhNlosGX/mlFMqe+ij8pMoI+bna520zJWW/51qXKoo46g0lHtyyjUzfwgq1KoZ5ONJVns+HOHxfr+7+8U8/cDByWIHEwsIOEVcLSqDXn8G4Q/dgeVQ1u04EA+VApU7+XU5fL++6s6NApqgAxkM6ouB5ZSmzH7lmPh5Mhn3XuSBuW7oQXiAwRBXgvFm4QgYwE44fshajg1qkCKiKBt1bIc6T/8BAsgoY35YgMhC9nzkqYL7VHQ/yTkiRLSdBjz02vR1NsyI8cjyu9ePT7oNypnuLF7CHqYe+dnse/KaBZUGH7eDYgA+vwYnnsfxXoWZB53jeQoVQMAftCtHj9C96+PE2N3ux1yJdloEBIlmbQW48LMcVdFey8E6p/xslKWErUpZ488ezp+waBtVZPczwm1QBGF4on68BOziCo9n8AudAsISZh2BzLiOJljeMNBt7zs9/oOqx/4lZYSdrZYjldPCsbBPkMwGvIR3OuZ09hHOnH+9Us1+XAsi+U4QVs6dYK///7HTM2vH07kwvYm2Xxj1NKqXnbGbj6N2TXRJdBn6Kyg8YLxhDvS5KRvR7iq8IIuatLTStD74AD+/L1R688RYYaLvJALDJ1/rnRm89vV4xDVFXY7c01tRRUhkPllbWVg7mQFPgKeX0xO/hzL5siVsMcH/ABs7sLsyMbO+gS9NgYvQWefkfIDLH4BBKzBRjFcnAAeqWehiUd2eX2Hs/dORgwZ5HIlCNsvTQa+XwK/WxwGTZL13cI1FELJwUt7YpxUAzTbtmpOZT+wnCwPvdLRLcauEzQKVr8YKANMcuK7/1/WGpldRb1jriil7AHtpjwNrx73unf/Wlr475WoDFCaA/CjiyXxGPK+y/YKIhj4514= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: fc110c4b-9ca3-40fd-5afc-08d9c62d8a49 X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:54.7245 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: rNQGPRjGrTsM7m+eB1mhcBwCWhy4XPAPPDV1qppXHNnDO7ZRRZ6AeI7qZSFHcbvIA5u3M5LM1P1C10jDdLPdVnXlkVbIX4v27aMY60M0+nE= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.7.94; envelope-from=vsementsov@virtuozzo.com; helo=EUR04-HE1-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" We are going to support IMGOPTS environment variable like in bash tests. Corresponding global variable in iotests.py should be called imgopts. So to not interfere with function argument, rename it in advance. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz --- tests/qemu-iotests/210 | 8 ++++---- tests/qemu-iotests/iotests.py | 5 +++-- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/tests/qemu-iotests/210 b/tests/qemu-iotests/210 index a4dcc5fe59..10b0a0b87c 100755 --- a/tests/qemu-iotests/210 +++ b/tests/qemu-iotests/210 @@ -62,7 +62,7 @@ with iotests.FilePath('t.luks') as disk_path, \ 'driver=luks,file.driver=file,file.filename=%s,key-secret=keysec0' % (disk_path), filter_path=disk_path, extra_args=['--object', 'secret,id=keysec0,data=foo'], - imgopts=True) + use_image_opts=True) # # Successful image creation (with non-default options) @@ -96,7 +96,7 @@ with iotests.FilePath('t.luks') as disk_path, \ 'driver=luks,file.driver=file,file.filename=%s,key-secret=keysec0' % (disk_path), filter_path=disk_path, extra_args=['--object', 'secret,id=keysec0,data=foo'], - imgopts=True) + use_image_opts=True) # # Invalid BlockdevRef @@ -132,7 +132,7 @@ with iotests.FilePath('t.luks') as disk_path, \ 'driver=luks,file.driver=file,file.filename=%s,key-secret=keysec0' % (disk_path), filter_path=disk_path, extra_args=['--object', 'secret,id=keysec0,data=foo'], - imgopts=True) + use_image_opts=True) # # Invalid sizes @@ -176,4 +176,4 @@ with iotests.FilePath('t.luks') as disk_path, \ 'driver=luks,file.driver=file,file.filename=%s,key-secret=keysec0' % (disk_path), filter_path=disk_path, extra_args=['--object', 'secret,id=keysec0,data=foo'], - imgopts=True) + use_image_opts=True) diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py index 83bfedb902..9b374dad3d 100644 --- a/tests/qemu-iotests/iotests.py +++ b/tests/qemu-iotests/iotests.py @@ -219,9 +219,10 @@ def qemu_img_log(*args): log(result, filters=[filter_testfiles]) return result -def img_info_log(filename, filter_path=None, imgopts=False, extra_args=()): +def img_info_log(filename, filter_path=None, use_image_opts=False, + extra_args=()): args = ['info'] - if imgopts: + if use_image_opts: args.append('--image-opts') else: args += ['-f', imgfmt] From patchwork Thu Dec 23 16:01:27 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698469 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 07008C433EF for ; Thu, 23 Dec 2021 16:04:52 +0000 (UTC) Received: from localhost ([::1]:49222 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0QaJ-0000QQ-6a for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:04:51 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43052) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXf-00050h-37; Thu, 23 Dec 2021 11:02:07 -0500 Received: from mail-eopbgr150124.outbound.protection.outlook.com ([40.107.15.124]:2176 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXd-0005Js-AB; Thu, 23 Dec 2021 11:02:06 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=FncI+TVvHhfHKUmtg0bOE8IKqWMVHRx0jocxuH8/PoUz/lLKk1NOjhvlOLsoBjz/wg0eletcTSidIJdzcsE1jAj9SPwgGsMr4Ex4eWAVUO2/VefDD5qsX/KNZctMgZDQG5mXcfOH9j/EW+xJZLuK08k27AqAda6xsmHYDoRHO+ubzElMGZcBn8mZtQdxTMsBSYak+4rmWh1UelvU3bzgM+WmeRh7iICkCFuOTdiasnmR+fVSEIUVPWAZI0WgxUjG+DF0ipl6Wq5QWLe9IfA08c2cGBwmobtWYIoZ2RnKkGX7O87RrrKOij1kY/wZLVV7I2fkz3aXF+SZAuhp9I35sA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ugNx8pTaVX6K2FBKmoeNPtVML04sAuUp1rkZwwvlW9k=; b=iLJbnBpOb2hcoaEL/alF6zmdJ+ghrF9LRSSmti37aZl7d0d+ErslIxLrW1VLmI6f9tYu+EIm+WG+sVJG4fg2Lf+91CEcfVUq6wcG1DxBuKfIsTixxyH2FPLov5r+InFlXpEu6OQwgZEHvsEj5anlzTYfL7GkAla0ZON+M+fBw81ESKGSeV9jSaLRZVsHxaBc/oIIl3eEuHFLwXWy3rGkw0pqsFLUFnmJYgYzLqnJS1rgBdLdxvjLuSpKJeIiLSOKF3lyYTbYUXSjJLOTVtwTsyNPwRzXSvD3UEvscS1iZQkVRnTvuHghm+FqJKIU5dtOMliValET5YSbVl4o+03vqA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ugNx8pTaVX6K2FBKmoeNPtVML04sAuUp1rkZwwvlW9k=; b=FOYVQEJaKOBqzqC6Ki3ld8NOACJrK8jwPT2YmWYFZ6swxgPtBYk8onJdHetG3YppwRr1y5xohN/5XwL0PZ98Z+hypWT/akdQpMwBd66F4ULkFzbD0f9R6zCVTCqCSDfXhAIBkVZ701kuJCeKo3p9+Ahrt7/zZjuEynjjKxfF6No= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:55 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:55 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com Subject: [PATCH v5 02/19] iotests.py: implement unsupported_imgopts Date: Thu, 23 Dec 2021 17:01:27 +0100 Message-Id: <20211223160144.1097696-3-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: f4e7d21e-ceb7-49c6-6720-08d9c62d8a9a X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:6790; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: THMcqs8kULanLxcBWR6jyo+xj/HZhcXE4bO0MMxKyiIYOT1dKJCMP6e/tayhlJ1ASAQ2N6O/g3qTYSjyzmv51gtixAEKnpDO007+2ujRw8SiGJDag7LoHhctCVLoGWU/jjEDQBoQxzpSqx0QbIQgAcsLH0szkjVIKUtrqoyPFGiHFWBfEaCRHgujZPwvI3SmuJvYrjn2eg4/TIK9nElIazIisWMYlg8yvBebHKzL/8P4g13sN0UJuK28Vo4h/t9naqNIAgoQxsiaytUsgb7OYcfi4UgY+lLBuyL/VpNzzdpxwoqPlFqR8rJJ/lt9yTOOGU0ls35cClgRh2j0QDQuh0q9AlQh2puugDgkBGkxA20bCnPSXV4igDXf27mO/SsBDa5bsyuhqAPxJzECoe1dJwH2DykUPbBhTJoxlNP0RWiMoTXFvLx0nbFbixMGTktXId7/pXUq5ns8gMhHjwwZEKsQv7dzshpV9YIVADKcc9OpVBo0xK817pv27mFWh4gw/mxC1myycsLCqOGdaps0A+FYsdJVG6Vr9WRzjKNMLMTZjz49jfgBM3MyZbHB1dX3XyPT0+WYHqsZDcVE7GXz95EC2i4yZ3Bjy7BHQRdPu3rAkVR2bEyLY8TP6P+hKHnj+PRlohkjZVaH3IYmaO1EHwbbz84Bh090Tw6Dk7h4ecxOxM/qDc+2zHeEhyeCRhFVn5uiIgDyH+ri/0pFM1GjXw== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: TKaLx3xa6hu9sB3kWpO4nKfnOZKUB5Ce5EBCoSzxvZyCYFvnqWc9kFABozkzPx+Q8jgmNnZtoLd6B4BwX5kDnXdHyxsTHVTio/LjDMJ/SQ4NE13bzBqxFyGKk0m69WloSNiDNsVLRZF1/ak/StuRUBq/Y33B4kXPwvrxALd/wXAfQDonDticP8EwiUk6C0bNdtq3sPNIUZsPP0fPSfg1Gp6kt/Z7FB/2j4k8crxYszQpFf0UidyAKBJH/hPNmRC/oJduxHfLoU2Oc0YMn73R7GjEpAQz0aAaGUuY8nxtHsO/AJo3v03U4SngIKsRek5Rcdc/gfGZJcA/o70ezSH+t7lJfbOS+Nz+CM4H2Z1otKD+STw6+8hvin/3pk73ISvjzKtZ1RzaylIqE9n0EiBJ7ZLUXYJRj4Txm0UqF13GEYSs3KexK7zAmHwasR8mRniuIcCi2189NIKHh0m7J2NxVk2JrC6F1ZiZs/hmSQhS6/JUJ9EpeaYbyu4nTO51xlHEEwAbTNpS2D8IXBqGM3j53a+LaDepllQ/nvs5rBQxWshuN8jRob7VwiMe/4FB6dB8Af8gX4g26/Sv9Y/m0GfHJ3HZS3zFK93ohWDwYF8fFZCxeF80YEQdzWOkw+q3Pa5rwMQFHUjO3y9bsmrqjjGgqaKEHclldaVorED6HOoSymuujA02tHguTWEVWVElIIbmYBiPV6a84VAmhRzbftcFv6cjaWhKnaZXjWi/7UHpvQnVOl9bXb1Ay5BX8GjJuZ9UOt0jLsj0ICdl+sklXtt0Wk2KqzYu+H7MrwvHxiDjdVEgfa9GEJu9ldtr9q1T/wRxzb1vaHQ1plZY/tUrBy8EBwUq/1kuBAUhIuhKSbz3RhlD8h/6Q1O1PCFnN9kNdLNfTOPvZ/BOtUHPQtjmZZGjG8Km/R00vlrWLWzzqrXDUdoRqDiAnW4YMVy0Xukabgs7ypDKSrPH8PUWNGaTMRU3RUKwuwPZfmJJhn2xDYeGBeW5jqc+m6CekI6fUxe2vN0+wvgGMsfkcK0YxD3NcOMVtUwPTxSey/V84j5nz+1Age89Or/W4g8I3FhWVXXpWXgQng5hxBWeq8W+K3sgVqfOHJdcNL93aEro+LZ5bh3ZCC9KIwiHZTPrhDFST4qb67ldvIscFBzyoK50rou6wJgr298DoQ8z1l0UBqODP8mJZ/sl1TblEMKrnOlgF34fXF70oeJjv+Sg/zlj83S2XF8qleUOTfq0HIyi1I9v+c7+aBnEqkGy7P1nGA1ocvC4Xt/bv0PHCzl/Ks6s/2Wm4e2tJ6f648NsJGq/hlGI42d08ZJENOjUMRLSObNId417z1LbS3hzr+2XvZr19J+Z4x7QHua25WnYJQUs5P0+x778ZeTEH54KZJi1+LWZq8i28/8ntuQxYzfxQX0myaZ8Stem1ieiX5LfCtSDH2rheZis16XKMuPEjzK6sHkfK2nBZvk5PhIB59dTHe7gCv2IzHxyEgV8qS8MA0E8zPZMo8RkUgINmioEsM2AULtZDi+8Frluz2077QsUkO03rvDpTwYAP59hCtGGNgcUph2quewe/UglsOW6fgOFh3oBQGyrBUhpOv0GO2gd7Fm3D3dsSG0sZCMyxR+19IlNIWHpeluQLbZNOliLlDo12/xAgnONu0ol5Rc5fDc36yTo8fWYOrtSJ+mfnSoHn5C7hgqvubmNhvg= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: f4e7d21e-ceb7-49c6-6720-08d9c62d8a9a X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:55.2088 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: LY5BRlojcE++duPMNdOaxqPinQsCW0KwOG7pS4vsOFwwPbyLjCQVNDL7ev0a1rUPkdj/fVd6fBWgKr52XRKbpNBBKm1VShg5pzIVvjudDtk= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.15.124; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" We are going to support some addition IMGOPTS in python iotests like in bash iotests. Similarly to bash iotests, we want a way to skip some tests which can't work with specific IMGOPTS. Globally for python iotests we will not support things like 'data_file=$TEST_IMG.ext_data_file' in IMGOPTS, so, forbid this globally in iotests.py. Suggested-by: Hanna Reitz Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Hanna Reitz --- tests/qemu-iotests/iotests.py | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py index 9b374dad3d..35d92715cc 100644 --- a/tests/qemu-iotests/iotests.py +++ b/tests/qemu-iotests/iotests.py @@ -1215,6 +1215,17 @@ def _verify_virtio_scsi_pci_or_ccw() -> None: notrun('Missing virtio-scsi-pci or virtio-scsi-ccw in QEMU binary') +def _verify_imgopts(unsupported: Sequence[str] = ()) -> None: + imgopts = os.environ.get('IMGOPTS') + # One of usage examples for IMGOPTS is "data_file=$TEST_IMG.ext_data_file" + # but it supported only for bash tests. We don't have a concept of global + # TEST_IMG in iotests.py, not saying about somehow parsing $variables. + # So, for simplicity let's just not support any IMGOPTS with '$' inside. + unsup = list(unsupported) + ['$'] + if imgopts and any(x in imgopts for x in unsup): + notrun(f'not suitable for this imgopts: {imgopts}') + + def supports_quorum(): return 'quorum' in qemu_img_pipe('--help') @@ -1391,7 +1402,8 @@ def execute_setup_common(supported_fmts: Sequence[str] = (), unsupported_fmts: Sequence[str] = (), supported_protocols: Sequence[str] = (), unsupported_protocols: Sequence[str] = (), - required_fmts: Sequence[str] = ()) -> bool: + required_fmts: Sequence[str] = (), + unsupported_imgopts: Sequence[str] = ()) -> bool: """ Perform necessary setup for either script-style or unittest-style tests. @@ -1411,6 +1423,7 @@ def execute_setup_common(supported_fmts: Sequence[str] = (), _verify_aio_mode(supported_aio_modes) _verify_formats(required_fmts) _verify_virtio_blk() + _verify_imgopts(unsupported_imgopts) return debug From patchwork Thu Dec 23 16:01:28 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698475 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id B5887C433EF for ; Thu, 23 Dec 2021 16:12:02 +0000 (UTC) Received: from localhost ([::1]:37680 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0QhF-0003ZY-Sg for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:12:01 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43150) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXk-00058H-A8; Thu, 23 Dec 2021 11:02:12 -0500 Received: from mail-eopbgr70094.outbound.protection.outlook.com ([40.107.7.94]:61158 helo=EUR04-HE1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXd-0005KZ-NI; Thu, 23 Dec 2021 11:02:12 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=IPxy/z1dHNjIsmxVXhXi1YMKUjQ28t8SGIOsTopTbsjbSeHeMNwws8a4Vq+R9tE3FJKLnNmRIRr1/ssCp4pvEgmtPhitPkS1/pUS3Ke3Y6SuX1T10rfDF//Ip2/i3yvbEjB5YChBPtHC5K8Qu/1xpEaFuyOU7wWCVVMuYN4hMdzfyi8sGUgYGx2soifDevJsehfFkTIeUlAulWp+Ev740GX1tZbAiqANkUm3ZZ50s9Hb7ojzG53ZGLWJpxL+9zp3OqUFGsEmfnJ3WCDBna8n/FqO3gneM1ANm6Oyxn6QQ1NQP6/EJwFE0PDiBmhBu/8t3ERwwoNS/rITRNSDgc1M3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=3l1S80L/AtuBK8VfJ1S7eelDCqYxyEhXzR8yV4w0eTs=; b=XvYwfB8fQQ16MxO+Xvf93LnIK46RvKG5GlPCSvanrj8rs2fQTmmoAYVIyY5EkVEwtyNOukxns9womYKg6KvNrQp0+F59mDfJQoVyBZaNostVSBjdX8NVRQIiEuCxROQN0rr8gvCmCkuPToD1r3OCETWwb00MFxaRiT+Ljg7O12s6/mvUwnOK3DHuLyCbi/1cceN3e2mvJmKrJCJqRhvi4U7sYp5IyJ0QjI7PqXqVy7hHm9liVtQ204nDOY8G2CQ2vopcP8zT987npeL+mb6+MO5l+S2defwKnAlBYSl4D6AR0NPNC0KkSVCSXtM8h1sQOLvWmzi8S1WRnzwXFATiag== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=3l1S80L/AtuBK8VfJ1S7eelDCqYxyEhXzR8yV4w0eTs=; b=dhOP6JAhQd6VENrFEX5Gqy012r+qV48QVWEee61/rYT3TSjf1Dff++UiYWpDt7Vr+xHSd3ygdvqV8WoeJ0rifHpReNJFawQOks7KeYY0if0210AIFvjtGiFpGtshlrWWxu0LuUlmQWj8XXXb/0eCgG3SgnDtMNXrgvnR3mWvQAY= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:55 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:55 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com Subject: [PATCH v5 03/19] iotests: specify some unsupported_imgopts for python iotests Date: Thu, 23 Dec 2021 17:01:28 +0100 Message-Id: <20211223160144.1097696-4-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 17034d0e-d8d2-47b5-ff37-08d9c62d8ad5 X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:3826; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: W1BCfEUUSPa3fur/ZIwNkpYOxaBbjzd7wlWcr7LBWwJuIRUX1CfWzr+gg9YJFaSTrJ8EepkOVKjaHTIApHJy6Pk2Ah4IyMHRRhlRyOMSNGfdFeQkuOrNpk38LJZioqJPmqv5a/yMdS3+DXQKugkhbBb6BVt7n2w5nQI5SxGPRqVgCCaIyreXi0M6u+ztD9yKVePQAHKzWQXFUmd44GkZbG2YNxGmkXGRv4JSgmB23cXv67GqKaUQlxPP/6PSfgsPJ5dBa9tQU/s/JRm+YCJd01OvEnEhWu9jcvQMeMK2sgaHcUvZhPIaQumDcGGuE8zHhqJqQI1h4ryuMoVy9KoR3OdK74Vq/O1a2H/rrpTXw/piz9dHDlr8UQgyTNx6e0dJFvoi1sW/2T3gGrfc3KQsCm9BonhLl5z18Tz9JjG1iW8pU1Tx6Aq8Ds1G2DHJ/bhpJTPSNLHUUYZZe06BQiXfMlVqLx1nIjysgV5Wu4JqN0t3gZGq6gXos0jHzaVOTBs/hieaAyL4SkVXw/kMtkJtMH3xLXRWP4Fb83tpFaDU+eFvEA/7nreNN4HW3ntH6z6ZEFusNaff60P1wj45kZqTkqxPTA+on/NTc6/e7fRssVpC5EETRmqG+PL3IB0A+0LOclKRz5anHWGhOSbW2vwtxQOrhv+kp/HjqNnwaPSiJZWPZdGquyT3lI5IFF94l1AYubOtKRfxh1Gjw0HTfKLqtw== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 9QVRQEEcsv2TE4XmkLomPMPJzncuHSJpnMtN0C2971b/C76WdjJEDgWecPVXk9nQnhORkx+3/qgGQw5woAQ4Bi7ixcpwcZVmxLxyXixwRLZwRbBJsR+cKpnd3RHdF7XrOl4kGZNUNIWlYyOBqCEIxDK3oWnfYAjlhnjRmAI5WjzCD+BoAcXeLabaolulyrypRVIoIPMskBkrMBd9dZoFp5bZMK/oYhjQsiLI5j+35H3nBB+DnAwwHZuyinb5zwMM7dVOdef20IWsb4cGf0Ky/3eqybD/hlGrfZaMrMlF4Eay+vRsqUIkIRyH+4HHRZpPpdnn6S9CIwZl+G95oT1XoFBF10g0FeBTj1i+t8f2vo9ID6r8EoQ9nbAYFZQsEZmH1icvs6KCxrr/QaasmfJgkxg2U8/JQpDlxeNkWw/P/YBXQHHmvVQYo+ocImirsR39eEB54YrVG9bQmGiQWfvomlIsebpW9SCEen99ZCiIqsX5kwws2vxUpk3I+P5OK/wq1SSqOErFJbM+cl9tObaUoW8HD6OLl+u0616pvLAsjZDI0SeElaUS/KI/bA1B5QWpyNBA6ta2m30qkxHHEsWJevDUeu6Px3XQObbJWLKOgjE+0zx+ijbXhEBzPt5dhD9QpvFocWyvXqZCXCgs1rpozD/HRewZwiv5SuvjT08JpfOIgfzCb602xqWsHwAZsn0sm1WVBNO3Z2aOPIfFxh8Bj5YInURkT2CcMNNLyKgIlvV2j8i9F2YnhF/Bl+0nNFEYm3/UhV8pXMieED9YMgFhxRUIjQ6iZXLFCKfIn/YUtW8bzsIDDm874mxD/RQ91N1ZcuXlOeny4kMikRSe4C9M3dw5GnVM2CzQ/8IlgduR3mtHmy/94h5CTQLD33F0k7G6mu5nJthjNcTNL/WDjS/weR+MIxIrnWHNBKjElBGORFHXnU4p9RWPZ4xAtoLM6Ur0dQNGXbFqnIJi8PsvMCXJgl7dWinbRWJR0Z5vuA+wlWOPAjfUbTI4+PVEE9s055WFI713bXpuDckOhJdUcyiCgjZWaRDZBIebrD7Qn81EMumzRmpT9APVeLerfMg1+Pfryg44Q3JodfFmhgduDDiBPUgdMHjFzT9SdMif2+WvcF7YhrHAZaKDFkviu/CdWrCLGfsr5SaVeukM0NfLrCT64lNZGM1TokL+IDi5k8TXzHrpgf2SNCwzSIL40DOgkcKT5QIt0S8Hz9VDB3YfCvr1yxC7V9+6eoq3MK5RISoHxrqFzsiNbGHxyZCgk9BmDkm6zBA0Magg8JSnKmOZ92GajtaOFkasZoQceZXqFe4T40OZv506QIHKun/xpFxR5rfAe46SkuyKeDgEfZSxWtnJESNQQFj7qjTrgwGINVAcYxPwWsUEqeSOjRMWTzzdNYsCIrIy89WVhrpDahHKWdlGQwm3HJR2QRntLtrvr0JRhPvTw04qHEFh+5CqMTuaMEvak+/VDee9ru3hD8CAgsmH9KRLy42obLhr5gMPpLj0tHIOlQe6V/xS4V7jvLpA5MpsxTLDU2AJONP1nYBxdG4crKJGAEJlD39Pe9Y6qUQ65gZ0ypzUZgqLtdG2PUycAIxK9Eia0uE0Dgy+eQVom0BQB2fuEwGk1HojHrn1JREP19m5Kc4P4p3emL9eLLFltSCVS/1ZBaJI0+zSxLbymfd0tEe5bmg3pHjKU7GScQaD7bU= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 17034d0e-d8d2-47b5-ff37-08d9c62d8ad5 X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:55.5837 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: hVWJdodWju7LHwYn5HrOmbFfD83cq8l6InHvGhfQHzGVU9GHP8KuNvVYbsA6vhRM03mD4gVhNKFM9P1YMQuiDWCxWT3BXlV/DNBocOqxCEE= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.7.94; envelope-from=vsementsov@virtuozzo.com; helo=EUR04-HE1-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" We are going to support IMGOPTS for python iotests. Still some iotests will not work with common IMGOPTS used with bash iotests like specifying refcount_bits and compat qcow2 options. So we should define corresponding unsupported_imgopts for now. Signed-off-by: Vladimir Sementsov-Ogievskiy --- tests/qemu-iotests/044 | 3 ++- tests/qemu-iotests/065 | 3 ++- tests/qemu-iotests/163 | 3 ++- tests/qemu-iotests/165 | 3 ++- tests/qemu-iotests/196 | 3 ++- tests/qemu-iotests/242 | 3 ++- tests/qemu-iotests/246 | 3 ++- tests/qemu-iotests/254 | 3 ++- tests/qemu-iotests/260 | 3 ++- tests/qemu-iotests/274 | 3 ++- tests/qemu-iotests/281 | 3 ++- tests/qemu-iotests/303 | 3 ++- tests/qemu-iotests/tests/migrate-bitmaps-postcopy-test | 3 ++- tests/qemu-iotests/tests/migrate-bitmaps-test | 3 ++- tests/qemu-iotests/tests/remove-bitmap-from-backing | 3 ++- 15 files changed, 30 insertions(+), 15 deletions(-) diff --git a/tests/qemu-iotests/044 b/tests/qemu-iotests/044 index 64b18eb7c8..d696e6442a 100755 --- a/tests/qemu-iotests/044 +++ b/tests/qemu-iotests/044 @@ -117,4 +117,5 @@ class TestRefcountTableGrowth(iotests.QMPTestCase): if __name__ == '__main__': iotests.main(supported_fmts=['qcow2'], - supported_protocols=['file']) + supported_protocols=['file'], + unsupported_imgopts=['refcount_bits']) diff --git a/tests/qemu-iotests/065 b/tests/qemu-iotests/065 index 3c2ca27627..dc7716275f 100755 --- a/tests/qemu-iotests/065 +++ b/tests/qemu-iotests/065 @@ -139,4 +139,5 @@ TestQMP = None if __name__ == '__main__': iotests.main(supported_fmts=['qcow2'], - supported_protocols=['file']) + supported_protocols=['file'], + unsupported_imgopts=['refcount_bits']) diff --git a/tests/qemu-iotests/163 b/tests/qemu-iotests/163 index dedce8ef43..b8bfc95358 100755 --- a/tests/qemu-iotests/163 +++ b/tests/qemu-iotests/163 @@ -169,4 +169,5 @@ ShrinkBaseClass = None if __name__ == '__main__': iotests.main(supported_fmts=['raw', 'qcow2'], - supported_protocols=['file']) + supported_protocols=['file'], + unsupported_imgopts=['compat']) diff --git a/tests/qemu-iotests/165 b/tests/qemu-iotests/165 index ce499946b8..e3ef28e2ee 100755 --- a/tests/qemu-iotests/165 +++ b/tests/qemu-iotests/165 @@ -157,4 +157,5 @@ class TestPersistentDirtyBitmap(iotests.QMPTestCase): if __name__ == '__main__': iotests.main(supported_fmts=['qcow2'], - supported_protocols=['file']) + supported_protocols=['file'], + unsupported_imgopts=['compat']) diff --git a/tests/qemu-iotests/196 b/tests/qemu-iotests/196 index 2451515094..76509a5ad1 100755 --- a/tests/qemu-iotests/196 +++ b/tests/qemu-iotests/196 @@ -65,4 +65,5 @@ class TestInvalidateAutoclear(iotests.QMPTestCase): if __name__ == '__main__': iotests.main(supported_fmts=['qcow2'], - supported_protocols=['file']) + supported_protocols=['file'], + unsupported_imgopts=['compat']) diff --git a/tests/qemu-iotests/242 b/tests/qemu-iotests/242 index a9b27668c2..96a30152b0 100755 --- a/tests/qemu-iotests/242 +++ b/tests/qemu-iotests/242 @@ -26,7 +26,8 @@ from iotests import qemu_img_create, qemu_io, qemu_img_pipe, \ file_path, img_info_log, log, filter_qemu_io iotests.script_initialize(supported_fmts=['qcow2'], - supported_protocols=['file']) + supported_protocols=['file'], + unsupported_imgopts=['refcount_bits', 'compat']) disk = file_path('disk') chunk = 256 * 1024 diff --git a/tests/qemu-iotests/246 b/tests/qemu-iotests/246 index 5932a0e8a9..b009a78397 100755 --- a/tests/qemu-iotests/246 +++ b/tests/qemu-iotests/246 @@ -23,7 +23,8 @@ import iotests from iotests import log -iotests.script_initialize(supported_fmts=['qcow2']) +iotests.script_initialize(supported_fmts=['qcow2'], + unsupported_imgopts=['compat']) size = 64 * 1024 * 1024 * 1024 gran_small = 32 * 1024 gran_large = 128 * 1024 diff --git a/tests/qemu-iotests/254 b/tests/qemu-iotests/254 index 108bf5f894..7ea098818c 100755 --- a/tests/qemu-iotests/254 +++ b/tests/qemu-iotests/254 @@ -22,7 +22,8 @@ import iotests from iotests import qemu_img_create, file_path, log -iotests.script_initialize(supported_fmts=['qcow2']) +iotests.script_initialize(supported_fmts=['qcow2'], + unsupported_imgopts=['compat']) disk, top = file_path('disk', 'top') size = 1024 * 1024 diff --git a/tests/qemu-iotests/260 b/tests/qemu-iotests/260 index 2ec64a9b99..c2133f9980 100755 --- a/tests/qemu-iotests/260 +++ b/tests/qemu-iotests/260 @@ -23,7 +23,8 @@ import iotests from iotests import qemu_img_create, file_path, log, filter_qmp_event iotests.script_initialize( - supported_fmts=['qcow2'] + supported_fmts=['qcow2'], + unsupported_imgopts=['compat'] ) base, top = file_path('base', 'top') diff --git a/tests/qemu-iotests/274 b/tests/qemu-iotests/274 index caab008e07..080a90f10f 100755 --- a/tests/qemu-iotests/274 +++ b/tests/qemu-iotests/274 @@ -23,7 +23,8 @@ import iotests iotests.script_initialize(supported_fmts=['qcow2'], - supported_platforms=['linux']) + supported_platforms=['linux'], + unsupported_imgopts=['refcount_bits', 'compat']) size_short = 1 * 1024 * 1024 size_long = 2 * 1024 * 1024 diff --git a/tests/qemu-iotests/281 b/tests/qemu-iotests/281 index 956698083f..318e333939 100755 --- a/tests/qemu-iotests/281 +++ b/tests/qemu-iotests/281 @@ -245,4 +245,5 @@ class TestBlockdevBackupAbort(iotests.QMPTestCase): if __name__ == '__main__': iotests.main(supported_fmts=['qcow2'], - supported_protocols=['file']) + supported_protocols=['file'], + unsupported_imgopts=['compat']) diff --git a/tests/qemu-iotests/303 b/tests/qemu-iotests/303 index 425544c064..475cb5428d 100755 --- a/tests/qemu-iotests/303 +++ b/tests/qemu-iotests/303 @@ -23,7 +23,8 @@ import iotests import subprocess from iotests import qemu_img_create, qemu_io, file_path, log, filter_qemu_io -iotests.script_initialize(supported_fmts=['qcow2']) +iotests.script_initialize(supported_fmts=['qcow2'], + unsupported_imgopts=['refcount_bits', 'compat']) disk = file_path('disk') chunk = 1024 * 1024 diff --git a/tests/qemu-iotests/tests/migrate-bitmaps-postcopy-test b/tests/qemu-iotests/tests/migrate-bitmaps-postcopy-test index 00ebb5c251..fc9c4b4ef4 100755 --- a/tests/qemu-iotests/tests/migrate-bitmaps-postcopy-test +++ b/tests/qemu-iotests/tests/migrate-bitmaps-postcopy-test @@ -272,4 +272,5 @@ class TestDirtyBitmapPostcopyMigration(iotests.QMPTestCase): if __name__ == '__main__': - iotests.main(supported_fmts=['qcow2']) + iotests.main(supported_fmts=['qcow2'], + unsupported_imgopts=['compat']) diff --git a/tests/qemu-iotests/tests/migrate-bitmaps-test b/tests/qemu-iotests/tests/migrate-bitmaps-test index c23df3d75c..59f3357580 100755 --- a/tests/qemu-iotests/tests/migrate-bitmaps-test +++ b/tests/qemu-iotests/tests/migrate-bitmaps-test @@ -307,7 +307,8 @@ def main() -> None: iotests.main( supported_fmts=['qcow2'], - supported_protocols=['file'] + supported_protocols=['file'], + unsupported_imgopts=['compat'] ) diff --git a/tests/qemu-iotests/tests/remove-bitmap-from-backing b/tests/qemu-iotests/tests/remove-bitmap-from-backing index 8d48fc0f3c..3c397b08ea 100755 --- a/tests/qemu-iotests/tests/remove-bitmap-from-backing +++ b/tests/qemu-iotests/tests/remove-bitmap-from-backing @@ -21,7 +21,8 @@ import iotests from iotests import log, qemu_img_create, qemu_img, qemu_img_pipe -iotests.script_initialize(supported_fmts=['qcow2']) +iotests.script_initialize(supported_fmts=['qcow2'], + unsupported_imgopts=['compat']) top, base = iotests.file_path('top', 'base') size = '1M' From patchwork Thu Dec 23 16:01:29 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698470 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7F439C433F5 for ; Thu, 23 Dec 2021 16:06:53 +0000 (UTC) Received: from localhost ([::1]:51332 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0QcG-0001rS-LM for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:06:52 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43162) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXl-0005AV-4Y; Thu, 23 Dec 2021 11:02:13 -0500 Received: from mail-eopbgr150128.outbound.protection.outlook.com ([40.107.15.128]:32197 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXg-0005La-4p; Thu, 23 Dec 2021 11:02:12 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AxAa7a6tH4U4PAN7uVzCLlXCFcvli7hmnvuZdXr/SL17SKqUoBPupt2VVOYnpauqMT/3dzop58x8Q3Mg4r2gy7+yEoOdMOnseGdp75pmHZkySJgyGM77jh6siYGCOx48o3H7e0RI+IFz9tf44Z7Yfuya+aeT8xrt3vwOz4oEt0uuY7DlX4eTbppI8vU0VnbL1i4+k+unaFUdEiZGNqrOOtgy79YfhaELakXjmH5AwPfHJjvNmyK7wwCvFKbOpYH0Mv5Ml3f6liB9ITV3/9Nux7wz4CsImoBQUdradPq54PxBgM6pEgsE06qAxMiEg4/1+2xKkPO4sGIwMel3oQXcKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=4lqvWBraaEC90gOXEJ0/+9/eyzSsX6A1KQfcrSscf0Y=; b=nCtiNo5Jk4V6ysSaL+6Mjo+LPqK8LKiBEnv3S0C539Dz98gD+HPql+bFuot0/gWQ1tJvyb+Xk73Tic1X24VK6PAOuvBMiPfTu5u6Pw0yorktv25YeyPlPyCBgceEtiMaJffCAabQWDPPUaDln05grtgmadJ/W0Y9pGrGYNCc0CxdzqoM3Zf901X5+k12US3y0c+yHER+K8+py7VgmV4lSK6cBs3AtHL4YTGQwd1TC8Vf4UFNwA6m8qlKxBgpIviGaK2egZsJgH9XtHZf8uW1ZLaf7YXaz+R0WIrWLjkYc/EKeni7I3mgQYu7cxX+G731Xs5qghYG0xzDXmd8G6yf2Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=4lqvWBraaEC90gOXEJ0/+9/eyzSsX6A1KQfcrSscf0Y=; b=pII9LtKyCInfVOv1j1UAr+YjBjZ4VeRJRGxbAq5FmdaR8ZKp1hP32pUrby39Jy7q9JkCu+xbQTlAsOMwYAFi0XgEz2oALxgRasEhLxZyOq758eK3+FhCO2I4FNJfGiwKHfZadC3ehV9MN+LP3Mc/QqpwfJJhpLnL3cjUYXvnSP0= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:56 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:56 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com Subject: [PATCH v5 04/19] iotests.py: qemu_img*("create"): support IMGOPTS='compression_type=zstd' Date: Thu, 23 Dec 2021 17:01:29 +0100 Message-Id: <20211223160144.1097696-5-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 652a7aa4-a026-4fac-a067-08d9c62d8b13 X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:8882; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 8Mr5Z4WrtMslg9EVg8zHjW6I0wbcW/QAf2lTwPIFvNAZeLoGbN9YH6kIKVLqxt01kH7XBeZ53TFPex8vc3NDsryK8U8sCan61SCuR9XnU8HcCgUPD6m9whBZG0dUkBDjwz9Pp2iHBadaAuzZM2KfD0cuaToe4ZlzuVpFIyCEmFbtvrzs+wrHYqzjEWZAngvNtaUI2nJ+Ti4Lnmr2r91wQJzIUVBdomH5PKv9zIkCKnOfJutCQSqJ3etS6lvx/tjfQ6iI+Ue219w2h3Fvy9dDDNyOzjOQSGvIwvR1j5xQ7f52lZwjaWHDuyzVt+wx8SAzWnkhxPzQqUSWc0j2UhQLs0QSGAHr2frl0mpmYT+9jfqL5ywzPfy5XKAjjN6sC0k9Phhc5EZb6+oJiFo5Qsc865nnviuwnhVBXtlM2mYTbg/jQoLPZXdUFR/iNreArYIsq23qySXueB/hkNIAqi4XuNV1QHUY1rTTSsO19stjP6/qeiyAmYjzXx0TjSI+vfFYoyQZo5FRDaFy8fGPE4QC9zQ/QCbtBi+yZU+7+xVGUADfUZTTE8HwYoQWvgduAmHbROPUkG8xG93c36H8T+aBxYWZNQE/rWs0XOxXia9UQt/muiZGzGal32av6rIMjkt1iOG85xu/QEekTfiaHdFBxDnPLJmUil6iOHSaQI/qSoQS0A2Dl7X2PP1kel21W4hpUF+nB4x9MCR9IV3jykdclYNvsNXVSgzpQbhsGJ1ndV4UYG0vnR3r25AfID0FNfKoMXqL9KLPSbrAn+TCAhrF/9I2d5XF6isCCTZpknW5LzA= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: lY94NFdnAdVHZIfyyNnJJHdSwZJ6miiNzdxG1ymfSacCXwgmve0f5LDETKHEeKbGhI6hkb9hgvuzM1ZHyKOz09oUemxucQElu4X5FsdKl+xG/RDKtJWdaKZ6h5OuEXZChOFO6yXHcc+VcEX3oliTZTR9v6/V6f8fspNIaH29WcA5awJpGVBXFAUSRYqi8oUqOjBA/o1MthHxhcw+sJfl4384zWmcjUOv1zPEGM7VnoHHYmBaaX5eKAb8fumZhtOXy9UJHN1CviXhY8WTWzBmqDOp0ztErG4cU+v1o0IrhaiDN14+qoGaWyWRNpokcjdUDEfxUO963Z2EPRWYXMW2V8yy6KxS2DLVO6lfVRiTiyD1rWOEiWTRcWyPxxlbaxUo6gJMJuPFJRHMoDWnyO+HcOveusmot9lW/ElbH1ZO8aKNBaoNqQEJnY4EVz70dBLrhyyMIWbjrAS4sq0hhRD6VCQmW22xZd82HWTSc1Goxhf518wmFJFug/0S7ZHAmwZxB/yfuFfNPwqq4+H0cdRsRabq8WwQ5bfNP7RR47qansRviMeDwgQu8abuRvGzM3B7NjEXG/YW1qAJEkTrSR6FRKsHmOWJO2Hc1Mbts2S/8qUAFn2+N0B9+Be0yoadcItbHrfgbyY+vSsibCXPsEJNdA1ICPjOxkG+7jDILEec5KtGOqWu0ItzZpWbB60CbsOAbjonuoXx0bi4emd4obAAaR3JzFUUCSfrIbGBawij1hgMrtD5GTftmvSGsHZh2U/tbe1B4XgngsZEJiDmmjS+yfx0KZmUlo05W8VNnTKdyM5wdNndGuOum1zOUt5XqUmyrbh1X0X/SphniZkx5lRcuaCLlcbpeEZcvnABdBDoBDFWjtmzdBH5GRz2itwUl3Sj/wjv1B1Ae0BA82hiTSO9UWPCu1YBueZC0+hWP3nIVv1P4gnEhFxCfnbeqQPnkS3GUtGahFKJp+fHg+o+YicVsAENyELkyu3GgvBGfP5b6qWLV9s+B+DAZVnlAf+kXhkExt/NPR+gzMamOB5sAm5HWO5t6whR5DoOLXHAZljbVm4Gwy7xwSEKg6nNXkRw6cusOa8R6sr2HzorKbT3br/SlPKFJzDM/aAyJepmMcUhROqQfBTkkXoCCSm7MoMZQnkyNLqvNxfwT2hj584mzpYsOivaq0EkG3pliDVCR3LnA273SijcgcPSoiPHjaavSNY0xkzoZDNKK21FiyJdWvyggB0D9/TbNEje266VMSxGkLlsAfLnsaWLyrAMf5x2C/Jam4HWy5Ppu50c4hWEQclUQr8OnDVN9W3yc2WLH7epDnwZl7kHd0W+Mee/njhYsZlDstrDcRzh35xpyX/EvkmGViRXL/D1HlWLxHe02k5AazXJJuj3uGrxcSOErKT7jKFSteErBormtj42tYlhObhJmmkefYe1/hPaxc6+QLQ6JrCdNuUX27siYRPgQ2azPYOW3+q7f75cVCSIXzoGAE1pws3XoSX9EHrKdcq65aVb7tioTIeYYBDD2EOzTkwV5DAHTUbS4KTKmuUO96d511QxSLnMmMQijalYfvOA/hYScDnNoQPkuKRe/8V3xDStv1NFBB3Uk2pwsLeAEoxtAWnirVRuKIrF//ylS0pZWe7BzYwnoX9ZVtXTNJJizqxBxixn9uwE5xGFsCtMrZ7SiwyKZ7brfQFlwNvh4SreFnwA39o= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 652a7aa4-a026-4fac-a067-08d9c62d8b13 X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:56.0189 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 6iSiE4NbPOE/ccTnndT0fsPSISwrHI7NYpTcOXbtGr2VQ4QG/aiukuD5XnDLuXsnybhP/vgqiF4w/A3Z61obcbyMCWs78KbV8PK68oGKteI= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.15.128; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" Adding support of IMGOPTS (like in bash tests) allows user to pass a lot of different options. Still, some may require additional logic. Now we want compression_type option, so add some smart logic around it: ignore compression_type=zstd in IMGOPTS, if test want qcow2 in compatibility mode. As well, ignore compression_type for non-qcow2 formats. Note that we may instead add support only to qemu_img_create(), but that works bad: 1. We'll have to update a lot of tests to use qemu_img_create instead of qemu_img('create'). (still, we may want do it anyway, but no reason to create a dependancy between task of supporting IMGOPTS and updating a lot of tests) 2. Some tests use qemu_img_pipe('create', ..) - even more work on updating 3. Even if we update all tests to go through qemu_img_create, we'll need a way to avoid creating new tests using qemu_img*('create') - add assertions.. That doesn't seem good. So, let's add support of IMGOPTS to most generic qemu_img_pipe_and_status(). Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Hanna Reitz --- tests/qemu-iotests/iotests.py | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py index 35d92715cc..f0370b5206 100644 --- a/tests/qemu-iotests/iotests.py +++ b/tests/qemu-iotests/iotests.py @@ -16,6 +16,7 @@ # along with this program. If not, see . # +import argparse import atexit import bz2 from collections import OrderedDict @@ -153,11 +154,35 @@ def qemu_tool_pipe_and_status(tool: str, args: Sequence[str], {-subp.returncode}: {cmd}\n') return (output, subp.returncode) +def qemu_img_create_prepare_args(args: List[str]) -> List[str]: + if not args or args[0] != 'create': + return list(args) + args = args[1:] + + p = argparse.ArgumentParser(allow_abbrev=False) + p.add_argument('-f') + parsed, remaining = p.parse_known_args(args) + + result = ['create'] + if parsed.f is not None: + result += ['-f', parsed.f] + + # IMGOPTS most probably contain options specific for the selected format, + # like extended_l2 or compression_type for qcow2. Test may want to create + # additional images in other formats that doesn't support these options. + # So, use IMGOPTS only for images created in imgfmt format. + if parsed.f == imgfmt and 'IMGOPTS' in os.environ: + result += ['-o', os.environ['IMGOPTS']] + + result += remaining + + return result + def qemu_img_pipe_and_status(*args: str) -> Tuple[str, int]: """ Run qemu-img and return both its output and its exit code """ - full_args = qemu_img_args + list(args) + full_args = qemu_img_args + qemu_img_create_prepare_args(list(args)) return qemu_tool_pipe_and_status('qemu-img', full_args) def qemu_img(*args: str) -> int: From patchwork Thu Dec 23 16:01:30 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698479 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id F05B5C433EF for ; Thu, 23 Dec 2021 16:15:18 +0000 (UTC) Received: from localhost ([::1]:46250 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0QkP-00010L-Rv for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:15:17 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43198) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXm-0005FL-Ht; Thu, 23 Dec 2021 11:02:14 -0500 Received: from mail-eopbgr150124.outbound.protection.outlook.com ([40.107.15.124]:2176 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXg-0005Js-6a; Thu, 23 Dec 2021 11:02:14 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=B3I+nNznB3my47IvhGDk58amh/RaRVhhklViGDmvFUyiDpD9VA7wL5JazRfxrnRa/ZwJS/9qA+Gwl3vWAz+M5ojs9emudDQTJo2ayyUf0+0k2zBJ+sONzf5oipURQ0jgyUKVQdSWWqBRdPcy+dV2MMa0f4ZCB4YOsbE6E+H/TbQu+OpsPV56ijnzOE9iBobdzp6g0NUPaXyJf/OGfTSGe70p3THAhh82IyZG5eItjJdmePjn0itiVnrzA8CfN9uv6eQUbPeJSHnfGJf0r1l1pEPAAGVZN64VlYdIrkfHCvw8/Qy4DEWHraqDCKLn7NQpNizgpxJ697ueC3DBvStdNQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=5Fa+F/H7Tvpi70Z+kG/DYY5wrn0r5gwyoz4B9H+F7N8=; b=n8EPVTnelPiVx9Dhy18eaR4lYFw2LqFh60yjK9vkShEsd4+Ufuss7VNtValzaL57o1EqdbboJ19Yjz3psirHOWC8MUa4hO8i9WBvz9Ngd/94kqw5VHSEH0iUHARYTQ2H3chtXvJPvv5pLiyHF7DecLWJMbpTLVMkMyMc4DQX/a/oEK1uA6pdibBwS1BIGi48rWNZ2JbSoH/LZkR1fR+PlYiqg/GucCbW+4hVo5CBWU4pqA4+WHxMYdyCIErHni2UgiqwyKWFiGqqekmxZs2MYGDgMB99CoYKOCxnxryxPlvXk96y1noafAWZmwMbLUZPEPSD/q4vcwFGZb7L86Xe5w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=5Fa+F/H7Tvpi70Z+kG/DYY5wrn0r5gwyoz4B9H+F7N8=; b=wAHFKSknZDOh44INz23Mp1bdNgGDB5JN67mfn7f6Y/Bptxww4/HCpMkz2066LNjjjVofLlR55ZbenTZiKOqbAvZ3aapJeilO3gJJIIU3D2p3Ahmt7mTk5dgBXVPgImagG4G8293lkRsnHMrqjvFOFTMwgC7lK6XdDbJb9P77KfE= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:56 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:56 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com Subject: [PATCH v5 05/19] iotests: drop qemu_img_verbose() helper Date: Thu, 23 Dec 2021 17:01:30 +0100 Message-Id: <20211223160144.1097696-6-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 84047942-25fd-4681-0ab5-08d9c62d8b4d X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1923; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: erySd0M7+3s2jA0yFtzKpVRPhfMkvXq4p/F5HITSowe07ywFILbVyecgHMGFtTsCf1eUnoEIkHlm2zk7FvGKLh5OKAQQWP4Ag/l6hUbJcZVGwYslCCW4CCmrNg63nvtWEaEUonC65Pji1Kdm248ZhJ70ansnOM1iGTNKQQH5xJ8ssyOXcwxDUG0XMdXSOQqk6p0m9wgEofx6NbPEKk7QntsVwbudyQXxU011ovrqFcePUlypdpZVPzUd6ROVXsCfa03dXa4NaJxD9L5dn7wbYa3P5xJ/khRJmCQf3RwzTcvJeMYNeAYQzs5/rEtDdhgyTfeZQc2rVtS9V1TkqJZRcwIZfN/uvtRNRC0mtxyBLGhGfmbCt/juAyMM+NoVZrUQN81XPdfEUUPg1YVhSlDChaZdFROM5SAJSlWoEsDwgFUYUlYJeVvIRTBfFVFqYPyDQIuPlM5DDuw/aDEaUCpqaHYwEYOr/IlicOjZs6KFOqTmVNFPaDFN2sJFMmAOSMLF8rK9Q4C4i+pzNuJmVVQ9+dGN8U8UI33MI5vgMNI8eQq4kuRmNypr0O3ebuw+fukoHidBsZSv4Y0oAo4aLlwjlpmOa5IsakPCBtRqWBbfi1u34sDD6wliBhfL/bLKZEZVn0C3SKICOzoR1lzqL6eHwVVO0v5dgLH/rIrmQqQDyryj7C+7vawwzin2PJYjOhFFeUaU0XfLtMbagE4D74xa4g== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: npnKV6uf495Ji4gKEsNt/2EusxhJMc0kLjht38Aclbg4PYGqHEiZPb5s2vmrEXWIXc30PXwDXZuolEhIajfdwojFPdC57deoMbm/BWN+yAa/takuiBVxdSPdNeuTX8aQlstZlPExukkuQKMJSnH2a+6PWWda3ATETV6oGg/EE36uX5uXJHf671Z644Tt5bpvZ49zpmEUkqNeNo4YVzBtXiT5oRH7SULt5jyAaJLpFHtQxx4qvBV/kwRg4CtXxeGPcYSTlWXrQdcsFl/h4qXM5oK1fxsY+t76JxiwAmvAm67PqiUctyw9PyjbNXJdshKM1zh4zmaTFDlCg+gBcHNkyUv7cAvXry93urAWOW62HdoQoJce1G5puUL2KwhaXIDcVqB9TrTL2/cc0NoXwrJPMge4TDvYiM+DlnZXhINSWoR7APBpAKa5YezjEkQLzelrbwZbqZ0FWTAZShxP/GV8AakTJLfSW0b+SXrrGvJr+/l9A3JmTdU05ckXGco9ZUWD4pfOyY3gdug1C/4TU+Pn6NMdUSw5ldHFAlKvmuPfqkqYlDSFplCBOWkihEHRDZVpXHImXPOH5DjppMoSbDZcee5139Y/rcRjmtOsPeO5LI108PXUZlwoB9eJ4JaE5Obf1303Aq7WD+moqMM8NVUiKNKwZU494B98v+Q6OWZIZwCeVMeD/8fWoQ4mYQRaVL/WghTU67IZjSZKf2p0WrHJDKvU+rzPujz1HQ0mmtJmJEdzYX3FTcGZ42OqYFltZcZ//ELUVziN+b4XOcj7AbmfpwC3iCPh+TSZiZXN9CnxMxrg3btrOxcvc6gZFepGJjxbZXWAXtyXcCpt5S57AL3jU6WIZUIYtWJsCxGlJUuMQVNZWJDmXjNMcokDywA9b6iQc3hk/8FX5vV+MwJUBbufiwRcWOAAUnsoJXlqQic0d6IP6tbOcky8rzHT6tdU8rOuqTEQp+W2x3px4jRoKzPefBxj+E/My8zlux5jGidSV5Ud4ybWEtUXy5G45lGfSJXWCAJXH8dIiV2U9dPNVAo8ucxn5CtvmN1FOCoNYQGteC+gQNl6IRE3SDI7cQM+K+pnAeZ7ICD2/9k+a15gZx1EKMTpmSia5/QbszO+4pnbX5Z++38WSU+WAKQyouTTfnjPNGHsWI1yhNxZ8D8a75/HHczoz+D+YHaTMO2zoPk5sSJ5ebWkYhtp5A/6cjXr6VzAmYLDje/FM6cKHZ69KltO33wmh9U/LPTXe7++4Rt+ilZ0v8TFZzEMfM7Of3GP9wtZbS5ffmtJfWBrQUn65uEA0pfGeh9VMjeoTIdlSxU+48R83ZovuFM4tMKxEtbf1Zw7b0EkhA5/gtlKw6ckKrIofBRD8/Kk1plFUGw1yjdsmYjGyKqBjVH512dOb5SCejp94R2GYe7cwSp5Dla+cRAzoI2ewTxCR+oNEsAh19zAPRCC5Kl1CpWzQzGlC9P3XGb4ULScqK91Qr9QUxauYm/+o5BntmEnfEG2pxOro7A462FaO7Amr2htGA20JymS9WaGQJ68StCMenvDGntgJHanmzUzkqlalKyflYaGWQ9adzxUeFqnUzUALDl6zkvl5leStinQwzKPT01EGDydvsCDtOXo4gC4OMsIWQlYF9FyuPPVPtB08VhAgxjhcUCIYScU7VwAOgOb9qeiuQLPCS6+jiTqOuzAZ7rrcS/brZb9c4o= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 84047942-25fd-4681-0ab5-08d9c62d8b4d X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:56.3483 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: SwUV1p7dnwKp0ssZuqO1ArknEWF2kCi1l02m1JwWfBrDDf9dNsRZVk2p65+yOPVVnRSR21RvYFyWCrT+07AYLu3MUctWq+8NXnib/U0EGWg= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.15.124; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" qemu_img_verbose() has a drawback of not going through generic qemu_img_pipe_and_status(). qemu_img_verbose() is not very popular, so update the only two users to qemu_img_log() and drop qemu_img_verbose() at all. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Hanna Reitz --- tests/qemu-iotests/044 | 5 +++-- tests/qemu-iotests/044.out | 1 + tests/qemu-iotests/209 | 7 ++++--- tests/qemu-iotests/209.out | 2 ++ tests/qemu-iotests/iotests.py | 8 -------- 5 files changed, 10 insertions(+), 13 deletions(-) diff --git a/tests/qemu-iotests/044 b/tests/qemu-iotests/044 index d696e6442a..a5ee9a7ded 100755 --- a/tests/qemu-iotests/044 +++ b/tests/qemu-iotests/044 @@ -24,7 +24,7 @@ import os import qcow2 from qcow2 import QcowHeader import iotests -from iotests import qemu_img, qemu_img_verbose, qemu_io +from iotests import qemu_img, qemu_img_log, qemu_io import struct import subprocess import sys @@ -112,10 +112,11 @@ class TestRefcountTableGrowth(iotests.QMPTestCase): def test_grow_refcount_table(self): qemu_io('-c', 'write 3800M 1M', test_img) - qemu_img_verbose('check' , test_img) + qemu_img_log('check' , test_img) pass if __name__ == '__main__': + iotests.activate_logging() iotests.main(supported_fmts=['qcow2'], supported_protocols=['file'], unsupported_imgopts=['refcount_bits']) diff --git a/tests/qemu-iotests/044.out b/tests/qemu-iotests/044.out index 703cf3dee1..ff663b17d7 100644 --- a/tests/qemu-iotests/044.out +++ b/tests/qemu-iotests/044.out @@ -1,6 +1,7 @@ No errors were found on the image. 7292415/33554432 = 21.73% allocated, 0.00% fragmented, 0.00% compressed clusters Image end offset: 4296217088 + . ---------------------------------------------------------------------- Ran 1 tests diff --git a/tests/qemu-iotests/209 b/tests/qemu-iotests/209 index ff7efea11b..f6ad08ec42 100755 --- a/tests/qemu-iotests/209 +++ b/tests/qemu-iotests/209 @@ -20,8 +20,8 @@ # import iotests -from iotests import qemu_img_create, qemu_io, qemu_img_verbose, qemu_nbd, \ - file_path +from iotests import qemu_img_create, qemu_io, qemu_img_log, qemu_nbd, \ + file_path, log iotests.script_initialize(supported_fmts=['qcow2']) @@ -33,4 +33,5 @@ qemu_img_create('-f', iotests.imgfmt, disk, '1M') qemu_io('-f', iotests.imgfmt, '-c', 'write 0 512K', disk) qemu_nbd('-k', nbd_sock, '-x', 'exp', '-f', iotests.imgfmt, disk) -qemu_img_verbose('map', '-f', 'raw', '--output=json', nbd_uri) +qemu_img_log('map', '-f', 'raw', '--output=json', nbd_uri) +log('done.') # avoid new line at the end of output file diff --git a/tests/qemu-iotests/209.out b/tests/qemu-iotests/209.out index f27be3fa7b..515906ac7a 100644 --- a/tests/qemu-iotests/209.out +++ b/tests/qemu-iotests/209.out @@ -1,2 +1,4 @@ [{ "start": 0, "length": 524288, "depth": 0, "present": true, "zero": false, "data": true, "offset": 0}, { "start": 524288, "length": 524288, "depth": 0, "present": true, "zero": true, "data": false, "offset": 524288}] + +done. diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py index f0370b5206..5a6bfcbb6a 100644 --- a/tests/qemu-iotests/iotests.py +++ b/tests/qemu-iotests/iotests.py @@ -227,14 +227,6 @@ def qemu_img_measure(*args): def qemu_img_check(*args): return json.loads(qemu_img_pipe("check", "--output", "json", *args)) -def qemu_img_verbose(*args): - '''Run qemu-img without suppressing its output and return the exit code''' - exitcode = subprocess.call(qemu_img_args + list(args)) - if exitcode < 0: - sys.stderr.write('qemu-img received signal %i: %s\n' - % (-exitcode, ' '.join(qemu_img_args + list(args)))) - return exitcode - def qemu_img_pipe(*args: str) -> str: '''Run qemu-img and return its output''' return qemu_img_pipe_and_status(*args)[0] From patchwork Thu Dec 23 16:01:31 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698472 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6CDAFC433F5 for ; Thu, 23 Dec 2021 16:09:24 +0000 (UTC) Received: from localhost ([::1]:58718 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0Qeh-0006zJ-BO for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:09:23 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43228) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXo-0005Lo-5U; Thu, 23 Dec 2021 11:02:16 -0500 Received: from mail-eopbgr70094.outbound.protection.outlook.com ([40.107.7.94]:61158 helo=EUR04-HE1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXk-0005KZ-Vx; Thu, 23 Dec 2021 11:02:15 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=bN21Ntcayv9U8VycYs1ZDkDzgarfQLN4UHGv9gIRc0yHZbSw/ZFp+QOmNnpaaE+It6Bm5AmdeNZ4XL4kfHPlHqWHKRb8a1pHrTe1fNfb+9IsmabQJqXifW6tZcCPHO+s4hcSUVX15MY9W09lR6C0UqJmAcJoRhQgINQkyt5CEV+/SoDjON56U2YKg0MkAk/uLLX+j2yMj1lElmUoYOCHQlUTN5LVpyZNgpAjEK6EGhilFIJjDjH2Aow+MwW2Ku4HLsaPQwaMf5gd5luaSUmyz2/rA6fPvsxRW4OFxDMcAw6re8Tj7gCz3LwaZNPQwo5XNXXoNg9F9oJ5inRKvBOcKg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=vVh8nyePVg5t6jGI9De4e826WvLiuGz4daiKw7aF7Kk=; b=ZS6GOq9tubyBimSFdWK24hQVSnmC0Yfc67jVJFOnETBH6zpL7O2GoR8305Fc0o7vJBKPVu2NCaY/KfqTIjtSWEgpk3vT0CG2Y9IFtpByQ1aL5AEPRDJqFDDypDFwb+yYwwDhVfIgzWWuV/WotrGS6ELTD7MoMMlcvabQMwHpuGYgmNdrj+aydFBns2pwLv/zbAwrz8qb1UV14cKjoygTFz0TZFlMmYe18m7Az8BtVhp8p8tffs5t/h9lZqGI6sScnOLRsaI0EbMA9IuYB3kpZ2eOqkvuteK803+6NljZjsYHjTvZpOgJgqCbUlRwPya3hRQJHOfSl2xN6TeiQpMGMw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=vVh8nyePVg5t6jGI9De4e826WvLiuGz4daiKw7aF7Kk=; b=i1hkdMe4tjHEQ3Z0DFWpVtByrC6FVy/p6k4Mta4E+S8MAMM6kJXkA4FDpGT3hJSiWJJyYRcU3ywLubZL695phlTOm4jrH4dIhD/HJdlSbnJq1CPJLHpAkaDQDc793Yy4WebZRgiQNJ8uwhItcihQ+LQBbf+nxRr8erAdqOqE5Ek= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:56 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:56 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com Subject: [PATCH v5 06/19] iotests.py: rewrite default luks support in qemu_img Date: Thu, 23 Dec 2021 17:01:31 +0100 Message-Id: <20211223160144.1097696-7-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 40055b04-1898-4531-de3b-08d9c62d8b83 X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:5797; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: rJNl3grUCndSQWtlnyLDndL5q877QI3l8r1I7CuZwMwFOWBmUGMNn4z1+4+k6xlfYhXK3nDLlttjQQjW5ObgRNVm3wlpyrtC0Bhv4cEe5MGAAI4DFXZ63ykORBSP7ruAFMRwxgvxuKJXB6FS2cJCdJWyzxeWPyug+UZ+ct6JDs/G0g5touIlvGYgfdKD/cjFkP8pJ4YseHH8JCCa/oGzzq8x7EIUa5KUDGqGlWzmzVZtcwmZ9C0SAFi4vtltBYKQC7Gp+OhN1F1JqdFPcFyPzs7z6nIuNqvDdcNlmRQUeMxLNH92XsrU9Hhf/pL5awH7RtoOC0yzbtOq11Cwmte4o2/C7LR07XSk8DHCKSKXC7PETUh5Zyg8SwSDldzlDDZqUgkORhVzUjz/7/z2QmD4wngKKfaCeW0bAYS3Xzb047AKaQYf8y8r9MpV2lhqERKWWYXX3j2m0LjshYi97lCnSspcLzhjxxvWvFnCViMnog4y1ipNUodH3h5q/ju2ESEULSyhZZWon41cf5Bw+U6VmYzU89D3PFVUwtrncdZfqHcn5w8wYzyeODNXhDrjvOziXVwCFKgkSyCv7figXN0exRKuxMUhDJUZUl9673BULJY42NC2UoqJYieL0KdSneSmh0ZvwSVZmxdmqzOj4R4LQG4LKGfTqxhNKA7ktUwnl8ZOrAFKvjOagxDJiY0LuOTm5JzRImePmZDM7YlkLMWAtg== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 1ziCIn+CokLcpf6N7ePpz/zeSOtBtFOkftOWzjxFHTOz/97/DYYaP/bz7ONCP9xPSG+RheCpi1B3rvudOoVjlpgwwttJM9x/zDbUKi+8+gwBwqlCYcc7dLCBlcQWRk1N5pwd+GO3YZHq1VHJqrFparZkgnGZBm28PedRdbkwKGaTmYUbsZ5PBkjRsbbmAvpzf4tzKAb0KY0Gzj1EH1zC66o+TL17H5s1F9wp1dKzLrk/4gzeSxCEVj1KvdfWv7gNCcuQcDFapas8GgCrjFB57nROwMg8X/6KSfRYrErUzGn927ZBtgCVGM7+zYNungYxyZGzIf8oOFnazMUNpuOeXyDM+2GWcY2rxo8Lw9OERkwl5H81a2GOfOIMmZAY8ZqD/Ap/o6WDpf9TYtnCGD+3Cbs0WTaElbErDQvffWKvTYKAiojC6YJy5NDdTZRDQewMtJevR6oU8gazde4Fs56fXls4nqZJBssgj6FmxHHFHoj7u9mwwqOE/yE0EUrxCF8o1OqNEzMjTe0cU489CrTS2Fb9bJevDK8YACQu2AtD7oRtrvu11+MQIOkbJM0vIeB7vpe6Dpii0YThWhgHTNHm/xXM+H5+qKao1OiYr7hvxN6P2HQbu0F8N4rPEU85DOuZqxKhEUs3UEdaAn2sxAtdSJsDofmQl1Truj/KF9Zv5asYZRCoegdpnOJZF0QuqddMnmOZemVJjj4hFMZCnwv5zPZlchQ2h68klL9f+aWU25+u+qUDnh6rgN6FCGyYx8LB1V4uliLPjsjYw46yod7uLXOL5ID+C+CQk4nura76g8xWBngMUJiFKtTHUkfrK575Uf/3laafZYtlW4GFAGMsjqLmGeInJojk6R1Wq4bCgybengJ4Hwx34aaxKmSZXBD/Phx8vX/XWvFJpVTpH/YWNMx/3fNZ7BPuVuL51oSjVr536D5zx9Q8JEqHjn1k2JpWUYmmlX1PdSlzuZDy7W2SpSu3g/UdLh37ZfsUjdOOERqVvR0/9JNfRoT/YI2PZXZZRQFdr0+DxypxPrr3lwPZ5hDc3tOICRyZ2lFUFsh2geWUi/cHoD/dljwzDGs/wvI0uzKO20EjwjOE1YaVNrwpL4QWaYDMWNdPfqUUn/3kWrVzDur4j21gecZgekEFTQWnJ4e+5Rgm/sKPGA6GE/MJgaPsM52vvPYUo/JnjAvUvyyahSZagVCIfV+9aA0uYdwX2SAslzeCmeV7E/35sMueKYU5hsu/m5RKwU5laZqoju3IbklkXqHJLgdVyXMmyIV44FnZ48OyIP0VOSxrM3IsupFfFCT03P5/vaeLvvEla1j50yn9OyIjiyWMhqGTxTyxIt44lgJZJHcMVc3lmQdJ08Cinf1ay3U75KcUXAqjjJPMi5fTOy08AEY9AY055pg3+X4mD8ufqIpR5hRLdJXKh5TmuTc3t2wPaVR/nqFgHOHgusOOteUoDMriHBINnd4uQ6erKVDnZFE5GUcNs7LGFTSpxAaZ61Um89DOWhguhp0Dw/GN0R2rTy4zJyBZ6rl3Zi6ls5cbk0YvSVkh3hf3roGfyKJICwBcMeYPKSeLes5k2IErLR1FzR27VTPe/b7/jzD2GTXWsB7199e1h2moe3MrgO14Rqpg6pzvcKwrf2KZgnifTCAYtfKfSkG+XZYEvXZ79NKzoAb76UL6DoNDaKeiHIb76rQ0w0XZmRjiAKU= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 40055b04-1898-4531-de3b-08d9c62d8b83 X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:56.7076 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: IiK3YlMO1y0uI8qlF2UIcYYuBZwk1g1GCPsnQJ5mQX81ovzM9wsAqZqV4Cjyb/gfaqVkwABH5BVwW4oFzfJYmDxsOwvPAYlzz9JyjKI1PBI= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.7.94; envelope-from=vsementsov@virtuozzo.com; helo=EUR04-HE1-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" Move the logic to more generic qemu_img_pipe_and_status(). Also behave better when we have several -o options. And reuse argument parser of course. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Hanna Reitz --- tests/qemu-iotests/iotests.py | 36 +++++++++++++++++------------------ 1 file changed, 17 insertions(+), 19 deletions(-) diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py index 5a6bfcbb6a..f424e04573 100644 --- a/tests/qemu-iotests/iotests.py +++ b/tests/qemu-iotests/iotests.py @@ -160,9 +160,13 @@ def qemu_img_create_prepare_args(args: List[str]) -> List[str]: args = args[1:] p = argparse.ArgumentParser(allow_abbrev=False) + # -o option may be specified several times + p.add_argument('-o', action='append', default=[]) p.add_argument('-f') parsed, remaining = p.parse_known_args(args) + opts_list = parsed.o + result = ['create'] if parsed.f is not None: result += ['-f', parsed.f] @@ -171,8 +175,18 @@ def qemu_img_create_prepare_args(args: List[str]) -> List[str]: # like extended_l2 or compression_type for qcow2. Test may want to create # additional images in other formats that doesn't support these options. # So, use IMGOPTS only for images created in imgfmt format. - if parsed.f == imgfmt and 'IMGOPTS' in os.environ: - result += ['-o', os.environ['IMGOPTS']] + imgopts = os.environ.get('IMGOPTS') + if imgopts and parsed.f == imgfmt: + opts_list.insert(0, imgopts) + + # default luks support + if parsed.f == 'luks' and \ + all('key-secret' not in opts for opts in opts_list): + result += ['--object', luks_default_secret_object] + opts_list.append(luks_default_key_secret_opt) + + for opts in opts_list: + result += ['-o', opts] result += remaining @@ -203,23 +217,7 @@ def ordered_qmp(qmsg, conv_keys=True): return qmsg def qemu_img_create(*args): - args = list(args) - - # default luks support - if '-f' in args and args[args.index('-f') + 1] == 'luks': - if '-o' in args: - i = args.index('-o') - if 'key-secret' not in args[i + 1]: - args[i + 1].append(luks_default_key_secret_opt) - args.insert(i + 2, '--object') - args.insert(i + 3, luks_default_secret_object) - else: - args = ['-o', luks_default_key_secret_opt, - '--object', luks_default_secret_object] + args - - args.insert(0, 'create') - - return qemu_img(*args) + return qemu_img('create', *args) def qemu_img_measure(*args): return json.loads(qemu_img_pipe("measure", "--output", "json", *args)) From patchwork Thu Dec 23 16:01:32 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698476 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 3ADFEC433F5 for ; Thu, 23 Dec 2021 16:12:31 +0000 (UTC) Received: from localhost ([::1]:38688 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0Qhi-0004HC-3B for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:12:30 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43254) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXp-0005O2-GH; Thu, 23 Dec 2021 11:02:17 -0500 Received: from mail-eopbgr150128.outbound.protection.outlook.com ([40.107.15.128]:32197 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXl-0005La-NU; Thu, 23 Dec 2021 11:02:17 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=bYLDGFHps4sKPO+VZBQTGd5scweg53cczNhauw7nJrqMJXpzezUpW1K38/0RksvFY7Qy203TtmnuCw4rM5+ysDCMrzh5i3UwMVxXaSCnCyjwJm89FONrf9PeFN/SgCo/JcthT9PEL/U2/FWlXPpmiF7Tqvw5sCV+07bdevLK0Ce/+jo3mo+8NpVvp71snJXCBqLB4GfTqTX3mA5lORtYxWIulREzggmIkwreXxEXOY6LStX/38lL/ACJaJqPrxwHr6zvZMO+Z6R3WLlTGOOV0cWQBFRPCa4G1WjSFrXhaAb9AbSzcJDWchFth7D9CTAsTiwKLB5HsLWXKsdZuLNqxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=PYvWbov9Jx46mzSrrOlp3/9EkbNVwe7VQDUQY/L0QQc=; b=UuV8h6iOA940HBxAyCpQBlc2DqLjPehntR8Vw7DSGvZ7GsD2FDjkrgIOZqFNfAIKFlG1TVTUgDFnRTB1KNG4folT6DTtoHOkssaEwkb3tbRoMrLKdlUlDeUl+++vuu6pSQ3naSE0XkoOzHlN7yMAQjNAK6i1DBEP+hfqjejU8qrWBLUJu/MlcZr5+1Hxk7k1xQItjD59QuZorN6muQe58EDxWzyL6t9SubWgju/n2p6SmryJxHSZVF8iHY9BofjV20qeHnpH9q5vaHxNiwR9KJZt3Halr5IXUp9/45zox4desNf24iDZTY0jcRFkG2xGFnryhSSEbrux6Bb7Wyn/mA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=PYvWbov9Jx46mzSrrOlp3/9EkbNVwe7VQDUQY/L0QQc=; b=eZ0p3r97J+jfce5LO8F4pEhn2ef87hf6eQGnHbxXqIqqUV6bL/9XVOEfmrfDk4twfELFhpBP2+y8nyjDWgRmOXumg7lCw+dDm5j4nE9Ag3rDG8aAwqaboMSGObou9fgTkBhDrYd5QpRt81cor7HJJ6dRsjPzeuEOSVS5tvzqZmk= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:57 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:57 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com, Max Reitz Subject: [PATCH v5 07/19] iotest 303: explicit compression type Date: Thu, 23 Dec 2021 17:01:32 +0100 Message-Id: <20211223160144.1097696-8-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: e776a8df-f4fe-4569-764c-08d9c62d8bbf X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:6790; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Tb7qoY37veKY/BO301yWzLuaQpc5E7aIuBbyQEUpoAt0vFbfODA1qEEgL6HZfMZX1mJvSyb9oonH43IjgWvNSYcQp8UZqoyvBmLjDbSoGlCMocC8mBYgjBq0ONdMroMANHi37NrDzC2aunHyuUC0hHT9qh8KJ8D5MBlpdVA2o8Hg93kQlZle+OivLQh/alliwb3rS42/2h1M0MxFYuytuschMjkYV4iciszOGqPjUQanRQnznPVICHsgwnboO5wkefN6/vPdx+1F1RHzKspmC3UhMz0dup+eIZBoSgQhak/0TYUvji0F4ivaHPK25GxLy9nrKOCVO64SKHD/oyqIONVRwJrMfzjg+c/A1UZbvH5zivtnJ9+QnOOWqaR0t6zDEOliKxunMcFoJn1xh01dprLMr03iP1pGSWtACp+6cfADuMDPQ7Mha/jxcAK+0hcXYUxbaIq4XKfxTBXb7GX4lyL3b3H6l4N+iyvQh9Bty30ytYg/7nq2Ud2AciNCBcE2iMKlpAJFogMWDJ+cHVFdka9w1WtJt8bU1HNXLx9x0pvvUD4WhIMekB70SBPI6CzVh5Psmb8cu4wzw3tYNseFC5pNJRs6JzMGFTVVjk63o/lj3XVFd0DQ45mVg1Y1qKiRtZsFuN4RQURvsydmaTwtKUYAq+Nq04UFWRY2xr1d5Zwi3OdKQL27781mHMHg00ORbzDH1ggIZZPN8lv4vp1jgUtOPF9niAJ4VMzBUr8Dw94= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003)(21314003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: alznftK+V9Owbg2uyClsjM6T2N66VeCSVcTlRkJ6nAze4YtIVK/lAndO3yjmqEy3u4yrJIQGdBLVgdtCliMrW+lgcURoJQqFgFhTM+AbFxRU+ic4m2QyWrymzlBwtJ1KD8vZ30kYvoT70TfDEgHd/X/0IDZiryuR9RwytMKNmh1AxoFaTKdu0kSJTen8pXxjcBUvtrwZjp469RNAvEvQETgJtSpURXCti9l+vMyshtBe/8/3ucKMuAT769pX2IJa/PxR2PKvYe9/q1OwBtm/s7WNKWKHNMB/2Pw4jX8DCO3PsE2fEeFCPpxozEuRxHFbE58uzuPRBcy/t87YunO/fAQGk4Zvp0bvWs0xxwzJpizcsU3tkKBWqWNz21lpGamvB+9Jua3yfBs4wM5TvtqbgyTTXuIDy8rHBD+1OWmbe0KA7fDn4ESzBNFG//9NX5UoeCVHV05NvEJbdJB0+1PhH3EhRBD11s9ODr9/pGEnjDRxJTxV6XlBp03LWqbkP9jBvfukOpc/KyTdy4WlNLPNPinmVewVhNMIfWFNSaXfWhArN8M/Xt7BpnaQGxbQ6rQYeLNoY/dlIM4Bv5ZIQNRvOm9WzJWwxeJLtlcrJGttVttXWQ0yW9teRFVW6oSuw0z5aec/XHQMqPJBesx5pPz4y6AG/qp5vQ4F83pReaxvqzJBWT7N3duD09HDf9LWiw3ozMulFLPnj9kXlifL0WNDOoZVPhiPewXtq06oMZwH46svlnVcw1KySfVdlrP+OYBRf9B71qmxMx5pO3XAveJN6q1x8RBOmluVlD9v/DaeYgEfQIMwPwjj5Kxh+zwIQB1wOY1x71TtleJzn3OiLcIUC7+iL3ChMJNoUC43wCP4G9GsYbWazBaa1itkrqBiqdqepl2mc8+bu2kGl333hZ0IQoIPgQjqy6k70LaTaXYjPQS6qfsgW1/7KIgQ/Tp3WJyxUbOJOc2W20uJ46MmXQ2wHE68jn6xZRrOVrYx935ziFEaqZ79uYNCF59f2jIMARCJFR8l0AuS0znWfw5LMLeYCnFlf2OucRIfQyRKiFxO8rmF6VPH2UhAcPVcOhJi4uuzCpIdIAW+KqkUwRw7OoK6EUmqJk7mgaMDAz1N/KIdtQuYDDOpKCeCYmLqb9rKdf514zJAnF43cabCfBqFF4hNaiuVPTIVPVap7V6vrK+pu2ahyr4jJiAxiTtoWp52rRUo0QsACUYnXk78O0o7MkPOUM1246idXIat5hX+XslxcFTric+xEsrfjhuWYU/8crpT356ZVIQq4ioDq0DqiPLtRNrBzT5w2osEKqMed3l0Rru4IqBxHaJl9meU7mHOXonlS49TktcAlx+n0B9q+s2PATHIIMu+8jeX2ZbAdA7n+tfYNEeOCPYppz+xObDLYDPopsMTL/Wx5ELZhOtJ7sb+aiXQ2g2jqs45zjkcf2/cq8l9CwXQ8LRDc3MUIuEqRdt2bNxbVhcnWN22v3Yf2zcxBhbFGmfLX3D9t2VQ8458khXr16JGRoQnubZDTdwYddxh+FpV5HwvdlS0MiAHiUheZwwUcIicCe1VJbn88zs+FYZ9AYkUmbstfh2b6ZlDfLDePKPPJ0t/uNqXFzaMR5TJOgvg3R89GLl0gJEC61I2YrJGI8+xkjMD05H6n9PLnOSpvc0fbuI9AsU4XQtIgpHDTZBsrXMzWbLlX4zPL6YV5bQ= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: e776a8df-f4fe-4569-764c-08d9c62d8bbf X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:57.1138 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 4i9SmImxWrGaODrhgUpl3xIHb3KYCjwUIL3tqjd/IQE4RDm3EobCDcCxMFUyPiiUPVohdlwuRIVCvI5nUfEz9vdxpTbdQCpD7j8LnUXLiBE= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.15.128; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" The test prints qcow2 header fields which depends on chosen compression type. So, let's be explicit in what compression type we want and independent of IMGOPTS. Test both existing compression types. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz --- tests/qemu-iotests/303 | 23 +++++++++++++++-------- tests/qemu-iotests/303.out | 30 +++++++++++++++++++++++++++++- 2 files changed, 44 insertions(+), 9 deletions(-) diff --git a/tests/qemu-iotests/303 b/tests/qemu-iotests/303 index 475cb5428d..16c2e10827 100755 --- a/tests/qemu-iotests/303 +++ b/tests/qemu-iotests/303 @@ -54,12 +54,19 @@ def add_bitmap(num, begin, end, disabled): log('') -qemu_img_create('-f', iotests.imgfmt, disk, '10M') +def test(compression_type: str, json_output: bool) -> None: + qemu_img_create('-f', iotests.imgfmt, + '-o', f'compression_type={compression_type}', + disk, '10M') + add_bitmap(1, 0, 6, False) + add_bitmap(2, 6, 8, True) -add_bitmap(1, 0, 6, False) -add_bitmap(2, 6, 8, True) -dump = ['./qcow2.py', disk, 'dump-header'] -subprocess.run(dump) -# Dump the metadata in JSON format -dump.append('-j') -subprocess.run(dump) + cmd = ['./qcow2.py', disk, 'dump-header'] + if json_output: + cmd.append('-j') + + subprocess.run(cmd) + + +test('zlib', False) +test('zstd', True) diff --git a/tests/qemu-iotests/303.out b/tests/qemu-iotests/303.out index 7c16998587..b3c70827b7 100644 --- a/tests/qemu-iotests/303.out +++ b/tests/qemu-iotests/303.out @@ -80,6 +80,34 @@ extra_data_size 0 Bitmap table type size offset 0 all-zeroes 0 0 +Add bitmap 1 +wrote 1048576/1048576 bytes at offset 0 +1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) + +wrote 1048576/1048576 bytes at offset 1048576 +1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) + +wrote 1048576/1048576 bytes at offset 2097152 +1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) + +wrote 1048576/1048576 bytes at offset 3145728 +1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) + +wrote 1048576/1048576 bytes at offset 4194304 +1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) + +wrote 1048576/1048576 bytes at offset 5242880 +1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) + + +Add bitmap 2 +wrote 1048576/1048576 bytes at offset 6291456 +1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) + +wrote 1048576/1048576 bytes at offset 7340032 +1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) + + { "magic": 1363560955, "version": 3, @@ -94,7 +122,7 @@ Bitmap table type size offset "refcount_table_clusters": 1, "nb_snapshots": 0, "snapshot_offset": 0, - "incompatible_features": 0, + "incompatible_features": 8, "compatible_features": 0, "autoclear_features": 1, "refcount_order": 4, From patchwork Thu Dec 23 16:01:33 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698481 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CA125C433F5 for ; Thu, 23 Dec 2021 16:16:29 +0000 (UTC) Received: from localhost ([::1]:49854 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0QlY-0003Uv-Uz for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:16:28 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43312) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXt-0005ck-AN; Thu, 23 Dec 2021 11:02:21 -0500 Received: from mail-eopbgr150124.outbound.protection.outlook.com ([40.107.15.124]:2176 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXn-0005Js-4P; Thu, 23 Dec 2021 11:02:20 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=E+3WagP3Th+Ddcr0Z+24ekA6XuNN5jJxJcP2KCnurViXIrzUEqDsOSUhX4oG5Fs83eZx7DaSamOTljLGzOawO0P2QM5xx3dSgCLe0YONatzeLSmtThlaZ3gQnwBy8j0MtdbWwbS9Y0xLZtVUboGCCS/ZiWDOCgTSiJl1zd1JGRwQ1peNU6KWgTJccOeRWWXNAuRAD6DnpKMDR/oJlAvoEemKW0Ettu2p0c3tFziQaLjsnWzcGl3Lmx+P1GhE1rna4oANZFzrci6PfbG9cHwPeXKpdOYOa7RjKUseym6+DQCP50cYjfN0XxqMZ/x3ceODYgaWNAkR6wtS9GkKZWIAiA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=JBCv/+yx5YMwBuqUowLPgDaBR0Xcjv3u7XO99Wgdtv4=; b=Lc7KdUxjIFX4BLv7a+qLn6v4xVksCN78mGOXLvAKGeAArKTTW4J8pCU5ghRuKJ2uvZMYFlwrr3JBapDY3KKdtnY2YLRGusaSXzjxi4kcIZcUFhFPxQdROnfOj8HRz0WT6detJHPucOvf/+NcHUeGTFkrlt6biSRg/73jD8x/AfFWxlLuLUcuJWyOSlgEeF3dWBgT6UB9xauPqjwbcqrDDfO180Wa3zGZ4cyaSq+/TFmtuzWcVkFOGg+IWvkzPDgRg+m81NJyDrqUqyZboeIg9oNA3yHHHUwmy2hLUQPaQUaJPTAQR+5uv+qEzl97DWxpXT+PXoVhFXibxBji3NYFUA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=JBCv/+yx5YMwBuqUowLPgDaBR0Xcjv3u7XO99Wgdtv4=; b=F+F3dMMMs1j6jRCHSvsCGCOC1IVeXqPcxn6S3R4gsIYdcezBrgx7CPnhRiql5/Ks28T8Ny82XYzCszDLc0FRELVBz/bMMOMUd1nbDezjkFf1iE87omdQohOiXrQD95Aoq1z6pvC1K7rdIuWN3VziEPGQO3t0IT3mro0itqTfbSU= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:57 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:57 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com Subject: [PATCH v5 08/19] iotest 065: explicit compression type Date: Thu, 23 Dec 2021 17:01:33 +0100 Message-Id: <20211223160144.1097696-9-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 2913bcea-f6ea-468f-e790-08d9c62d8bf3 X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:2887; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: rI4QCvPxHJRkMaCXBphPF5MMvZuncWPcABl2I9ZpcPbTqJKQkz02KFTZyZIKkhcjsAGMzCqX7852LA0CxK/daB24PS1yVTfnFdZxEKWhJJDhbIYDBciLWds1O/LkwnJbqjg386sYbY36EnkSj3K6fQFYOrrtG9Q2I5YshnNcdiJlswC4Dp7Ir5TELUN/kRQEPQkWVAkd07BKiBfFUinCMyWIqXT78VSv2gM2RuB4HJqd2rYqrhfLAcjiaG80x/MAt2qvLocRZ8/ImsdKbGsMqvhKiF7wCanB5p9QVLHm70Yna59sMq42iN9KliZNHaNT/2Q/023XH3FMW7I+CWOaCYZ+bzntE2OIVM1BGIfhNIMRd/hcB3JFDoQ5ohzbtyQ/HQAfHxiTXNz2aRc7lUB77VMtY9RXrdi69XvSemiq2BPcs2EMQUKw09nq90c/sMdHo0U4CnGn8mbF0OYrl15grNWYJPCR3YL1c0hPn/Mg3PecQUjVLiFSKDzdalf2z1gIjb3GDjVLIf4+Flq29KeuAvHaAd5yNnxIov5S7sP/axQxa7pJABJG1LC2IyrALe1yR1ab0bbhnjYr4kII6GzY3F1KxBDsEpzua++lU9dLlR4ElVYdxD14RuvhS+x8m3Oo5mKW2b4dQ4Wlt570/54IVvU+mebkCXHNVGPwzthIYXF6/XqMHtABpQrOqBf95HNThV1Cdl4E42VLnilEmnoRYg== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: qpaYiLRtSfo73oY2lYa6+XI7YmrBVuCs1hPeFy4lGPeECVKvAKjdgaGoxYPfh4FeiEkNzFRMAAx00waLU7QQ4kLSkRQbYFKoemEcyMHDkfKH7qmr4Viwy+bplrG4uWypCVSqxru9kG1ce5wTl7Qw244GloDVI2KvodA2xLYZnT4COwRje83WZIPDly1enZ6FWCraQjvGHuK6shkWuSIud+uesJ6Vg0/a64DeoXg2XypIvLHXMOxpr94SyypgeElnjGwZOfYfuUPFpNAYLnT/kjleLzl4AwMiYyQyXP3C8ArRrBlm88NJnvteGTR6Vmtvn+v2TVHPQCXoPwBj4FKTLwISnP22bDG0AhC4uI70Z5DjSYRbvfP29X0b3KhLPUxhglgcuNBxBRmt0fFEE1s82ihlQTrD9R3m7KXAMOBAFuPp1hWmyzV7NDoj61pxXpsWvwaxp1wM+vlqNzeVtXy2uxkHAjlcLjZN510edenk06BTvr2evcX4je1RRGqURVhbybDu23DxHCUi2/hsKDW8jP3QkiJ/foiS+wrtZC1ry61wM3Ek4fh+HN1EAlWNp4OI5cKmoBs8GsL3quGTzcpDg30+KdSz+dAC4+k0CpwVCfnr6/UXdbqCh/rK7AJHMtKHTLY5ojUXrYekS3dksT09p+IGhgxO63J7RJeN/ctRpOoeorC5l74GpWvS3eoqXZoNCzUYlVg/L8915E+NZfJtjjEiX3IYcTZiC5AkSSrWwc/21P+gR2+2wGse34cqQP+xwf0x8xF+k4txUeWsybZ8JXIOhPh9gyTuIDBp3VctesP/uP1pBZQ/ZDDO/j9DPwuPvtcIl5PDhefmeBTqfkenSLrajpGKZ66oMbhja7jH+SaQlMJw5X/13Ab133YFTYFtJG3dLhDopZq+07CN+mxAUQ9a005WYrklGZh3QXeHHawRBS4cMsEyVbOwNdWvlUDBKksKol9UBtzXQsVIiUdBfwKQAeS8HDjC/7yYQO1h9V7v+CfR8PkKSyO2YtQMOzPydQkSWgBencBFbggggihvdKwA/kCRs7cEnLZbxm3hS5CSEhIvdWRkVNM1RgwQxY99MNyUIx+LKpS6dL/VW+PlY8vYJhDqNQne11Bbg6dWEeJLiHjFg7IXO+Ts8pzIQOskwufDM+OX7Ef1KmrinkMUGKpFV2mZobVZ+IM/3WGEBlJUEHjRfzixLAtaFDHJpRg/PPmjgKWuxc+Jn3urcZsPWMsVD1RrF1LyxFXzxuJ3fLjqa/HIdOS8No+vbK7Yv9xvZtkbXb3H41/Yu49J/7sZYo3io6GURbSe3buNq68w/MfSH4YR3KdV75RrKVcItbtqYRV2wK3cb/jVRuBf3RZ/wXNgbda17QxFw9JveLEBBJfyJXOhiPprIG0DtB5/0mhAIncJCBf9cdqlJXMvF481UvLZv0MesfSdM0N44cRd1Sk58anQCewQVS7tU9LYxESE3iczGoUkhbsGsBFPALTc5ztm/VmzxWvYyURsy4uJwlWZ2W66rvYN7SLD/+CZyYIgYC0fQ/YFurssRvUB939v0Vxj0pVxRMdB0NHFWkiJhNLbOn7rdgElpjhAFrbc9jysFsbKKszXPW/Oz+f7sDYXD0zo6bvdhQnpsCZ6ryeend3UvqgFmKZI8at0lK0+Cz0En5P1s4lhb/izJOgMQJoZ2qo/zzN16ml30g+qcVtLNgo= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2913bcea-f6ea-468f-e790-08d9c62d8bf3 X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:57.4574 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: nvn1AA1N40AqTWtto7eOfKwDGvWdYBHLDrjbUbCUNCLoQ3YHWuQZGmR1slhNIYyUU1ZgjCg5o4cMqBTMhdVWISeXq8MXzxzPzlyCVUxFDR4= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.15.124; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_PASS=-0.001, T_SPF_HELO_TEMPERROR=0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" The test checks different options. It of course fails if set IMGOPTS='compression_type=zstd'. So, let's be explicit in what compression type we want and independent of IMGOPTS. Test both existing compression types. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Hanna Reitz --- tests/qemu-iotests/065 | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/tests/qemu-iotests/065 b/tests/qemu-iotests/065 index dc7716275f..f7c1b68dad 100755 --- a/tests/qemu-iotests/065 +++ b/tests/qemu-iotests/065 @@ -88,7 +88,7 @@ class TestQMP(TestImageInfoSpecific): class TestQCow2(TestQemuImgInfo): '''Testing a qcow2 version 2 image''' - img_options = 'compat=0.10' + img_options = 'compat=0.10,compression_type=zlib' json_compare = { 'compat': '0.10', 'refcount-bits': 16, 'compression-type': 'zlib' } human_compare = [ 'compat: 0.10', 'compression type: zlib', @@ -96,17 +96,17 @@ class TestQCow2(TestQemuImgInfo): class TestQCow3NotLazy(TestQemuImgInfo): '''Testing a qcow2 version 3 image with lazy refcounts disabled''' - img_options = 'compat=1.1,lazy_refcounts=off' + img_options = 'compat=1.1,lazy_refcounts=off,compression_type=zstd' json_compare = { 'compat': '1.1', 'lazy-refcounts': False, 'refcount-bits': 16, 'corrupt': False, - 'compression-type': 'zlib', 'extended-l2': False } - human_compare = [ 'compat: 1.1', 'compression type: zlib', + 'compression-type': 'zstd', 'extended-l2': False } + human_compare = [ 'compat: 1.1', 'compression type: zstd', 'lazy refcounts: false', 'refcount bits: 16', 'corrupt: false', 'extended l2: false' ] class TestQCow3Lazy(TestQemuImgInfo): '''Testing a qcow2 version 3 image with lazy refcounts enabled''' - img_options = 'compat=1.1,lazy_refcounts=on' + img_options = 'compat=1.1,lazy_refcounts=on,compression_type=zlib' json_compare = { 'compat': '1.1', 'lazy-refcounts': True, 'refcount-bits': 16, 'corrupt': False, 'compression-type': 'zlib', 'extended-l2': False } @@ -117,7 +117,7 @@ class TestQCow3Lazy(TestQemuImgInfo): class TestQCow3NotLazyQMP(TestQMP): '''Testing a qcow2 version 3 image with lazy refcounts disabled, opening with lazy refcounts enabled''' - img_options = 'compat=1.1,lazy_refcounts=off' + img_options = 'compat=1.1,lazy_refcounts=off,compression_type=zlib' qemu_options = 'lazy-refcounts=on' compare = { 'compat': '1.1', 'lazy-refcounts': False, 'refcount-bits': 16, 'corrupt': False, @@ -127,11 +127,11 @@ class TestQCow3NotLazyQMP(TestQMP): class TestQCow3LazyQMP(TestQMP): '''Testing a qcow2 version 3 image with lazy refcounts enabled, opening with lazy refcounts disabled''' - img_options = 'compat=1.1,lazy_refcounts=on' + img_options = 'compat=1.1,lazy_refcounts=on,compression_type=zstd' qemu_options = 'lazy-refcounts=off' compare = { 'compat': '1.1', 'lazy-refcounts': True, 'refcount-bits': 16, 'corrupt': False, - 'compression-type': 'zlib', 'extended-l2': False } + 'compression-type': 'zstd', 'extended-l2': False } TestImageInfoSpecific = None TestQemuImgInfo = None From patchwork Thu Dec 23 16:01:34 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698480 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id BF782C433EF for ; Thu, 23 Dec 2021 16:16:00 +0000 (UTC) Received: from localhost ([::1]:48560 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0Ql5-0002bU-NS for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:15:59 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43356) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXv-0005lt-MH; Thu, 23 Dec 2021 11:02:23 -0500 Received: from mail-eopbgr150128.outbound.protection.outlook.com ([40.107.15.128]:32197 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXs-0005La-9N; Thu, 23 Dec 2021 11:02:23 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jCwJZZarBlw0DwhfacPMG+KAUUs70RxwN+HQAuNxHmiAcDqRFnLMZpnuRXNcN2E69okYWGdvX2W0D76k801XbehQ7dqu4bDdJZ8k3w0HjCFQb8o6vgNAEDDZ/5pXDXqBmc1i2Ck1eca715G5cb/S6/tDUObVuKY1WvxtdWzrcIrz/wu550WvujVaZb7kiI4IgJBAZlidnKYznDnfYT9V3Q/2iGmLY/EDsDVnNtyl9nv/Xznzh5MfzseoH3oFliNX5XtQ94PQ1bYSPLmSjaB2HT/Li5c6ccZc9t0BowauHt51r/F71rm5r4wtEcppJnzQIg3KIQgb2mjEc5ZQpaGBCg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=K4yY/cTfJ6ANnVhv7UxkDR3Yy8k1VYZhqmNFWNMFZS4=; b=eAlB5dks/o2SYslPobyGxSWAGL5WzYAmcYMcNgLtrTJCInmn1n4vWoWH6IvquzfO7tFccaZsoXWHkxATHGcjUfv2toSxgmZUsDBkjeCZlhZPdoDjfHbZmh2qDY7uVYIIBVCtaL//hWfMuskPZb91Dzp2Z63wFlnjEz3T1dU5iYeARYBTPBiwfu4o/SWkv7RaUpyVeiUY7/ujDzqQgvu3iCs8G7QGgerQGHqXyhaIisutrw2/hEISpArKYjT5OfdLMnVjp70WYWKXO9bVLALqmnzzoRXkBY7Xqka40dpaA0R4hOkqlsSZ0dkxge0bOTsXWYCP9qyzjqYGFDmeLKrbTw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=K4yY/cTfJ6ANnVhv7UxkDR3Yy8k1VYZhqmNFWNMFZS4=; b=Qwfaz5ZnRbThroTQrZC0tc+/ms2fChUFjBhERowj21hQ8hLwO67xFGM8ZfQ0q+D2UwQBpOHznWf/AbQ4PCms/27QpoPuw/MAAW1oqg1SBTNImAigN4qLY4DgtkDsgoN7Tn57m970B3l2x51jhU2XFmdDiKhWiOYwnu/tLSGOEk4= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:58 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:57 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com Subject: [PATCH v5 09/19] iotests.py: filter out successful output of qemu-img create Date: Thu, 23 Dec 2021 17:01:34 +0100 Message-Id: <20211223160144.1097696-10-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 0fec5f8b-b1d7-4ccb-e1d3-08d9c62d8c31 X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:42; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: JT+IDtBS5zAkoOVgaj+2XUlFRByeCD2D0uJGBTs0Wqd5cg/5Btg0mF/ezKfeQBrn0N+nUvkFNwjT5A/nqwnxX4qz7vbc9rDEf6NIulN39uFDsNOYtyU6ioRpGETcujhHvIHnQH8tjNapoVAQ5rkRM05e0On1bk0CoheNMUQiQ/pwThAlXZHGXdf+wyWSeJ1NtEO+AOsSJs67Hgx9L7UXlv8d4u+8swNFb8nTvGocFVz+SxkB8txVIVzfcuSJkBLAMRGwYq4NtVTGX/HsyKUCnYWWh6qUMO+/FsU5hy0wpEObQMUQKfU/1TSmj67Kk+GwBMfzb8wX2mhGCMRX99b5cmFwMFeWkR3uCTySVcosZCOgBFPfQ3eF+zGRuouQn1Tn5EBoITjMt6WzX1sZmg7o4EyYGDbaTUQ0xdcRQrsh0Rr4nmNNZhJmnxVKqAOKiGnvJ6yU30L1aKZTY4DFWKZIxGQ1ma9PMYj+hHtnhtC+FBkJaFYMqKojXHPB5/GoDPsFGcUy+XOYzmUyyq4F9v1I+A/ltQCIvneUXttpKa8fnraaLP0RPXh0SFMDw5jo6Ib7ebBuvUebPEnZYKKOq16ZxwIJH74KjwXsyIAvNKBIxAQu2sMFpKudEP6bPXHw5mR4H1nwxh7fy8CA4usLFSHuV9YbTBPgbC4pHQzHU1gm9XRt9AY8jlaP67/P0/DJwM8AD3wW7cbCPNQkIfGAwoUPdfdf/zP47L7vm+/uDL4vhy8= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(30864003)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003)(21314003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: NhDkXABA1p9RNxzZ4ec/pUEOPgo6PGxxC0HriJVNj3xZ1/bD3hgNv2nl0tyiP3aEKYDNkK/8i/f/2yvCm0EGjchyatdoOwMXV8jG3wPYzjExwSRQFWMkZFXiDOagonchDKgEYMNpunm3Ce6bcx0Zqd1FGO3H1QOWwqHSu7OTXmN7eSzOyfPE2g1a5wyVOHB8uzUGQnd4wAHkvts1qKePM/WXMW0Bu/CuCnatGCW/bFIYOf5otJucQrSzOPZzNpm+Tfj65zZNUwsNO1AlmJ25ADiVqiTEKnkUBtKWOoZSwu0jzWpan7ExC4Q5M5X6MCKiJK/c1QyQjSoru2tpLgHH/tKbA2th4P3uz18Pn0ObVnPtCzGttggAUKgvY5zkNND+5VVUXfBk7Jv42vxCzrbF6dEim5rYOJfWxwkv6PPf87who35XCQyLIbJnVpBdVV9l95ZurhxMejTY1rJBDmQ3awnj9H9O3Hi4qtPheBxMX8eDp6YX7huPaVHax5jb+w5EGNMy3yYv2wGJCnwGRgd6Sv55VUHEgx1v5yxJ++0Jx7wAXnVnQCzPGkJbeb6X/KQbDbitIcKCHwV180EH/w8470zw+ar4+MluXCorxeLxlYAjqR9LYNJN3CvkVBKAmGRpX9FVJh2hQyoXRIDJNwZbIIAbTXUXNhl0x1B81LnibvbA5ArZxpTH/SahLyXE3r2AAJpsAmrzuIk5iZpwVN8oVZqmN0wUIgSZS0dVRBngpA0Ct/Ra71ivGoaCq7Cz7G+Pvwjj13MzTbNBomFm1Vdd5SOYfhIvY/c1WaiBvoExhl4amgN5ZwOGBiV7bQLNGHCF80hNqHp2MeCr6lssS3NRf5bqrc27+LAh4pqc34Ho3ts8t3czUU6RvdSY1AmPo5VwL7Z3gZV7QaQM0SIrFVI4Hflx0jSYC5+E5ZwDBc43fa7w9nIetcc/Z9XYNkisAM/Vi3/8OTumSzo9aIjlZZVcvEpNBz5C+xWYJ2Ng5g8vDgaCUEQtOd8vOhc5G3aNJwGzfrIlmGFY9P+T5LUSTsQRHPBuhHHX0W/Uq+cXYmHkVC3oTRBSnJYRkav87yUVxc13xAq+P6NvbMuv3UaG04aQWktRVNPoXiKGwB4DGbWwrS7rFs/Tu5/bzcz7J9lxxLmaIO/N/t/8W5u4tpbKvJKMcN3tNn5KyPlDZncVBHVdOnhkMgvDEg33ijdU+1i//zTY/gtueJbJmDNWVYd5VoOuAf2amKoz/wgyvKCYu/RCkQq8yehbPwfQnAUHJdOyNiFqlKt9m+Xjwjeyp/fVFtc2jQ9Yw/4NiC4AwSJOLXROlzjz8RdqOMaDSSEMXv3GfLVaqsj6uKDD/aGeqvj87DQ4RcJpSYd1IipCaY7QMzqr4WJAmZe7mJxujQp0n6yydwp454A9hzEmYqnMmROpgG59JIK7vDbycM9HQIyfuU3JTCJyD4oRclouru2+AOSfVKTieBvE8SRN75UHpl2Th2TPaA7nVc6X4UsefnBG34KZxXpjD330Auht6TsXyybVUoEOzbxVhMj2+XoMzRVWimaVb+9Uq4DWJxqhAy5f9yDJsfXlEyWFUYLnrnnN9L3d4H4bVOcxAu7ov8zSsyGI8O0JacmvCYSvLyr/qqYEJGY1KJlnYvYDyPPd1lyoFx4tlMDEKletLbut9NK1V6at4VeOcbwwoOpusSJE7x8o3j35wcY= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0fec5f8b-b1d7-4ccb-e1d3-08d9c62d8c31 X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:57.8949 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: DtT7aPFKanGYrxFkoZ9ZGAl3vW6sl3oR8DWpEd9YOFxVtDA6NsSiMtUGws9qWmzlkh/XtLeglu6lTHRnz4Fj/0shd+KMywLMbFOsq4r45sA= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.15.128; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" The only "feature" of this "Formatting ..." line is that we have to update it every time we add new option. Let's drop it. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Hanna Reitz --- tests/qemu-iotests/149.out | 21 --------------------- tests/qemu-iotests/237.out | 3 --- tests/qemu-iotests/255.out | 4 ---- tests/qemu-iotests/274.out | 29 ----------------------------- tests/qemu-iotests/280.out | 1 - tests/qemu-iotests/296.out | 10 +++------- tests/qemu-iotests/iotests.py | 10 ++++++++-- 7 files changed, 11 insertions(+), 67 deletions(-) diff --git a/tests/qemu-iotests/149.out b/tests/qemu-iotests/149.out index 6877ab6c4a..ab879596ce 100644 --- a/tests/qemu-iotests/149.out +++ b/tests/qemu-iotests/149.out @@ -61,7 +61,6 @@ unlink TEST_DIR/luks-aes-256-xts-plain64-sha1.img # ================= qemu-img aes-256-xts-plain64-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha1 TEST_DIR/luks-aes-256-xts-plain64-sha1.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-xts-plain64-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-xts-plain64-sha1.img qiotest-145-aes-256-xts-plain64-sha1 @@ -181,7 +180,6 @@ unlink TEST_DIR/luks-twofish-256-xts-plain64-sha1.img # ================= qemu-img twofish-256-xts-plain64-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=twofish-256,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha1 TEST_DIR/luks-twofish-256-xts-plain64-sha1.img 4194304M -Formatting 'TEST_DIR/luks-twofish-256-xts-plain64-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=twofish-256 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-twofish-256-xts-plain64-sha1.img qiotest-145-twofish-256-xts-plain64-sha1 @@ -301,7 +299,6 @@ unlink TEST_DIR/luks-serpent-256-xts-plain64-sha1.img # ================= qemu-img serpent-256-xts-plain64-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=serpent-256,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha1 TEST_DIR/luks-serpent-256-xts-plain64-sha1.img 4194304M -Formatting 'TEST_DIR/luks-serpent-256-xts-plain64-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=serpent-256 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-serpent-256-xts-plain64-sha1.img qiotest-145-serpent-256-xts-plain64-sha1 @@ -421,7 +418,6 @@ unlink TEST_DIR/luks-cast5-128-cbc-plain64-sha1.img # ================= qemu-img cast5-128-cbc-plain64-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=cast5-128,cipher-mode=cbc,ivgen-alg=plain64,hash-alg=sha1 TEST_DIR/luks-cast5-128-cbc-plain64-sha1.img 4194304M -Formatting 'TEST_DIR/luks-cast5-128-cbc-plain64-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=cast5-128 cipher-mode=cbc ivgen-alg=plain64 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-cast5-128-cbc-plain64-sha1.img qiotest-145-cast5-128-cbc-plain64-sha1 @@ -542,7 +538,6 @@ unlink TEST_DIR/luks-aes-256-cbc-plain-sha1.img # ================= qemu-img aes-256-cbc-plain-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=cbc,ivgen-alg=plain,hash-alg=sha1 TEST_DIR/luks-aes-256-cbc-plain-sha1.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-cbc-plain-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=cbc ivgen-alg=plain hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-cbc-plain-sha1.img qiotest-145-aes-256-cbc-plain-sha1 @@ -662,7 +657,6 @@ unlink TEST_DIR/luks-aes-256-cbc-plain64-sha1.img # ================= qemu-img aes-256-cbc-plain64-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=cbc,ivgen-alg=plain64,hash-alg=sha1 TEST_DIR/luks-aes-256-cbc-plain64-sha1.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-cbc-plain64-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=cbc ivgen-alg=plain64 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-cbc-plain64-sha1.img qiotest-145-aes-256-cbc-plain64-sha1 @@ -782,7 +776,6 @@ unlink TEST_DIR/luks-aes-256-cbc-essiv-sha256-sha1.img # ================= qemu-img aes-256-cbc-essiv-sha256-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=cbc,ivgen-alg=essiv,hash-alg=sha1,ivgen-hash-alg=sha256 TEST_DIR/luks-aes-256-cbc-essiv-sha256-sha1.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-cbc-essiv-sha256-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=cbc ivgen-alg=essiv ivgen-hash-alg=sha256 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-cbc-essiv-sha256-sha1.img qiotest-145-aes-256-cbc-essiv-sha256-sha1 @@ -902,7 +895,6 @@ unlink TEST_DIR/luks-aes-256-xts-essiv-sha256-sha1.img # ================= qemu-img aes-256-xts-essiv-sha256-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=xts,ivgen-alg=essiv,hash-alg=sha1,ivgen-hash-alg=sha256 TEST_DIR/luks-aes-256-xts-essiv-sha256-sha1.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-xts-essiv-sha256-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=xts ivgen-alg=essiv ivgen-hash-alg=sha256 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-xts-essiv-sha256-sha1.img qiotest-145-aes-256-xts-essiv-sha256-sha1 @@ -1022,7 +1014,6 @@ unlink TEST_DIR/luks-aes-128-xts-plain64-sha256-sha1.img # ================= qemu-img aes-128-xts-plain64-sha256-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-128,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha1 TEST_DIR/luks-aes-128-xts-plain64-sha256-sha1.img 4194304M -Formatting 'TEST_DIR/luks-aes-128-xts-plain64-sha256-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-128 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-128-xts-plain64-sha256-sha1.img qiotest-145-aes-128-xts-plain64-sha256-sha1 @@ -1142,7 +1133,6 @@ unlink TEST_DIR/luks-aes-192-xts-plain64-sha256-sha1.img # ================= qemu-img aes-192-xts-plain64-sha256-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-192,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha1 TEST_DIR/luks-aes-192-xts-plain64-sha256-sha1.img 4194304M -Formatting 'TEST_DIR/luks-aes-192-xts-plain64-sha256-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-192 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-192-xts-plain64-sha256-sha1.img qiotest-145-aes-192-xts-plain64-sha256-sha1 @@ -1262,7 +1252,6 @@ unlink TEST_DIR/luks-twofish-128-xts-plain64-sha1.img # ================= qemu-img twofish-128-xts-plain64-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=twofish-128,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha1 TEST_DIR/luks-twofish-128-xts-plain64-sha1.img 4194304M -Formatting 'TEST_DIR/luks-twofish-128-xts-plain64-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=twofish-128 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-twofish-128-xts-plain64-sha1.img qiotest-145-twofish-128-xts-plain64-sha1 @@ -1383,7 +1372,6 @@ unlink TEST_DIR/luks-serpent-128-xts-plain64-sha1.img # ================= qemu-img serpent-128-xts-plain64-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=serpent-128,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha1 TEST_DIR/luks-serpent-128-xts-plain64-sha1.img 4194304M -Formatting 'TEST_DIR/luks-serpent-128-xts-plain64-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=serpent-128 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-serpent-128-xts-plain64-sha1.img qiotest-145-serpent-128-xts-plain64-sha1 @@ -1503,7 +1491,6 @@ unlink TEST_DIR/luks-serpent-192-xts-plain64-sha1.img # ================= qemu-img serpent-192-xts-plain64-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=serpent-192,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha1 TEST_DIR/luks-serpent-192-xts-plain64-sha1.img 4194304M -Formatting 'TEST_DIR/luks-serpent-192-xts-plain64-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=serpent-192 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-serpent-192-xts-plain64-sha1.img qiotest-145-serpent-192-xts-plain64-sha1 @@ -1625,7 +1612,6 @@ unlink TEST_DIR/luks-aes-256-xts-plain64-sha224.img # ================= qemu-img aes-256-xts-plain64-sha224 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha224 TEST_DIR/luks-aes-256-xts-plain64-sha224.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-xts-plain64-sha224.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha224 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-xts-plain64-sha224.img qiotest-145-aes-256-xts-plain64-sha224 @@ -1745,7 +1731,6 @@ unlink TEST_DIR/luks-aes-256-xts-plain64-sha256.img # ================= qemu-img aes-256-xts-plain64-sha256 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha256 TEST_DIR/luks-aes-256-xts-plain64-sha256.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-xts-plain64-sha256.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha256 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-xts-plain64-sha256.img qiotest-145-aes-256-xts-plain64-sha256 @@ -1865,7 +1850,6 @@ unlink TEST_DIR/luks-aes-256-xts-plain64-sha384.img # ================= qemu-img aes-256-xts-plain64-sha384 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha384 TEST_DIR/luks-aes-256-xts-plain64-sha384.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-xts-plain64-sha384.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha384 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-xts-plain64-sha384.img qiotest-145-aes-256-xts-plain64-sha384 @@ -1985,7 +1969,6 @@ unlink TEST_DIR/luks-aes-256-xts-plain64-sha512.img # ================= qemu-img aes-256-xts-plain64-sha512 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=xts,ivgen-alg=plain64,hash-alg=sha512 TEST_DIR/luks-aes-256-xts-plain64-sha512.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-xts-plain64-sha512.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=xts ivgen-alg=plain64 hash-alg=sha512 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-xts-plain64-sha512.img qiotest-145-aes-256-xts-plain64-sha512 @@ -2105,7 +2088,6 @@ unlink TEST_DIR/luks-aes-256-xts-plain64-ripemd160.img # ================= qemu-img aes-256-xts-plain64-ripemd160 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=xts,ivgen-alg=plain64,hash-alg=ripemd160 TEST_DIR/luks-aes-256-xts-plain64-ripemd160.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-xts-plain64-ripemd160.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=xts ivgen-alg=plain64 hash-alg=ripemd160 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-xts-plain64-ripemd160.img qiotest-145-aes-256-xts-plain64-ripemd160 @@ -2299,7 +2281,6 @@ unlink TEST_DIR/luks-aes-256-xts-plain-sha1-pwallslots.img # ================= qemu-img aes-256-xts-plain-sha1-pwallslots ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=c2xvdDE=,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=xts,ivgen-alg=plain,hash-alg=sha1 TEST_DIR/luks-aes-256-xts-plain-sha1-pwallslots.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-xts-plain-sha1-pwallslots.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=xts ivgen-alg=plain hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-xts-plain-sha1-pwallslots.img qiotest-145-aes-256-xts-plain-sha1-pwallslots @@ -2419,7 +2400,6 @@ unlink TEST_DIR/luks-aes-256-cbc-essiv-auto-sha1.img # ================= qemu-img aes-256-cbc-essiv-auto-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=cbc,ivgen-alg=essiv,hash-alg=sha1 TEST_DIR/luks-aes-256-cbc-essiv-auto-sha1.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-cbc-essiv-auto-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=cbc ivgen-alg=essiv hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-cbc-essiv-auto-sha1.img qiotest-145-aes-256-cbc-essiv-auto-sha1 @@ -2539,7 +2519,6 @@ unlink TEST_DIR/luks-aes-256-cbc-plain64-sha256-sha1.img # ================= qemu-img aes-256-cbc-plain64-sha256-sha1 ================= # Create image qemu-img create -f luks --object secret,id=sec0,data=MTIzNDU2,format=base64 -o key-secret=sec0,iter-time=10,cipher-alg=aes-256,cipher-mode=cbc,ivgen-alg=plain64,hash-alg=sha1,ivgen-hash-alg=sha256 TEST_DIR/luks-aes-256-cbc-plain64-sha256-sha1.img 4194304M -Formatting 'TEST_DIR/luks-aes-256-cbc-plain64-sha256-sha1.img', fmt=luks size=4398046511104 key-secret=sec0 cipher-alg=aes-256 cipher-mode=cbc ivgen-alg=plain64 ivgen-hash-alg=sha256 hash-alg=sha1 iter-time=10 # Open dev sudo cryptsetup -q -v luksOpen TEST_DIR/luks-aes-256-cbc-plain64-sha256-sha1.img qiotest-145-aes-256-cbc-plain64-sha256-sha1 diff --git a/tests/qemu-iotests/237.out b/tests/qemu-iotests/237.out index 2f09ff5512..aeb9724492 100644 --- a/tests/qemu-iotests/237.out +++ b/tests/qemu-iotests/237.out @@ -129,11 +129,8 @@ Job failed: Cannot find device='this doesn't exist' nor node-name='this doesn't === Other subformats === -Formatting 'TEST_DIR/PID-t.vmdk.1', fmt=vmdk size=0 compat6=off hwversion=undefined -Formatting 'TEST_DIR/PID-t.vmdk.2', fmt=vmdk size=0 compat6=off hwversion=undefined -Formatting 'TEST_DIR/PID-t.vmdk.3', fmt=vmdk size=0 compat6=off hwversion=undefined == Missing extent == diff --git a/tests/qemu-iotests/255.out b/tests/qemu-iotests/255.out index 33b7f22de3..11a05a5213 100644 --- a/tests/qemu-iotests/255.out +++ b/tests/qemu-iotests/255.out @@ -3,9 +3,7 @@ Finishing a commit job with background reads === Create backing chain and start VM === -Formatting 'TEST_DIR/PID-t.qcow2.mid', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=134217728 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-t.qcow2', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=134217728 lazy_refcounts=off refcount_bits=16 === Start background read requests === @@ -23,9 +21,7 @@ Closing the VM while a job is being cancelled === Create images and start VM === -Formatting 'TEST_DIR/PID-src.qcow2', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=134217728 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-dst.qcow2', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=134217728 lazy_refcounts=off refcount_bits=16 wrote 1048576/1048576 bytes at offset 0 1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) diff --git a/tests/qemu-iotests/274.out b/tests/qemu-iotests/274.out index 16a95a4850..1d2928e14d 100644 --- a/tests/qemu-iotests/274.out +++ b/tests/qemu-iotests/274.out @@ -1,9 +1,6 @@ == Commit tests == -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=2097152 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-mid', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=1048576 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=2097152 backing_file=TEST_DIR/PID-mid backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 2097152/2097152 bytes at offset 0 2 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) @@ -66,11 +63,8 @@ read 1048576/1048576 bytes at offset 1048576 1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) === Testing HMP commit (top -> mid) === -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=2097152 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-mid', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=1048576 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=2097152 backing_file=TEST_DIR/PID-mid backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 2097152/2097152 bytes at offset 0 2 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) @@ -98,11 +92,8 @@ read 1048576/1048576 bytes at offset 1048576 1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) === Testing QMP active commit (top -> mid) === -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=2097152 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-mid', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=1048576 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=2097152 backing_file=TEST_DIR/PID-mid backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 2097152/2097152 bytes at offset 0 2 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) @@ -136,11 +127,8 @@ read 1048576/1048576 bytes at offset 1048576 1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) === Testing qemu-img commit (top -> base) === -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=2097152 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-mid', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=1048576 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=2097152 backing_file=TEST_DIR/PID-mid backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 2097152/2097152 bytes at offset 0 2 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) @@ -166,11 +154,8 @@ read 1048576/1048576 bytes at offset 1048576 1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) === Testing QMP active commit (top -> base) === -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=2097152 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-mid', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=1048576 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=2097152 backing_file=TEST_DIR/PID-mid backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 2097152/2097152 bytes at offset 0 2 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) @@ -205,9 +190,7 @@ read 1048576/1048576 bytes at offset 1048576 == Resize tests == === preallocation=off === -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=6442450944 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=1073741824 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 65536/65536 bytes at offset 5368709120 64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) @@ -224,9 +207,7 @@ read 65536/65536 bytes at offset 5368709120 { "start": 1073741824, "length": 7516192768, "depth": 0, "present": true, "zero": true, "data": false}] === preallocation=metadata === -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=34359738368 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=32212254720 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 65536/65536 bytes at offset 33285996544 64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) @@ -248,9 +229,7 @@ read 65536/65536 bytes at offset 33285996544 { "start": 34896609280, "length": 536870912, "depth": 0, "present": true, "zero": true, "data": false, "offset": 2685075456}] === preallocation=falloc === -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=10485760 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=5242880 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 65536/65536 bytes at offset 9437184 64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) @@ -267,9 +246,7 @@ read 65536/65536 bytes at offset 9437184 { "start": 5242880, "length": 10485760, "depth": 0, "present": true, "zero": false, "data": true, "offset": 327680}] === preallocation=full === -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=16777216 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=8388608 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 65536/65536 bytes at offset 11534336 64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) @@ -286,9 +263,7 @@ read 65536/65536 bytes at offset 11534336 { "start": 8388608, "length": 4194304, "depth": 0, "present": true, "zero": false, "data": true, "offset": 327680}] === preallocation=off === -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=393216 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=259072 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 65536/65536 bytes at offset 259072 64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) @@ -306,9 +281,7 @@ read 65536/65536 bytes at offset 259072 { "start": 262144, "length": 262144, "depth": 0, "present": true, "zero": true, "data": false}] === preallocation=off === -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=409600 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=262144 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 65536/65536 bytes at offset 344064 64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) @@ -325,9 +298,7 @@ read 65536/65536 bytes at offset 344064 { "start": 262144, "length": 262144, "depth": 0, "present": true, "zero": true, "data": false}] === preallocation=off === -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=524288 lazy_refcounts=off refcount_bits=16 -Formatting 'TEST_DIR/PID-top', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=262144 backing_file=TEST_DIR/PID-base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16 wrote 65536/65536 bytes at offset 446464 64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) diff --git a/tests/qemu-iotests/280.out b/tests/qemu-iotests/280.out index 09a0f1a7cb..e39164c579 100644 --- a/tests/qemu-iotests/280.out +++ b/tests/qemu-iotests/280.out @@ -1,4 +1,3 @@ -Formatting 'TEST_DIR/PID-base', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=67108864 lazy_refcounts=off refcount_bits=16 === Launch VM === Enabling migration QMP events on VM... diff --git a/tests/qemu-iotests/296.out b/tests/qemu-iotests/296.out index 6c69735604..42205cc981 100644 --- a/tests/qemu-iotests/296.out +++ b/tests/qemu-iotests/296.out @@ -1,4 +1,3 @@ -Formatting 'TEST_DIR/test.img', fmt=luks size=1048576 key-secret=keysec0 iter-time=10 {"execute": "job-dismiss", "arguments": {"id": "job0"}} {"return": {}} @@ -13,8 +12,7 @@ Job failed: Failed to get shared "consistent read" lock qemu-img: Failed to get shared "consistent read" lock Is another process using the image [TEST_DIR/test.img]? -.Formatting 'TEST_DIR/test.img', fmt=luks size=1048576 key-secret=keysec0 iter-time=10 - +. Job failed: Block node is read-only {"execute": "job-dismiss", "arguments": {"id": "job0"}} {"return": {}} @@ -26,12 +24,10 @@ Job failed: Failed to get shared "consistent read" lock {"return": {}} {"execute": "job-dismiss", "arguments": {"id": "job0"}} {"return": {}} -.Formatting 'TEST_DIR/test.img', fmt=luks size=1048576 key-secret=keysec0 iter-time=10 - +. {"return": {}} {"error": {"class": "GenericError", "desc": "Failed to get \"write\" lock"}} -.Formatting 'TEST_DIR/test.img', fmt=luks size=1048576 key-secret=keysec0 iter-time=10 - +. {"return": {}} {"return": {}} . diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py index f424e04573..4bb740634d 100644 --- a/tests/qemu-iotests/iotests.py +++ b/tests/qemu-iotests/iotests.py @@ -140,7 +140,9 @@ def unarchive_sample_image(sample, fname): def qemu_tool_pipe_and_status(tool: str, args: Sequence[str], - connect_stderr: bool = True) -> Tuple[str, int]: + connect_stderr: bool = True, + drop_successful_output: bool = False) \ + -> Tuple[str, int]: """ Run a tool and return both its output and its exit code """ @@ -152,6 +154,8 @@ def qemu_tool_pipe_and_status(tool: str, args: Sequence[str], cmd = ' '.join(args) sys.stderr.write(f'{tool} received signal \ {-subp.returncode}: {cmd}\n') + if drop_successful_output and subp.returncode == 0: + output = '' return (output, subp.returncode) def qemu_img_create_prepare_args(args: List[str]) -> List[str]: @@ -196,8 +200,10 @@ def qemu_img_pipe_and_status(*args: str) -> Tuple[str, int]: """ Run qemu-img and return both its output and its exit code """ + is_create = bool(args and args[0] == 'create') full_args = qemu_img_args + qemu_img_create_prepare_args(list(args)) - return qemu_tool_pipe_and_status('qemu-img', full_args) + return qemu_tool_pipe_and_status('qemu-img', full_args, + drop_successful_output=is_create) def qemu_img(*args: str) -> int: '''Run qemu-img and return the exit code''' From patchwork Thu Dec 23 16:01:35 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698474 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 109E6C433F5 for ; Thu, 23 Dec 2021 16:10:03 +0000 (UTC) Received: from localhost ([::1]:60908 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0QfL-0008Tf-1c for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:10:03 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43322) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXu-0005fJ-3X; Thu, 23 Dec 2021 11:02:22 -0500 Received: from mail-eopbgr70094.outbound.protection.outlook.com ([40.107.7.94]:61158 helo=EUR04-HE1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXo-0005KZ-Rp; Thu, 23 Dec 2021 11:02:21 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kfI1ggC4Yjd8cgj5xxM0tNj5tVWE30hNDUBbfz0Sp2DGJlykpcdLl9gTpXNTvSE5HQh6YOSm80W0aM3AT+luVbPS+VAAQK3Q0TKSPDohlDYks1i4oFxpihT7yTr21v96XVae1XpWtBfOae8KQ7bIAVBgEQ4hSuVeSbnR22eN7kIILHLvk12Kfj0Hqk0IXZGT5DdFNjPGI+wTvOz2cjq0CobQ5DmjsaQ4+rNC/eJ37IoTl+osfFCn/Ugh0/SBJzwpZtQThylbngtxP1Y6yPbYAvCPkHTKO2dcfrHXagg3OCkClpYzr2GLFbrq4nuyMgEkhuIfuHTEQHKvwApGiNoZsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=rjQCHljwpc8KaOozU1GtqFJZ/wxePith2kFAjsp3U+s=; b=Rptfrw1QbkdZh3my8f3xEG95AVzHmFyNH8FgEH+JSGCC2HexUbaFdoK2t/s8WMhbegGll6criA3ILkTsqaUaAof6D1fA2HR7DPTwbFSyo0cfuWpI7JZ/8eA2WNoBkHgUG2g3I8WfxAxDT4yzdQ17FHfYu2RCiaN4eyUo6Y3F2n/mNVQP7g+oasnt5nhAi9Yik6yzzy3hyNWIXXOld5+AY3seju/D+g6SJx5g0bZt98EVAVIwn5fuw/3aKwdobD5HZIVYOLjjycqNKt6g/znzvJ80ZU0QpEEovKNaEv6jh+0N1ffRWDuuD8b0pKQi0sEYvSWhv8PUMahmxX25SFO07g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=rjQCHljwpc8KaOozU1GtqFJZ/wxePith2kFAjsp3U+s=; b=Dv7oa6UItTSfT4unvOm99vpZ7S1hv/vs6PsOdVeILv9Bz51Jj0KU6ZesuP9/8ca2HcJIk2lFItGabbPPXhMx7XLcnUX6IlrxFGxCNFgiFaCMJQzD3RPnRDmHGtT50Zu5h0e8jweT8WjnLJIpnXQPtp7zwYWIG0YP9qM7ezjAgyg= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:58 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:58 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com Subject: [PATCH v5 10/19] iotests.py: filter compression type out Date: Thu, 23 Dec 2021 17:01:35 +0100 Message-Id: <20211223160144.1097696-11-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 657eeb9c-0565-48ed-79e1-08d9c62d8c6d X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:4941; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: PqS9qE1njY8U8z+ZR6YIKZjE0UDLIhSmfgmgzG2nMfuyXxanqjTz/QQGbtMRKywX/W66HejcdAqDo3npplakI8mNgrXb4BG3s3vVw+GWa2qr5JeM4SeWauRKdaA91FxJIdvWtlaB5n/X9gzTJzDn5qyi5cz2N3IzSZLVpR56JFeTKFzwcmdMCV5zEubVi9thu6r/KhZbd5vhADuByoRFRcSTe4nRdl3hiFanWielsObnKBXWtWoRapabHzHwO3iGCLp24Xk1chTlXptAdbck7Zu05oUdSAaypKPxjsvQ21oOOeTrGMzhm0PoS5tVjjBFVAj+gVO12DiqM1+EA87pjJO2zNxHi1UXWfKf/EyS9GDAm7xHEzrL6rwyJH2Hu5CTYQNjfsY1UWvyzBtlmJBHtkOciUyxRt185WR9TA4I5MjFCE9VG9YYAesqLrjY2HBsM7TdaFYemo5TFAYPZUJW0QouvtT15CMc7nZjuLPVOKEdybPVf5LMOyHkd2lyUyN4MqKAXOoZlfr5jxDc47kNLN/IiXynLwjOkPhSXlJSP2rXbWA8LUWE2CSyIA4JuAxTce9kwbjpjy4lWxeyzey0iEPaTrnxebs4KCcSBz3FNkgGQOfpB5BXyqRcClyWE2RhF64EhZERnDNnNiAvP25LL5Gop5cstBfRq1k09aK1g/mF4jnBwwxVTx9Pu4OB9K58cn9L4AMWzlafk5J0cbWqYg== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: Nzbtkvk4V/35vzXVlbt7IABzCEgD0lESNTSCw6bTelIQEythtLw+LYilUTT0+LVO9uTQFQKsnUybxiH8s+IU518+Lr/Rhw9ZKyeICeiS/lErbswZnnvLuSeCEK5GIf/AQZLXV906XQxi3kQs3DkQjCq4SI24IfQ7tfHz9CVobkpiVVlVbw3UI0P+oSk6l6yKEkWpTzGGPZbDddqvx/6UJECpXdjz46fqWPM3sMlaJs4XoO82ZMepavNqNXc0PyaazNUiPggTOeCNA/o2ye3IdLRbA9mhd44ECzSRBWsf02JGtI/pUUkzFoUsBGKiaRe5oQhnlHfKxGc/+VsRdMpPNWvhTWDpSlIpayJWwmAASF3Jv6FXaHtHoiiF35+HRMx8h4lJZ2gFVy9wd3gR/YIYZgk7uY/ei+UirgSvsRM9X6upp5L5fDhNQPX0L1CmHq4dhh8WOqTru/Ulz3aHWw61sxN0aJT61dPCnznYpIHnUztKoLYlfS6CPHgs6PztlM+F3BnP5BCOlCRr1e0PZHQ/mEBRPxZS7mhmOFGYNCUa+nHRj8KpM0k7w4Z44USPs6iz9K/oM75llbNHC49cYq/9CxMxdGa6oO+ckyspLaOcaf1InrXTu0aYVBcp5tWPtyBDiU3RpS4zl+npcyUp07Y4jg9eCDFGuGrNpJO40ThaKVXy7/aXhvnAHzsjh3lByp3qKGRc2XA//a08shUDL2CNixuwRBTxfDiDXPpHDom/3udp+I4Hvs7k8qfrXl5cVRGrbbsA+D8RnI+gbtEvDIj2/fizKvot6JxH2mJ6fGqCdFR5i6JP3vJF0AG5C5rEPX9m3sj2juKjJhRTjbbjbysb1oCtw0gtjhzQJk8qinP/Ko5JrDj04KXCZpiD/yTCtovOB1l9Lzh7OXTwfD0Sl/fwGoYmF+SXZleg5koCyXJNmwvPUWnQ6MTe+Xj5piLZ8sQ8sRjmo1K5//lPmNAFsX6prd8UaXAf59DkgG259DKhH04OxZbdAWqOFKYYpUVwOAKblt3dM/9lexg0XzkKPER/FOosH3Lg9f++gkyS27FEQsIVeqknu5+UX10ToiGfC5t4zlt9QCj6oKv0DZ68d7USlAmleZnKuJyE3J5pigc6sFTKUZssrNKwV7Kf8AxRDk3Rwu6Y4bMveQHn7HjJzQ1wyZx2CFWEsiu2XjJmO/EF59UJ478s5Nckl1NQJ05ktXZYx3JDdyf6a/y730z9f7Tmk4xfekxdgjqwnNFbKfEfe/o0dkQOezu8J7T7Qv+TWxU65WzGrW7IVRxMmGrf6cOWHqahxKyXW8UjgfmFb7pvQAC8BCeVL1yNYULAgXgbBnCyTxr/n+U8+32M2NZ7xef0P5M+KsBKY/0/YIy8i/Vc9Q2alP8x5/FnTclTgPyfh9VmTVqEXMF5k2EhsGTx5nyaXl1FMt8/TpQWX6iI8KVI+jbT6035LLdmeHOOCOSzT/I1NqBYI7YVpDiVN+6x1wE2y7She5IiSVT9mkuKifmHn8reMP7PYqIx3900fYcCfJiL6/VBm8MYDjJ4ochOT0XXIZ8g2Gjrp7Qly8TSw1N+jNso28eE0vIHn+4YrhG38fD8YcWr/bIFvdiiP62P3OAafBymBrqY3ySZ3WtCER9bHeQR2VzkVKGONaeFUU9dSq/KhESmiuRLN/gl1gNRSF5Hdh808iFlhFydgX2fYlXz/Gw= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 657eeb9c-0565-48ed-79e1-08d9c62d8c6d X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:58.3648 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: j6fr8hgn+us3TntlouJ9aJ0rHhkQKVYEEvfV73Ci6tfoJdRxpvO6SwmsCwfk1ZOz84lokYfR9fKH7x81iYweQ4/pQpWrvwRU9vGt0jKIiF4= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.7.94; envelope-from=vsementsov@virtuozzo.com; helo=EUR04-HE1-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_PASS=-0.001, T_SPF_HELO_TEMPERROR=0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" We want iotests pass with both the default zlib compression and with IMGOPTS='compression_type=zstd'. Actually the only test that is interested in real compression type in test output is 287 (test for qcow2 compression type) and it's in bash. So for now we can safely filter out compression type in all qcow2 tests. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Hanna Reitz --- tests/qemu-iotests/206.out | 10 +++++----- tests/qemu-iotests/242.out | 10 +++++----- tests/qemu-iotests/274.out | 10 +++++----- tests/qemu-iotests/iotests.py | 2 ++ 4 files changed, 17 insertions(+), 15 deletions(-) diff --git a/tests/qemu-iotests/206.out b/tests/qemu-iotests/206.out index 80cd274223..7e95694777 100644 --- a/tests/qemu-iotests/206.out +++ b/tests/qemu-iotests/206.out @@ -18,7 +18,7 @@ virtual size: 128 MiB (134217728 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 corrupt: false @@ -42,7 +42,7 @@ virtual size: 64 MiB (67108864 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 corrupt: false @@ -66,7 +66,7 @@ virtual size: 32 MiB (33554432 bytes) cluster_size: 2097152 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: true refcount bits: 1 corrupt: false @@ -92,7 +92,7 @@ backing file: TEST_IMG.base backing file format: IMGFMT Format specific information: compat: 0.10 - compression type: zlib + compression type: COMPRESSION_TYPE refcount bits: 16 === Successful image creation (encrypted) === @@ -109,7 +109,7 @@ encrypted: yes cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 encrypt: diff --git a/tests/qemu-iotests/242.out b/tests/qemu-iotests/242.out index 3759c99284..ce231424a7 100644 --- a/tests/qemu-iotests/242.out +++ b/tests/qemu-iotests/242.out @@ -12,7 +12,7 @@ virtual size: 1 MiB (1048576 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 corrupt: false @@ -34,7 +34,7 @@ virtual size: 1 MiB (1048576 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false bitmaps: [0]: @@ -68,7 +68,7 @@ virtual size: 1 MiB (1048576 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false bitmaps: [0]: @@ -110,7 +110,7 @@ virtual size: 1 MiB (1048576 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false bitmaps: [0]: @@ -161,7 +161,7 @@ virtual size: 1 MiB (1048576 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false bitmaps: [0]: diff --git a/tests/qemu-iotests/274.out b/tests/qemu-iotests/274.out index 1d2928e14d..1ce40d839a 100644 --- a/tests/qemu-iotests/274.out +++ b/tests/qemu-iotests/274.out @@ -50,7 +50,7 @@ backing file: TEST_DIR/PID-base backing file format: IMGFMT Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 corrupt: false @@ -79,7 +79,7 @@ backing file: TEST_DIR/PID-base backing file format: IMGFMT Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 corrupt: false @@ -114,7 +114,7 @@ backing file: TEST_DIR/PID-base backing file format: IMGFMT Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 corrupt: false @@ -141,7 +141,7 @@ virtual size: 2 MiB (2097152 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 corrupt: false @@ -176,7 +176,7 @@ backing file: TEST_DIR/PID-base backing file format: IMGFMT Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 corrupt: false diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py index 4bb740634d..2cbb13d67a 100644 --- a/tests/qemu-iotests/iotests.py +++ b/tests/qemu-iotests/iotests.py @@ -486,6 +486,8 @@ def filter_img_info(output, filename): 'uuid: XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX', line) line = re.sub('cid: [0-9]+', 'cid: XXXXXXXXXX', line) + line = re.sub('(compression type: )(zlib|zstd)', r'\1COMPRESSION_TYPE', + line) lines.append(line) return '\n'.join(lines) From patchwork Thu Dec 23 16:01:36 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698478 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4B99AC433F5 for ; Thu, 23 Dec 2021 16:13:42 +0000 (UTC) Received: from localhost ([::1]:41470 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0Qir-0006Bw-Dg for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:13:41 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43292) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXr-0005W9-Mj; Thu, 23 Dec 2021 11:02:19 -0500 Received: from mail-eopbgr150128.outbound.protection.outlook.com ([40.107.15.128]:32197 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXq-0005La-0Y; Thu, 23 Dec 2021 11:02:19 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=NUb/dtR/knFYu5jv7iNzQvy60/UpdRY6ukHhKtlQOyD+fCVFKH3Of0OY2y/9i1Pco9ickkcJh/G/G9vAjag4q8Twg7hDBwwwc4ojfGsnNqlW81eD85wx7WLDW88HKjvr2M27wLxf4boctJ1WrVl+evnt+VYbkosgzuRFu/Jcqw/FQzsJCXEcRTW8jVI9wZ/ZRJ+xtFsp9rsSlE43bZnosi0pQUoKZmHtzY49cXamrOza9vmZ4Wf87xWAy7CnvQGmR/6q+Xqy5MyCXSvcd04VVsT9yWoE3GtiOXGoXfWHlBWhGO/SZBWzp7onzMGAzBMaTz2142jZbS//3LvwQPYyHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=FhvaATUa4cNWT0H3PXZx+a7CCwtxj8QfOSkqKBncPnU=; b=m1Y7LPKxaYm17iKy4MD1ghuPxxS0WYUF5LHmATzIZ79rP8Xdl8a3n2u0r8JNCGwVUVTehR7bc8rqVYCiY0mZZ79E2//8egLUeKvI1ZhAUA3K65tprBChpoh2Rc4q0MFeOh0DfRblvDouCB2b/AyFtxlXJJWa93bplgx6bGHWKeeH0dBYNUMrJnwiVD1mO2iYClbhzCb+K0jCc7DcgFIS8pB9RMN/3maClmqJkAtU7ReGnznWpgNxtROQFHJHlWdQKOsmAD4bzJCipgh2B3zBa2vCXJmqKWGYZx7Z29GgcWKWR0nWtN0VXoKzmxenM1t7/D4UtoyU+X2EEVhYSJ0rnw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=FhvaATUa4cNWT0H3PXZx+a7CCwtxj8QfOSkqKBncPnU=; b=Y5MQGewdCoi9JaXAeXupOWRjB0jYkd9wBwMN6dNpvLbeC5tkWgLZNSiV/GUE6lEKo7MxGQq7mKdN7156Yl0XcbPwyjHMomZIJWo5O3uTdvFpWgip4ya+c2NDG6T2HvqtND6mnBW7Nk9IoOZSNrAC9cOrxy0FQSR1euN53lA5Tm4= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:59 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:58 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com, Max Reitz Subject: [PATCH v5 11/19] iotest 302: use img_info_log() helper Date: Thu, 23 Dec 2021 17:01:36 +0100 Message-Id: <20211223160144.1097696-12-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 8d4bbe42-75cd-4607-3017-08d9c62d8cb5 X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:5797; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: AlhaqP6cF5sSLpx8xlMw+Kd/XVEYxkeedTOzlLa+6d1Cw1fiyL3Wdk+jFuJPZYVJVBeH3TiB/+hdGYeoULVEG2KBt9TQbhknLvHbIeuXTYPV56JvNmyXSGd6iei+0Ijg6vmYxiyTyT5Jk4mj0y+7dyf23kQhiFkh0rqseusbTMdG7wA3pneliBJFsZyMu4HGL9Hk1DpqtQhj7Nq7M/dsEaeOGpRqJHCyYKQwW8e1mhIAjLWNhITSUulosQeQ387RsJZc+/gtp5wwZAyjPT+vut06RKPbmodzF5nl51kfWlBr5RPHNGKEMVVJBCbEfso9zW4AGcCz7nNO2+/DIE2f5T/I1N6glLGfjqQ6jCMAlGcCJnzhNb1A1aFFWjIU9ZbgFyDQrJ6t2o2FMrVBm5590AxxRvpoAapP5pli0OoPO/fBsD5HcXmwsZdAbw5bDlAODfifUtWeul6AxzoFPlv0+1qztR+DcT5tHRRcqcqFDsWQZ6eNR462LgIBsfSoyTXkR0KGwywFBN8tQCjyaILRrI+SBEyIoIIK8xofEn2DhF5WOjFOUMa//NBSoNYtGxO6onD4twoNMlUN+ON11WiNnzHcQKqNr8P4pfI1w/tfy4WwigwRMEJ77zJDF4jOHQ+rWwHWUomKPVpCmuGzMLa+EExSxxMDZo7b4YZ3UPhZX4ntmaXdeTDin9v6Y/gsbq9ZO7DcJ8lrUCLJTwViNYrmZA== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 7AaDVDYO43H6WQM1nDsovnwFqzD22a8gP7zdDI/rO8dt5bUWHSZOuMjhcFO1nYqlaZJbmzpFp+e5KzI5jgRajpNM1vTyEzyXJI+Nb0CAy7I5Q5b0zq3TeFWnX3st9PmXqQ/GAlNMEMhHoa1wkyaWNRReLKQjkWUO6zM4dL7KXNnKHm8i+xH6TacJuXGlUYd6A3ts9N0lBK/p6PF2bTBYGGlznGUz+N54nreyYrUEhpifvkUur0X4zgtkGbWhpbqIyPmoDhputAYDwx9IEMZJiGfnjQdjWbZfHGwHAg3HGeUDQUS8wnll/JJfrUb+bQiCEyP6n26IDjDz3yhJZrkcAdlcRUIbiWprCOSvrZl7YIMwfZgtzNvGBSz72Eh7K68MRg+/32lvJNi2g2GEjVs6++TZzXfFwj6Zk6do+oNDymsTTtL2Pc5pZHoBWDvZDZ+CBYZ5XiSu7ePycaaNYxOuJtODHRU+QMnuCnGst8NhKFly5GhogPQT6+D38JLwgFgKsIrPuwRK8YpjSzdF0LJwwc6+IGAgJAIl9JOa5q1yaQKIPZASXNt/QSlcfyGJ+gd4wbwTJse9/B7bxxHflLucDIFVERqu0/YUFmQ7u/4Oo+2S1PoJYqk/bHvggHVsaA4TMQq3CRe3dRHyi0PcPcAtrbLGFMaXVHE7ZG/nWXYlNNNkvs60oVvnqVRHKreZwDaRDRy1lGOU+Gs1VeDPqDPLzf4nofQnNdccaMvrrHnmyMVKyWPMWAmNlam3JbciaWZw6gakm18r8H7bTm3oYc0uP0o+CnDqQq9sTpU7eQKhfUo8NDoXYs/BedZoB9v004Qs7kKCvjH3XAtfHvAGmvMdL6l1O/d2zu1yQxywf5v/leNwnhSuUc9o+pfXs3gv1zfPEWZWmLRxp2H47SUhA8UGofYZEjxzF7e33A6ACASKWGnisS6o7mN5NyCou+5YFcr56zwRFFNUOFH5ptSQc3WVjxv1CPuTC0NCV7bIc9eK1KUtTIEoaw3aLGir8+EKG2m61m3ax9Ov2O0tjbdAX6MqeL7ZgGcPjp8fcnovPcEEyyKBaoFMqtC8FJ16F46XdK2B0KNCvm7tzcdJLWOEntxGOGi4dDOkmTG5l817pgbn/TXA5DRNYS5YExPOI7fjalNnswn+Inu4QX2ggdjNuzudFZ14wXluhD/scCqCCGTykzuXUG7U8lB9jM+hM9ToKj7cat1Yb1lvPBTauE7L+W9Y6Ti/rdHpeuzYWd7U1TolaR8QMNVpQ8wt1cq07EF6Yp0KoYXll+Qg7MWPj7xKtaBnhPqtQys7XVnlsiSE1Islq101LCReNT7aI7PrrJQPfJFiWLRMtyb1B/gXaBbsJpHou2BanetiSgG6wOHFcJrbYPwCn5KKao3+Qb3rnUr9FJT/I1FU5GF9MVMDlO6SOePaq2liRgEtL1ytmDvjsaVRUufe+8aGuqAVqW+1eu559X/QMLbR8/62BxkFQWQIQsD9eOlj1gQuffUNHZKzwnIhw0jkitkIHGsBTong41n9QRPjv+6D9cmUQhd5R77jBGBnoNc4SxgK5ViVabefXxT52onv+bFZiTBG8AggZosjD8fvuLv97JN5Kb2AfVB3tzlb6c0OATHywmLZdq1YVjG/NBDr3bycT0tyjTUMbidDQ5+N/zS+DwsvzpoUsSC9EqftWm37kMkMIIvDlRGYyLr5gJE= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8d4bbe42-75cd-4607-3017-08d9c62d8cb5 X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:58.7554 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: TdF0azUmei4mXtwJPg+tGdZKJ1qFEeYQAIoGBg6cJgMTZJHFsKD/lSkOTaVzrylO9BfxjRR81WrmiXqLU0LoD0w3Oo4jEZU9KsdPv5E7xJI= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.15.128; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" Instead of qemu_img_log("info", ..) use generic helper img_info_log(). img_info_log() has smarter logic. For example it use filter_img_info() to filter output, which in turns filter a compression type. So it will help us in future when we implement a possibility to use zstd compression by default (with help of some runtime config file or maybe build option). For now to test you should recompile qemu with a small addition into block/qcow2.c before "if (qcow2_opts->has_compression_type": if (!qcow2_opts->has_compression_type && version >= 3) { qcow2_opts->has_compression_type = true; qcow2_opts->compression_type = QCOW2_COMPRESSION_TYPE_ZSTD; } Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz --- tests/qemu-iotests/302 | 4 +++- tests/qemu-iotests/302.out | 7 +++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/tests/qemu-iotests/302 b/tests/qemu-iotests/302 index 5695af4914..a6d79e727b 100755 --- a/tests/qemu-iotests/302 +++ b/tests/qemu-iotests/302 @@ -34,6 +34,7 @@ from iotests import ( qemu_img_measure, qemu_io, qemu_nbd_popen, + img_info_log, ) iotests.script_initialize(supported_fmts=["qcow2"]) @@ -88,6 +89,7 @@ with tarfile.open(tar_file, "w") as tar: tar_file): iotests.log("=== Target image info ===") + # Not img_info_log as it enforces imgfmt, but now we print info on raw qemu_img_log("info", nbd_uri) qemu_img( @@ -99,7 +101,7 @@ with tarfile.open(tar_file, "w") as tar: nbd_uri) iotests.log("=== Converted image info ===") - qemu_img_log("info", nbd_uri) + img_info_log(nbd_uri) iotests.log("=== Converted image check ===") qemu_img_log("check", nbd_uri) diff --git a/tests/qemu-iotests/302.out b/tests/qemu-iotests/302.out index e2f6077e83..3e7c281b91 100644 --- a/tests/qemu-iotests/302.out +++ b/tests/qemu-iotests/302.out @@ -6,14 +6,13 @@ virtual size: 448 KiB (458752 bytes) disk size: unavailable === Converted image info === -image: nbd+unix:///exp?socket=SOCK_DIR/PID-nbd-sock -file format: qcow2 +image: TEST_IMG +file format: IMGFMT virtual size: 1 GiB (1073741824 bytes) -disk size: unavailable cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 corrupt: false From patchwork Thu Dec 23 16:01:37 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698477 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9FED1C433EF for ; Thu, 23 Dec 2021 16:13:30 +0000 (UTC) Received: from localhost ([::1]:41108 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0Qie-0005vP-SE for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:13:28 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43352) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXv-0005ka-D7; Thu, 23 Dec 2021 11:02:23 -0500 Received: from mail-eopbgr150124.outbound.protection.outlook.com ([40.107.15.124]:2176 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXt-0005Js-Pn; Thu, 23 Dec 2021 11:02:23 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=NxAXWqKWjD0tiCdYz6alP1CUiAWh2yFhkACqj/eFg9GWFdXyCDsomdGYi+6F/L7yLyY18Z91axETNb7Td3rpqBMxXeBiOGGe+4FEz4jlgcdvd0LbZehYwdV61BJXK1IjhogZpxOTVTVHrR6Hpq4DikTKZ5og0lSLOD2ZY8uO5EeE39AmBQtPS7s203d5EYE2ZFRMsfCdJHCJjpRPJns4w4MeXjdmLxydt9E9rONAdAltqr8GDrORbWfU1i471FmQ7DeKWgk25vO0ZKdRgASI9tcjA8Nh4DC8qE7De8Dfq0dO8BHpEEir23lMTpT1IQ3Wl0e0dYmAUy3QriyNMoFe7Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=JZ9duRdLM1iFu9d6jG0ecjmGr53zpdW3ngUMGs3ybAI=; b=gYlV+xIvflTWNN05XPzQ8tlPQ3gJUiMCuQgy6qFnYRKf2UsuzRRhi2TIZUUnlqmjN9ne297Ukthf+9+QcaE8Wl7xs4bHRMzrpVcXo0zVzDJSmb4z4haDgoW1OkwQ11BZyVZDDiD7/CxYXEmiDm94EHFLO8bWPnXGVu1WEiFTIpRrLbdFkRUbXQc7HumXBY8rvhC/fU4V8+OdcGK01HGMtcOjnbI07F2Kk+Eg+T28tAA9BnHL4OzsPGA5+dC4u4zr6zJtGbUOqtItpetcDnLxo1LuADxoMm39kyX88pefjqLWMufpXYuZV+nf2rxPhV/AkAVXaIWuYj9/8vLxQQoQHw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=JZ9duRdLM1iFu9d6jG0ecjmGr53zpdW3ngUMGs3ybAI=; b=XAfMqgrVW98csluJYqV0uI6BNwzQ25IpdoTdgrEKS5ubQY7ELrjXNM3qVDKylTvzScd4jPynrGVFdA10Ion+OUlcVses5AlSKp5rFbx8zAKAd5IjGXMJbsmdkmAIIf9GiKNdx0+q20NOgXtCZ3dPGuKlr1PFB+fVaXYl3aWRy1U= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:59 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:59 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com, Max Reitz Subject: [PATCH v5 12/19] qcow2: simple case support for downgrading of qcow2 images with zstd Date: Thu, 23 Dec 2021 17:01:37 +0100 Message-Id: <20211223160144.1097696-13-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: c4bda449-433e-4f2c-00a9-08d9c62d8d0b X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1247; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: fW7KsnSV+XYcDmQty6SE8BiKjkLEIPBwNkkswhSs0aVdQr7eq7m+pPvUqJuOJSkYu38ZnmGf7E0rmaoLtETpDMN4fZRXoy7T6WKKlVU4fZTKP/4C0M1hw3r6SOfupec70kaZ96uO6s4Z50un4kRdp0nE7G8jx/ShvE9oxApSj3tPXsSq5+0khttXkRM7gLsPhNieDaeSzCqIxdS9qrim+MrRnOzKN9Gqz/z0nvrVU55MYukqaiCmpfoSbyGRc4f4QMqxxVM5xcFXt+d/529A1yXS27Y2viLeR16sFrTyvmlLvCmpeVdzmP3G8G77D0zHYt5MjDPVxlICmS0aMNgtNFvvwTVfTPty7zHNbsxJ8yh0wfqkAYvu4Ve34Ify6PzuvlUS2l9bXVckpEIVUB68YieCMxyIbbQ22hU/As9ZEckv0GGNGpjhjNUnsVKxjUMZAK/G8D76pvltBFspMqwYm6xjD7Ez/QJj+Zd7mpO5BH7rwVyXXnaFHH3tyuEmc9R0W465gdfOJPWms0cMI1rQ/Gcl22J0Cfn3sYTw9UaPXGvCJnHiQdTOwtcOmd/1YCaXor4t7nKKPP2KXcwgIyDx2s0cXqKZENBnNhuXNqmb4MNXTxoMOK51ckV3N1hN8QKhvyNS/vpKogXJwz1jsjlbqU57JLq/sxWH/HCa2SPN4mAGc5eFsiJYVpfhrScub9EuFk/7thOeiwnyY3XtXzQA7g== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(19627235002)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: US07T5/Ha9cRHfEqP7oa3phBLZfCbICUmcs7O0hoWOvPdC8hTQTjxjmhPFDW6PIkoxrC1l0+TDDx3izJkgaAYGF9qZdmQl72zYYsFukf3AZ6rYtPNOD3a0gvGTKaSGoLEVw2WmpOWitGyUQXLLiRjTvusqwTvHCHWbpkBUpSr7machlzvxjR26k2hIM7r2P9NW/hgZVmUXQMSVezKMvoeG8PL2hSGE0BzZQUdc9xsr/ycJQIy8yKAT84Fsr1kuZIr7+O7Ke1UupVvlvvzHOJVDbXV5Yk5kZbfiiGDi1D4U8JjMrkC6LfCts/8KcicPVlrbCHeFkwg93j06GMspc0k3hitJ5ylMVxH4nGYr8QVNF31Mv4gWSR/i8EIRSet58dPZ8Vx+QQH/y1bxCiD8B10y3TLiIWrW2MduUSJuU1wghgcQXM7K4GAOunzV0tjG0lMWma/aoKmuF+xihZsmkr6QcLq8ioKo758ygEtwAjkXUKQYy4HEcneSY+NAZpsOmveAw4DlzFne73YzMzK0WZ6OhOX9F9liiybUVnkVYbAcJnN713QGPJ/GSbGpmFJFUfhcOM7XC4z7dIDTTPKFU9JYicpMuyfaz8VSqRUTtzgf2zwdlSENYE1GqL5McK7JFZ5C2u7UaYtBST0aNKy1UxtOAVJjmHTX0islNgV0+TWiZrBf3Ibs+JhdXyEideo5oUI1w2haWFp5R9Stf6EcgvQQvTUTn/8ur9Lb99QmqJl+UtxPGQ5OyiHFvz6HUm5jQhfTzqaoglc/6WAI8Igl+SHGedD8MeW54A3eGdBMEe8L7vteaNwfGFl46PvlHWfm5OxAxzE9L8J0VXWCGBG6HIn5pe/WnUmfSU79no6EDEXCL7AoPEbMuopNSvIaWdfs5QwSrX7kBm+QT2vVDvLtrtvkzYw67G+ct9xvLwI5KOwDliHGazpzvjF2Ozkzta3YNfvs6xs4CrnqKq/5GhEqzkzvYvSIGiTZRqo7Z+TqfAr7DKP+cSgUs4KTbaWkQIXiDZ8Dk3R0oLqa1gRXyNTCUDq9XteYdxkagZCmtfmRpCJB12iVezF6Z8V0zXkNBWo508FfsVRhNyXKgdFuU6iaZg6Bel7dhhwdfwHruTf8EDOsyFCdImg05bKm5hp5iPSdY4dZpOOH2sGBjGhy9hwXher1qfirFWZtQT3j3HqQur82B9dL7sO+I6Fi/U+MdVv0OnIGtU4ipxe+EQOeyR6pU12aEsbFp7poRM3tEIB6eo2rWPH2MrXz4NoCB/2GBEuHHKsWyWyxr6xhH3D44GF64i3i8943ezF8PkhYbNg7xhckr1xnUWnH62VrIDvv205MEvc5F1Dnp60ehlQtSgjuy5LIM9nedH5sQOSU11tPysckZwhUvDMqr0qzasVVbvQErXpaTklcXHFTyKmgXM7Esod5WFUHzxaKT3oB3XLct7reGGUXqZQLyFpeN0075OBOQQ0UdqTIEi0DBg/IXZ842HK5XjDX4xnZtqNnK31RNu9hDJS0g5ojmqZZ5KGuEIgGMSUDGQdTBZSSHLmmitL0ODg9fa4pZdk3wKPwXDLThdDf+DAZuPhCLm0P2F8/thkDxQ2S5sxUdu/+L/W6RyfC2kwDyaRYBBKsdC4HDhFB4UtDCY1khbi9Z67SwwlmiM3m7tOOMTDTrSa9FthgofyXoIeeKPI+ZaMUU1wXIjLABdTQo= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: c4bda449-433e-4f2c-00a9-08d9c62d8d0b X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:59.3022 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: hOEBMi9u+GHLMUpehIBOczboRf8ZVzGtcQc5UlPl5jd4W+K6oT89REQqxmhR7YDW/KSLMF+RITynpizOnH+JYnmlyAUmI0LR5JMCoyyH+yM= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.15.124; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" If image doesn't have any compressed cluster we can easily switch to zlib compression, which may allow to downgrade the image. That's mostly needed to support IMGOPTS='compression_type=zstd' in some iotests which do qcow2 downgrade. While being here also fix checkpatch complain against '#' in printf formatting. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz --- block/qcow2.c | 58 +++++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 56 insertions(+), 2 deletions(-) diff --git a/block/qcow2.c b/block/qcow2.c index d509016756..c8115e1cba 100644 --- a/block/qcow2.c +++ b/block/qcow2.c @@ -5279,6 +5279,38 @@ static int qcow2_load_vmstate(BlockDriverState *bs, QEMUIOVector *qiov, return bs->drv->bdrv_co_preadv_part(bs, offset, qiov->size, qiov, 0, 0); } +static int qcow2_has_compressed_clusters(BlockDriverState *bs) +{ + int64_t offset = 0; + int64_t bytes = bdrv_getlength(bs); + + if (bytes < 0) { + return bytes; + } + + while (bytes != 0) { + int ret; + QCow2SubclusterType type; + unsigned int cur_bytes = MIN(INT_MAX, bytes); + uint64_t host_offset; + + ret = qcow2_get_host_offset(bs, offset, &cur_bytes, &host_offset, + &type); + if (ret < 0) { + return ret; + } + + if (type == QCOW2_SUBCLUSTER_COMPRESSED) { + return 1; + } + + offset += cur_bytes; + bytes -= cur_bytes; + } + + return 0; +} + /* * Downgrades an image's version. To achieve this, any incompatible features * have to be removed. @@ -5336,9 +5368,10 @@ static int qcow2_downgrade(BlockDriverState *bs, int target_version, * the first place; if that happens nonetheless, returning -ENOTSUP is the * best thing to do anyway */ - if (s->incompatible_features) { + if (s->incompatible_features & ~QCOW2_INCOMPAT_COMPRESSION) { error_setg(errp, "Cannot downgrade an image with incompatible features " - "%#" PRIx64 " set", s->incompatible_features); + "0x%" PRIx64 " set", + s->incompatible_features & ~QCOW2_INCOMPAT_COMPRESSION); return -ENOTSUP; } @@ -5356,6 +5389,27 @@ static int qcow2_downgrade(BlockDriverState *bs, int target_version, return ret; } + if (s->incompatible_features & QCOW2_INCOMPAT_COMPRESSION) { + ret = qcow2_has_compressed_clusters(bs); + if (ret < 0) { + error_setg(errp, "Failed to check block status"); + return -EINVAL; + } + if (ret) { + error_setg(errp, "Cannot downgrade an image with zstd compression " + "type and existing compressed clusters"); + return -ENOTSUP; + } + /* + * No compressed clusters for now, so just chose default zlib + * compression. + */ + s->incompatible_features &= ~QCOW2_INCOMPAT_COMPRESSION; + s->compression_type = QCOW2_COMPRESSION_TYPE_ZLIB; + } + + assert(s->incompatible_features == 0); + s->qcow_version = target_version; ret = qcow2_update_header(bs); if (ret < 0) { From patchwork Thu Dec 23 16:01:38 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698484 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 314A5C433F5 for ; Thu, 23 Dec 2021 16:18:57 +0000 (UTC) Received: from localhost ([::1]:56528 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0Qnw-00088H-5h for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:18:56 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43372) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXx-0005pZ-5a; Thu, 23 Dec 2021 11:02:25 -0500 Received: from mail-eopbgr70094.outbound.protection.outlook.com ([40.107.7.94]:61158 helo=EUR04-HE1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXu-0005KZ-Li; Thu, 23 Dec 2021 11:02:24 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=R94AMfT8QMdn1QN0W2MKJq3AEeQRvUARoKHcdeburAPVzVOzYIhnie5c7TbIp7meQoWbk30kpT+quBvcC+IkAG8fr/2oEQP5byPsesKEbVZlj4TDcKNaN1MG1K7QFzLQL89nmRoCZT2UA0vcOXBjx9N3NSR7z4PZcfhTClw1mg3XUkVJ8OykdG4DgyZDCkZesRIgndKDrxDBiCBLr/Gpyg0GddRIWh1nioRAAelXp+Bv319UeT1j+Jdi8b3B0CjyhiTytKuQe6rbM8AqFlC5MZ2454D3Hd1UgAoxGwFIcsegT4DI4OZx7UXFxDL2XH19BLJI4YL6rA4bnGbzRu8J7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=yX/y5RRgTxN3+SaetWQ1fM1b+d8og1FNDEBJvtslr14=; b=eh0QUkWkck7YUprNnwJwFj6OnQ0z+IinBMMIpHvUoo9lXPY/M2CcwrSnc7XTMhRDNM4O4AgcwLJL+nG1cwGjoFgLOjYBcovnmFPHAQUix6/3hRxljZd4FGLBKRuA0YC/7aCUzLQK68HDwpAtkJ2PizTA5t2mZvdtoylng9nRtMFtB4I/zgmBd2Wf7lWuvBdPYgYGlUeH9cehFRJU1Gh1/4vCERnvP7YbAj0A1OCdeyg9TWLD5NdXvOW4wn+9ZE8fs3bjmTNEJjkMXpynjFDZPPUeNU4xktZcYrWskBJf+Hp4enxSIgdsfCBJErwVr2viWTsNkPvJXuhqf3W7lYSIFA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=yX/y5RRgTxN3+SaetWQ1fM1b+d8og1FNDEBJvtslr14=; b=ujMDBEANmLZQtTVGm3QZiMh9P6YxV9IRXvnNJ0vd5/Wdm8EiQnc5faujq1QSi71z2H8RifQmCeirKjC1V6q2Eq3aRvSWx/n7NxGlESJRmq8YWiyZ/1W0org7PUShoUbPGAdQuumdBgJEk5UkwF8q3GbgzyfqLrUq4xd5WMmteCY= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:01:59 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:01:59 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com, Max Reitz Subject: [PATCH v5 13/19] iotests/common.rc: introduce _qcow2_dump_header helper Date: Thu, 23 Dec 2021 17:01:38 +0100 Message-Id: <20211223160144.1097696-14-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: b43de1d0-573e-4632-98a0-08d9c62d8d46 X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:3513; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: W30Je/VI0Btxmcfm3Mwf+OaTlNqLHJUiMluM31D2fn9QVH2AP8wYk3QfY8DuVw4rzuTmuMV0uREdzozrrGVTfyClxwZF0wjAYCJkvRjUHYuLOdfRn4QvLgpm3aEUXAx2Wfywj5MGFwlAIF3rXXfI4WfRgygVdkVkObiQFYUe1rzD9WnttQXLHE12gjU0t0Cvy9Kq+ocdc7EtXOenqumXYC/WGhMjHbWCFmydctAzBVeFumCbiKOZVFFNHJ3+a17AQuOiFFxzQ1kwQULQdFBeMTcwVYkPZL0HSo7nVpNvB80YmfKeKserHoY0KFJmF1ViF42NblqTay3W0+ldELYlRZn0GuNxnGs8qHHCmZ9OaunHZP7dsC9UjBEh2koI8BVTgC2bay6Kgt6L0yG9SwRPU9vmADxnt1KgcClipgRy/fnnB9KzvoLQSTskjQ1a2cK/vabhu7eEHGD5Cj5PR6ilnBVc/RLnIf5TRq4EvrME8KTYB7k1cBvw/eXHMUslxKmrXbNHpjlfEYbahE8P/lybAjCul96UJz0NSm+E3i5vE43SggtF9eXbgMLKEMk7MtviA71NH6DZI7AhA1akAmpktOB/UG1QnZhMYAyxpIGUQYMoIcxgGqFM162NUCjZEVeVZCcitP4O/ho27aBGYuHzo4fSzd08fng+ihX8rNy0GF3ctkdxAojilZkbDPhutgxG1pxZQVtuRfI1+4Hw2eyOFw== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(6506007)(2616005)(6916009)(26005)(4744005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: yNBkTW4biUqSXMknuqbnX4TJlkH/i57MaOPOHGTSG2w0WP5Bn2tC86+M5nYdJye47VZhFDTLm0Nci4ginnq8cDa1DhO2yKut2ZfmIeCm+MrBlbRIblJiPVlV7Vp2SzWuBxHblTwvw2JV8jJarLaNkXmtgdQKLauO3oybDzvwBFN285nbd8gAVhsOg/7p0jCjlRZ6EzliVo6uBQvCTs6+Ug3teIhQsqqlpkphcTE5wIPMSzOOVpvf/8RAVfM6DG+CCAW8Ir6k727t9WIEt1xWlb+EViZv/0H80wi7pmdAuT8tE0FWuyVfFVZBfZWM62hY5kKtfQg+gyfF32ZUs8PncTJCAW7VV51QgHpQzZ6N6vwuo5xM/OfmkNuiywMcYdAbh/F/Sqt4qiqgIzCONA2+KOQCvqDcS+WUj6CPbW6zrJgFGSsU+LrLv3WAj6wqoy5j6lRA0EYEk0KeVArdrnoyz8rbCf0erpIjXOYyxTst6yUaNXgbxdSFIcnY9tZfouVsI+SBu5ntRleWvzeZDI1cCh6qCJECR8DGxc4Ck/O8y54tY+hpZrtOALn8M17cSWd3zPIKVzt3EaEDcpQTk7aFkR/iNrL8CYAyWLpH8DwpSIwXHsI321kaj82Yz4fxuLl3tMzyKgMN1fkan6Jth0VS5VC/ePfSq/Uo4uuqXXObTo2gWLThDHBdnBFFb4XfCuqh9U5Jdf/X6XImqiIPigXo73yj50UYrvoqhBsRS6tQYAtY4AnDZWY9T2psucqt4QfuZVydgR//cahaldj0R2PN17CjQ02V02d/hp9/3j5zfwGaMYoqJCxXmqMA4M91zAGdih//OSODtjS5zlcNtCfY+i2dHalbqjdqQJ0lmjIBvXTcgL/uHtdbpHgO1XaTy56unagkZAKFYvVDQ2Yo55RJQ2hWPM9djQeoP5eEzbI+jaIvOqsrapu0NkfTXf4mYpjmmHozP+3I0srJTq+TqNNpxNHNyg/pyYpQdlW+16mQ4bx1+C57PzggVG3fWCGwi8081Dcs0wbecejhwVUaoSSYpLSDshcTvWyl1Xqs1vHcS0xRZQejIzXRVT6B7/S2sFSxQtw3msrtjA9fNrCHf54iTH68GzUqwWNVwzdJqJXBenjnE1HTFABK+59Xl5n8AaWdG4Mt6K86cWnv2bWYMFGy1aQ6qF1fcEdZRdgQUp0dUh0QRxg8CdVPe+Zvw4wwTP2+qxIP+25EwDMpMNVroebV9Ez6in3QkEz5Q5QWaCNlh+3XoXX5wfYo4JaIOVp5Ii0SlpmcuLvSX0K7LUPnrHV3YJ/pFnlcO9iIxF6R/9xR5/onCAtMr171rblmw3j0PQvA1rn76KOgPrabi3cTaJ/D9t9PAgBMdJO9+N6OCie1RIjGirNILV872cFDCOaxpbCXzeFGoKVou9YZP7KQK433QS5Kp5cYIwMC4IkvMTpoe4+rx2mTSfHAkuU3wX181MxNo2nG/Zsl/u5okkqPWfJJ7ZjsWle0EnfouWu4NJe4hf9zHLifJrq04YH4brbimFkxBqj3tEYiO66f74z2UKwtZ4zFazJOn/drnH62blQEY67sfGn4l5bYqy4SJC/pvK9Xuj5otqN9+esNHsQuzwiuOyb1Hg9ioSJBpwe29kmTbmjiwQJh6MJ7pi0R7Mib0BKzO80v36psG5JX5YpLtC0+JZgu2DReGsJyUhSofEHpPVo= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: b43de1d0-573e-4632-98a0-08d9c62d8d46 X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:01:59.6458 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: xVmqfGZ9dccg0gZKcGC0xSedS2tfV9F9g6aqLRI+3IIs+rU+NY+aG7g05QEzR6f8i1u05EDjhgVMXXPk5AzexKUI3XtvIla0XW0EwQNszY0= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.7.94; envelope-from=vsementsov@virtuozzo.com; helo=EUR04-HE1-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" We'll use it in tests instead of explicit qcow2.py. Then we are going to add some filtering in _qcow2_dump_header. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz --- tests/qemu-iotests/common.rc | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/qemu-iotests/common.rc b/tests/qemu-iotests/common.rc index d8582454de..5dea310ea0 100644 --- a/tests/qemu-iotests/common.rc +++ b/tests/qemu-iotests/common.rc @@ -996,5 +996,15 @@ _require_one_device_of() _notrun "$* not available" } +_qcow2_dump_header() +{ + img="$1" + if [ -z "$img" ]; then + img="$TEST_IMG" + fi + + $PYTHON qcow2.py "$img" dump-header +} + # make sure this script returns success true From patchwork Thu Dec 23 16:01:39 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698487 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id DC04CC433F5 for ; Thu, 23 Dec 2021 16:26:20 +0000 (UTC) Received: from localhost ([::1]:43966 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0Qv5-00021u-I7 for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:26:19 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43390) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXy-0005w7-IW; Thu, 23 Dec 2021 11:02:27 -0500 Received: from mail-eopbgr150128.outbound.protection.outlook.com ([40.107.15.128]:32197 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXw-0005La-6H; Thu, 23 Dec 2021 11:02:26 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=m605H+jqgMd/1lIZZyKtPYAFeNyvIplZK0ODFsemJUH8yLAekQ+gsncsqVubpQZa4iKkpJ+dQaEIib+42OffK8LDpIYpdfcTX/gksmlOd0FvzcMUqhN3ZyyFCD+vmU4hfRilzlu6ExsWfl9Gl+3ICGA8DQj5n+/3oLSDVBPbTVFE6WIWxdo4u2KOhu5vht2tnByXRocftV8lox4Whymj60osMZxNcrtXPdwiJVNrEo+EFxlWCPvvXzN+vjDkCLwGOOAmb+I8lQserGFX1aHvok2Im6NbWEPeofBBCdpV8C/DqEsRnnS6klizPq/86yTccedALMEd+tJQN512XsJ0xw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=wQ9oSHqLXKFNKhHgPqYkrc78zjIZx1hVU7ZozAuohNU=; b=EbTcQRsuL4178gOC3+ETyTeDkQo3fgI1eWwRLlhZGwLflY7FQHw1LvpNHnuoF9nrs4joKvfJD0R07SE1X9V05Wgzcfc7p9OBRISPsntyyMdsXPEJmVsuvlU33zPF9qcCAfQf4hNUn28clxnRMgjYqWPUVXhuilBIM01LaiEk7o2IGG1SHljdEaPQSaAe4W3pJQN7nm8Cfoy+Dku58Ad+oWFhQ7yhJxog3evA+iXQtU7rYJStcraJHzWJ2AmT5yn3dXjUKV52PocprVx5gwq9RtHtPxOJbTSzy2/xcw8As0AmzywDG/wxQOxZawvvE34NHWOTwqmAkLL5YS8RVVlfmQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=wQ9oSHqLXKFNKhHgPqYkrc78zjIZx1hVU7ZozAuohNU=; b=oOkOL1q3CkTLlW2GmXb2SJiyUhYz7puJMjW63RBvtM0ICGLIRK4zWWVQMSAXyOmbjR0EbszBKAZ9bSk3MRl501ZpgeBye59EvBPCCatuHzL3eNd96F6/2B4TlBcdnhrq3BhtmeJphl+jybfnwcn7GYk9JMStydVskUlNM5U6vyM= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:02:00 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:02:00 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com, Max Reitz Subject: [PATCH v5 14/19] iotests: massive use _qcow2_dump_header Date: Thu, 23 Dec 2021 17:01:39 +0100 Message-Id: <20211223160144.1097696-15-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: c124ce64-e4f7-4f26-6c34-08d9c62d8d7d X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:55; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: A4DKequ/m3ecSpwZfISrF5CKqYsxFeLrAhtUpP04x7IO7Rdagvu97HROyBs8wEyh1qGfaBw4Qo1WSPHyKZUEryMsglLzkSGZ+A+Zhaoa/8/+PElho9i72QjVI31qJDFMdz01bD/jPgqX6KA77TBuF+EMq0NNWvEoifSKJ5cNQr8DjPEJVGmHxNYJd968ej48zd6uTFwTHEgO8Wb9urEaEKoyIZa4un/N4WZ5Qm/eOSlx77iauih2X+5upJ+Lrgpb7nWmFxg4HFGJVPTUcHVwFVjvFj+Poj58G4U1yllCpns+h8io6HQaN2VDVCaFclIC9uOCUQVmVNwels/QlJlEK59YJMhvmjX4GKg96/WxI9Wzw6LmaaKYihVDw7RPBJ+dDUhEVyEllINLKCrXgn96eGjCKSefHJiwnM9et5W+QE+T0LkwI95qGfEMmzmN3MgCyV4FgAJ7Co5XwcH8OSBZXy4naXFq9kftte1jUbHKB0wjj/YqNKdwZYv8fffyJwBUxIy57n8BR6dhPaB8/h3806/QuChl4J8ZgGs6frBBmqqoeea0HCVzAPX5YLuRtA6aqlcWWjsbKtgat2wAr0O8lPkwCSV/Zhp4jo2OaXM++ld/hZ0Q0BHj81Mmdejw0Jhw0TFHFQXObomq2P79NTRxVR1a7ana1YXzjamB0ggT7MDIhplUjctKkUybLdlS8MO2pXzwfJtIXlWjBRD3W9SnwzAuPulOtU429islPWI5sIY= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(30864003)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003)(14583001); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: HaR0scFIgLKqbr/RtQ01aXiQet5p4vRhooR5SDEYDjB8BFrPThVDlIp8Gf+HP5q05SJ3060aKCVQHl9oBFXYCWrAAPyU0Bj39cOM8nvLXmT/R8MVfPhL3RPzGWEyogvAG2ZOXFfCaQzplfXmz4PwZoqvGvJEVAFjEtCUA1PxR9DUHbDHWH+F1iATrDYlnl5yBXthYVz7QDLy0HFfBYUu70vZUvJRugk4bBgjY9BCBLiqgsBdSIsAyOrQQHSlpd1BTKJbiUj8ieY6idO6EIHh7r0Q/3A9X4c+Jc+8S/8G+0GP03/Bw1yhR+dNHpWYkO4E9XIJ2/Gbw9IioUJcQG/bcOvgpAjLraMvFW3X8hItCx4wKiUcY6j+VAcuwQB0BLneEY4IFTwFPisB62MEPbsVfYR4AfnXreP/EWwLcHvt/6+KkPt7jBSFLFwus8gjr+MJn9UPBMEXwppad/fNlCgdxUppXBUfm5Ld0JlC8Az40bd9/rM1IQ4HxcmFVaTw1tmWSuQRpEFOM/sfMCPuqG/6gZKOHolVhCvEv8TtBIW71+uijBN1OAHC5soYlodiLX1rXomx7cFUa/d2pCdj5n3GlftihSHQ1cX4KFIcccPZXit/UKXN4+Cz1oxXDAJoKoxi+EQESv+3BDsiXwcDsDQyLtch6oMf9cVqDnL79P+W3PImweZUXSEQA8866Y/sDCPiUfa+3GOW2XCtg2Dgoo4h8ivo3HF04SH+WrkbjFFmZBdv3zj4XMHVl5Ve6SuOKWbFZjqXFrQ2seszHn+rmgTzEFKWdNXM/RyiZC0nVi1b9GsDZJ3yCeJFmDfk7Cz4hQbP8q2X2uvvzsGu97kMt+cZ1pFHTVn6oluuNypp3rSzXKlc1yWpRn88Sr51/OcdAsNPIexld8+Hwnbuos/T1h10IWUHDq1KEIoFnN+AlFCYEEZZJ7Yd2Yg36qB0Cv/ZkAggs+S9KQQ3qj324QCFRXt43ACNHaKAYf5Q1Q3mRpEOR4MxT/WlXlDx7a2gbt0aP2iof7QuE8xHLOeT0RVtv/bzXUhIkM58FQKUNqTjFK/NXqfEUICZbVM9miXBqXzIh2T+E01Fe4gGe+djOOxtjXtSy2bJ9fnfjFBcxYhmFUhawLpfwBzV2n35h22kUKpgUxRDe4XJt/HGDGoMQXJdR1xgtUjERjxr5125hW6IRBa8dkvULvGv6SJ8LlbLTVE4p9NGUizki0aEmxqd2YM6FEbYsk8Ri8xkgwzfPb6aVrfHcwJI1CMn4rgNi+a+IRT/nCpxA4OcuTfAmbmc/oxq1ll67xTxYTpp3nYeBDu3z6XL61E9DljCJxnmtT7t1vUzspicwEFxFUA9517wuoeA+eA+HN0+8Hm7QmwSHhDp+1FX7x76YX8c+gv9AKVCxJBbpS3wFyKYQffaNUyBar+C9KfwaJYx2NaPfeMpgzixWd2oI5hlvm0MLjArea0cOsko2VAdE5y/RSv8qeiANo8p5ED8WWtyStgKkcHP9iMvhTskXOsfTDmu9UNRy+smVbh78HDfDML34csdo2ZrHqCJ2oZAT2SVRO38atovrXfNBEWJK8xDAXKVsc9h2W3hzjwvxpAwXnd2Ek9nmKwFqMNGMAYkUHK/VMGBpp6FAxCBTNqSFiyRVWCj8TfkZbcnPsg1symBXdN9YVXlgIQ2Vjc5L92IU0tB/TGJWctf6zF6FtbpAGc= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: c124ce64-e4f7-4f26-6c34-08d9c62d8d7d X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:02:00.0833 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: N6Lc6N4mE8EwJijv28rLOd8R/FDkx7qYWfJI7WySYAOGlxNQ/7LpbgZdDsKYgpzl1L8J6xFAvYYWeBsKjVWfa090NEmBDibUJ/bf7LO9vnU= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.15.128; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" We are going to add filtering in _qcow2_dump_header and want all tests use it. The patch is generated by commands: cd tests/qemu-iotests sed -ie 's/$PYTHON qcow2.py "$TEST_IMG" dump-header\($\| \)/_qcow2_dump_header\1/' ??? tests/* (the difficulty is to avoid converting dump-header-exts) Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz --- tests/qemu-iotests/031 | 6 +++--- tests/qemu-iotests/036 | 6 +++--- tests/qemu-iotests/039 | 20 ++++++++++---------- tests/qemu-iotests/060 | 20 ++++++++++---------- tests/qemu-iotests/061 | 36 ++++++++++++++++++------------------ tests/qemu-iotests/137 | 2 +- tests/qemu-iotests/287 | 8 ++++---- 7 files changed, 49 insertions(+), 49 deletions(-) diff --git a/tests/qemu-iotests/031 b/tests/qemu-iotests/031 index 58b57a0ef2..648112f796 100755 --- a/tests/qemu-iotests/031 +++ b/tests/qemu-iotests/031 @@ -58,21 +58,21 @@ for compat in "compat=0.10" "compat=1.1"; do echo _make_test_img -o $compat 64M $PYTHON qcow2.py "$TEST_IMG" add-header-ext 0x12345678 "This is a test header extension" - $PYTHON qcow2.py "$TEST_IMG" dump-header + _qcow2_dump_header _check_test_img echo echo === Rewrite header with no backing file === echo $QEMU_IMG rebase -u -b "" "$TEST_IMG" - $PYTHON qcow2.py "$TEST_IMG" dump-header + _qcow2_dump_header _check_test_img echo echo === Add a backing file and format === echo $QEMU_IMG rebase -u -b "/some/backing/file/path" -F host_device "$TEST_IMG" - $PYTHON qcow2.py "$TEST_IMG" dump-header + _qcow2_dump_header done # success, all done diff --git a/tests/qemu-iotests/036 b/tests/qemu-iotests/036 index 5e567012a8..f703605e44 100755 --- a/tests/qemu-iotests/036 +++ b/tests/qemu-iotests/036 @@ -58,7 +58,7 @@ $PYTHON qcow2.py "$TEST_IMG" set-feature-bit incompatible 63 # Without feature table $PYTHON qcow2.py "$TEST_IMG" del-header-ext 0x6803f857 -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep features +_qcow2_dump_header | grep features $PYTHON qcow2.py "$TEST_IMG" dump-header-exts _img_info @@ -107,7 +107,7 @@ echo === Create image with unknown autoclear feature bit === echo _make_test_img 64M $PYTHON qcow2.py "$TEST_IMG" set-feature-bit autoclear 63 -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep features +_qcow2_dump_header | grep features $PYTHON qcow2.py "$TEST_IMG" dump-header-exts echo @@ -115,7 +115,7 @@ echo === Repair image === echo _check_test_img -r all -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep features +_qcow2_dump_header | grep features $PYTHON qcow2.py "$TEST_IMG" dump-header-exts # success, all done diff --git a/tests/qemu-iotests/039 b/tests/qemu-iotests/039 index 12b2c7fa7b..8e783a8380 100755 --- a/tests/qemu-iotests/039 +++ b/tests/qemu-iotests/039 @@ -59,7 +59,7 @@ _make_test_img -o "compat=1.1,lazy_refcounts=on" $size $QEMU_IO -c "write -P 0x5a 0 512" "$TEST_IMG" | _filter_qemu_io # The dirty bit must not be set -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features _check_test_img echo @@ -73,7 +73,7 @@ $QEMU_IO -c "write -P 0x5a 0 512" \ | _filter_qemu_io # The dirty bit must be set -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features _check_test_img echo @@ -82,7 +82,7 @@ echo "== Read-only access must still work ==" $QEMU_IO -r -c "read -P 0x5a 0 512" "$TEST_IMG" | _filter_qemu_io # The dirty bit must be set -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features echo echo "== Repairing the image file must succeed ==" @@ -90,7 +90,7 @@ echo "== Repairing the image file must succeed ==" _check_test_img -r all # The dirty bit must not be set -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features echo echo "== Data should still be accessible after repair ==" @@ -108,12 +108,12 @@ $QEMU_IO -c "write -P 0x5a 0 512" \ | _filter_qemu_io # The dirty bit must be set -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features $QEMU_IO -c "write 0 512" "$TEST_IMG" | _filter_qemu_io # The dirty bit must not be set -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features echo echo "== Creating an image file with lazy_refcounts=off ==" @@ -126,7 +126,7 @@ $QEMU_IO -c "write -P 0x5a 0 512" \ | _filter_qemu_io # The dirty bit must not be set since lazy_refcounts=off -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features _check_test_img echo @@ -141,7 +141,7 @@ $QEMU_IO -c "write 0 512" "$TEST_IMG" | _filter_qemu_io $QEMU_IMG commit "$TEST_IMG" # The dirty bit must not be set -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features $PYTHON qcow2.py "$TEST_IMG".base dump-header | grep incompatible_features _check_test_img @@ -159,7 +159,7 @@ $QEMU_IO -c "reopen -o lazy-refcounts=on" \ | _filter_qemu_io # The dirty bit must be set -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features _check_test_img _make_test_img -o "compat=1.1,lazy_refcounts=on" $size @@ -171,7 +171,7 @@ $QEMU_IO -c "reopen -o lazy-refcounts=off" \ | _filter_qemu_io # The dirty bit must not be set -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features _check_test_img diff --git a/tests/qemu-iotests/060 b/tests/qemu-iotests/060 index db26c6b246..d1e3204d4e 100755 --- a/tests/qemu-iotests/060 +++ b/tests/qemu-iotests/060 @@ -80,13 +80,13 @@ poke_file "$TEST_IMG" "$l1_offset" "\x80\x00\x00\x00\x00\x03\x00\x00" _check_test_img # The corrupt bit should not be set anyway -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features # Try to write something, thereby forcing the corrupt bit to be set $QEMU_IO -c "$OPEN_RW" -c "write -P 0x2a 0 512" | _filter_qemu_io # The corrupt bit must now be set -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features # This information should be available through qemu-img info _img_info --format-specific @@ -114,19 +114,19 @@ poke_file "$TEST_IMG" "$(($rb_offset+8))" "\x00\x01" # Redirect new data cluster onto refcount block poke_file "$TEST_IMG" "$l2_offset" "\x80\x00\x00\x00\x00\x02\x00\x00" _check_test_img -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features $QEMU_IO -c "$OPEN_RW" -c "write -P 0x2a 0 512" | _filter_qemu_io -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features # Try to fix it _check_test_img -r all # The corrupt bit should be cleared -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features # Look if it's really really fixed $QEMU_IO -c "$OPEN_RW" -c "write -P 0x2a 0 512" | _filter_qemu_io -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features echo echo "=== Testing cluster data reference into inactive L2 table ===" @@ -139,13 +139,13 @@ $QEMU_IO -c "$OPEN_RW" -c "write -P 2 0 512" | _filter_qemu_io poke_file "$TEST_IMG" "$l2_offset_after_snapshot" \ "\x80\x00\x00\x00\x00\x04\x00\x00" _check_test_img -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features $QEMU_IO -c "$OPEN_RW" -c "write -P 3 0 512" | _filter_qemu_io -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features _check_test_img -r all -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features $QEMU_IO -c "$OPEN_RW" -c "write -P 4 0 512" | _filter_qemu_io -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features # Check data $QEMU_IO -c "$OPEN_RO" -c "read -P 4 0 512" | _filter_qemu_io diff --git a/tests/qemu-iotests/061 b/tests/qemu-iotests/061 index 9507c223bd..70edf1a163 100755 --- a/tests/qemu-iotests/061 +++ b/tests/qemu-iotests/061 @@ -55,9 +55,9 @@ echo "=== Testing version downgrade with zero expansion ===" echo _make_test_img -o "compat=1.1,lazy_refcounts=on" 64M $QEMU_IO -c "write -z 0 128k" "$TEST_IMG" | _filter_qemu_io -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header $QEMU_IMG amend -o "compat=0.10" "$TEST_IMG" -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header $QEMU_IO -c "read -P 0 0 128k" "$TEST_IMG" | _filter_qemu_io _check_test_img @@ -68,10 +68,10 @@ _make_test_img -o "compat=1.1,lazy_refcounts=on" 64M $QEMU_IO -c "write -z 0 128k" "$TEST_IMG" | _filter_qemu_io $QEMU_IO -c "write -z 32M 128k" "$TEST_IMG" | _filter_qemu_io $QEMU_IO -c map "$TEST_IMG" | _filter_qemu_io -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header $QEMU_IMG amend -o "compat=0.10" --image-opts \ driver=qcow2,file.filename=$TEST_IMG,l2-cache-entry-size=4096 -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header $QEMU_IO -c "read -P 0 0 128k" "$TEST_IMG" | _filter_qemu_io $QEMU_IO -c "read -P 0 32M 128k" "$TEST_IMG" | _filter_qemu_io $QEMU_IO -c map "$TEST_IMG" | _filter_qemu_io @@ -84,9 +84,9 @@ _make_test_img -o "compat=1.1,lazy_refcounts=on" 64M _NO_VALGRIND \ $QEMU_IO -c "write -P 0x2a 0 128k" -c flush \ -c "sigraise $(kill -l KILL)" "$TEST_IMG" 2>&1 | _filter_qemu_io -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header $QEMU_IMG amend -o "compat=0.10" "$TEST_IMG" -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header $QEMU_IO -c "read -P 0x2a 0 128k" "$TEST_IMG" | _filter_qemu_io _check_test_img @@ -96,9 +96,9 @@ echo _make_test_img -o "compat=1.1" 64M $PYTHON qcow2.py "$TEST_IMG" set-feature-bit compatible 42 $PYTHON qcow2.py "$TEST_IMG" set-feature-bit autoclear 42 -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header $QEMU_IMG amend -o "compat=0.10" "$TEST_IMG" -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header _check_test_img echo @@ -106,9 +106,9 @@ echo "=== Testing version upgrade and resize ===" echo _make_test_img -o "compat=0.10" 64M $QEMU_IO -c "write -P 0x2a 42M 64k" "$TEST_IMG" | _filter_qemu_io -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header $QEMU_IMG amend -o "compat=1.1,lazy_refcounts=on,size=128M" "$TEST_IMG" -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header $QEMU_IO -c "read -P 0x2a 42M 64k" "$TEST_IMG" | _filter_qemu_io _check_test_img @@ -120,29 +120,29 @@ $QEMU_IO -c "write -P 0x2a 24M 64k" "$TEST_IMG" | _filter_qemu_io $QEMU_IMG snapshot -c foo "$TEST_IMG" $QEMU_IMG resize "$TEST_IMG" 64M && echo "unexpected pass" -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep '^\(version\|size\|nb_snap\)' +_qcow2_dump_header | grep '^\(version\|size\|nb_snap\)' $QEMU_IMG amend -o "compat=1.1,size=128M" "$TEST_IMG" || echo "unexpected fail" -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep '^\(version\|size\|nb_snap\)' +_qcow2_dump_header | grep '^\(version\|size\|nb_snap\)' $QEMU_IMG snapshot -c bar "$TEST_IMG" $QEMU_IMG resize --shrink "$TEST_IMG" 64M || echo "unexpected fail" -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep '^\(version\|size\|nb_snap\)' +_qcow2_dump_header | grep '^\(version\|size\|nb_snap\)' $QEMU_IMG amend -o "compat=0.10,size=32M" "$TEST_IMG" && echo "unexpected pass" -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep '^\(version\|size\|nb_snap\)' +_qcow2_dump_header | grep '^\(version\|size\|nb_snap\)' $QEMU_IMG snapshot -a bar "$TEST_IMG" || echo "unexpected fail" -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep '^\(version\|size\|nb_snap\)' +_qcow2_dump_header | grep '^\(version\|size\|nb_snap\)' $QEMU_IMG snapshot -d bar "$TEST_IMG" $QEMU_IMG amend -o "compat=0.10,size=32M" "$TEST_IMG" || echo "unexpected fail" -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep '^\(version\|size\|nb_snap\)' +_qcow2_dump_header | grep '^\(version\|size\|nb_snap\)' _check_test_img @@ -154,9 +154,9 @@ _make_test_img -o "compat=1.1,lazy_refcounts=on" 64M _NO_VALGRIND \ $QEMU_IO -c "write -P 0x2a 0 128k" -c flush \ -c "sigraise $(kill -l KILL)" "$TEST_IMG" 2>&1 | _filter_qemu_io -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header $QEMU_IMG amend -o "lazy_refcounts=off" "$TEST_IMG" -$PYTHON qcow2.py "$TEST_IMG" dump-header +_qcow2_dump_header $QEMU_IO -c "read -P 0x2a 0 128k" "$TEST_IMG" | _filter_qemu_io _check_test_img diff --git a/tests/qemu-iotests/137 b/tests/qemu-iotests/137 index 4680d5df3d..52ee135184 100755 --- a/tests/qemu-iotests/137 +++ b/tests/qemu-iotests/137 @@ -140,7 +140,7 @@ $QEMU_IO \ # The dirty bit must not be set # (Filter the external data file bit) -if $PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features \ +if _qcow2_dump_header | grep incompatible_features \ | grep -q '\<0\>' then echo 'ERROR: Dirty bit set' diff --git a/tests/qemu-iotests/287 b/tests/qemu-iotests/287 index 2d5334e8bf..5427ad5456 100755 --- a/tests/qemu-iotests/287 +++ b/tests/qemu-iotests/287 @@ -61,13 +61,13 @@ echo echo "=== Testing compression type incompatible bit setting for zlib ===" echo _make_test_img -o compression_type=zlib 64M -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features echo echo "=== Testing compression type incompatible bit setting for zstd ===" echo _make_test_img -o compression_type=zstd 64M -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features echo echo "=== Testing zlib with incompatible bit set ===" @@ -75,7 +75,7 @@ echo _make_test_img -o compression_type=zlib 64M $PYTHON qcow2.py "$TEST_IMG" set-feature-bit incompatible 3 # to make sure the bit was actually set -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features if $QEMU_IMG info "$TEST_IMG" >/dev/null 2>&1 ; then echo "Error: The image opened successfully. The image must not be opened." @@ -87,7 +87,7 @@ echo _make_test_img -o compression_type=zstd 64M $PYTHON qcow2.py "$TEST_IMG" set-header incompatible_features 0 # to make sure the bit was actually unset -$PYTHON qcow2.py "$TEST_IMG" dump-header | grep incompatible_features +_qcow2_dump_header | grep incompatible_features if $QEMU_IMG info "$TEST_IMG" >/dev/null 2>&1 ; then echo "Error: The image opened successfully. The image must not be opened." From patchwork Thu Dec 23 16:01:40 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698486 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 91469C433F5 for ; Thu, 23 Dec 2021 16:21:38 +0000 (UTC) Received: from localhost ([::1]:35156 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0QqX-0004Ry-GG for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:21:37 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43384) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXx-0005t4-U8; Thu, 23 Dec 2021 11:02:25 -0500 Received: from mail-eopbgr150124.outbound.protection.outlook.com ([40.107.15.124]:2176 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXw-0005Js-Er; Thu, 23 Dec 2021 11:02:25 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Oi9ENKajAeWXjYuORrIrB7BdPd6EFMSDF+H6ynjAGis0Hs3UlXzXK0LD1HeXqqiu1oRtAassd5qN+CNffOq3UV2ApwCq9l+FFHBERiHloWUExWl6KgzWxLhNKpVI9vcY2ghN4NCwfQ9xH16QpZRh8+pJIQ8YuryEcVlR/iYgkK2kW/dur3554JpqaV5rUKS2rqbxroWPfv26loGy4isjbs04KCMNz+lfeHRFonbw2XW1HPa1ywNdDWi4G0lBpFPmzw55r69KP/2kP9Whz9sAbNsFp6D5aOr97KJjg5oA1GEM9AVmyft6v4p1y3TzDoN/BaMfKnd0yPRGBRkPLY8G3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=aNBEUzaEKpyy3EPJPJuLjstFxgZdcUWJxXmmbd+oSZs=; b=Rc8xoN1SBnB2lqticOvxvTzTF3iTS2Rbq6PX1rfigDLLwh3KM5uJ/OYMgkJp9khnaYvtdHcAFa1vvrUnvew/HIHX4jT046yRCaXlM8ehPbwwCeluFuA6hEjegQvKlhVwbN8Doq/Em9qcSl41dqg91xmm0o6q9r04H1yaEAe6D0GEpvt9gLV3crP77jluhKbyWA8no718G4DHypYRZi7BWFeuV4ra9VGmK/xfQQ1qEQG4p+fnKYOofpXxz6QUxscLi5Iqi1NcFwDaPl1FPE6YsE1MIHZzP6wCZU2k4hP1JzbVleWPU9q4O7rlgPMfJNkQIJFtNK5G3ggTwmawCjm7xw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=aNBEUzaEKpyy3EPJPJuLjstFxgZdcUWJxXmmbd+oSZs=; b=KCtTuOXlVXt2qEoDficQYh+nz5ZTJSNzw5PE5wtf3x4hg5X9q65YMbTH5l/lBsuMa3o5RSNtmBvPgXWoRf/S4qLA/9rDrbn/ydBUOtJxTu4R9OYX5PzRee6h4Eow0pkSQwXeq0NrIRdN5EQSYOmAvAdca71nwsnr7TpXpsxCLZ0= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:02:00 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:02:00 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com, Max Reitz Subject: [PATCH v5 15/19] iotest 39: use _qcow2_dump_header Date: Thu, 23 Dec 2021 17:01:40 +0100 Message-Id: <20211223160144.1097696-16-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 39102ebe-4d2b-4d5e-f6a5-08d9c62d8dbd X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:47; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 4VMknRlT/LyxPfG3u7zV6zOVqqh80NDpynbJQtLreFZXAWSk00ggyM4HucKmuc+Bdnl9QeZjnFVsKJLSbkM4C4hzXdQjE5EQ+C0U0qwMBsd/r7hSv+uSiJP5EE7GhDC7ZE8uAIrjSzpRU22m1mZNFW6Rsvhct7fuhdlRdkD2JGkAaUq0RPXXrJbL2iHgSe5b2J/QRHf6JL/pUwlF/fZ9mFX1Ctr5EsND3Tl4coQMNcJDuEM8hIS+bemq3JOa10n7vXnvLyIPs6s57blDMilHs12g4utlKf+ky036dMniELMk/S9OZyu+Z4RTctTE6Eo3ptHzDV1bklvzGnSRgYshez8E/6gl34TUBolpql7W84cmATj9B+u+Ga693PRtU/OyNzXTqLv/UnKuYAsKOpjOl0f7MwtWy66ChMtrmimglTSNCQWpy8yLTFBd+ehWsyEqDFxyb1YnN/bEYIDDU13sMGX3nCwT5Ymk+htci7JlKgRwnoPCcKceE+2GwhWlMFr01pXaj2GNH0o0KrzPo3Bwi4y6lIJUkRzTSQtOG+q4XOiviZVOIwq+faNbJQrHwtqpZ8eFh9XBxXJ9uzm6/3SQKGuiVwhekeZkWGyYTmkqFb0Xh38YxHRLtbYQtY/Ljf/38wQ1vdelSJVQ/7S8G9Jsw6M84gsiVN3ONQ9B6dMRJg6S1UXVLUm+kZ4v8qZNd9zwchts5pocfoVZgr7ff3nOAw== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(4744005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 7079WHfgFJkLSBw4cC//bat7ncC1MdiQn0cqX/O0opkTGI3K9akSB2NP6zYFfxAZrCkLCn2ZakG9BuDLPelOnxsvDMG1lwsB2Ed4s+9LMmuFTXFXTCA0PUOSNQQwrjCRwVvcpZ1dPHBWlINjxpZ5KOBZhdPd6vrVXH7286KLp7kx9qZDhw9z+A+ni9qbUJwYiWtRoCWbDi1Jbzn6D3r6E4u0qmY08grxv+WQBIphFeDFYCJwuW+o2OvrWh35NnV0vbj2ZS+3wC/ZPsvgAP/VhKAMgan23sVBkQAEBZ6BtuE+46Q4mxPatOCrn7DdDtPPUj3CivSj+a6SVx/YH6ILcalWsRGuUOco7Q3oidJY8kpeeN+JhubGjEHc9aTeiorXs47ms6n6yOWMhlz/yEr/E//n5ygA0O8j9N6CzdgzsoDvAntlQHZXDTjzXnFVZvJOiqoHSxqrDEdYUEPDlaQ4E0hY26LDQ9pHG3CKrzmMHERi/EoO6KwebsiLmB3k+WWGcGeZsTeJJtyd4HyIIXDuAKn72JPr1D1X7+aLGH4AQgfI+syTStjigEtoIB2tA8XNzJAX0Z9jd2xp9tYnH0UHCj2k0RAaIJj0Pfpa2jS2D24yUwejuBEwj2lV4VjGQsgOcTwxnmmc6AqWJSh+8dozDpOE40q1wBESzYMmeHKPMtdYK2ApGz/wo+/kOcJDurF+MQIuAyZTF4pkK9puSUbWx0cv5CHCcq69v+K3Up2Lc3uaM6D/sc5j7G0xYrGMannXyukuDklALIlvpEyBiXlD3qUtGuc4DH6PsVC85P3fvc0H3g7q3Vgkhx7vZEG9WuNy/rlA6xniM8k+4sRlxzIAuxrienDjxY43OnphT3TZKr5gr/P+rswxztDwwCyNeu82QwOxdITtO00eCzyFoor4gK8qBmcpxPrBiViV7kYNGVc36ZqHafrnqzcrBYtJKSTrrD28KG2zPPTi7ZbUmnRg9DUb/MpQspTkzn54mpPBo2xwis2iaCZ6vJT21/5PfFGI/lTcaa1PFX/bJvjg76iWW7vGtRpElCU+q+dbzfopbG5X1NgJm9N74Q4bLB0IX4uH5HSADmCx1sgqCCq8JGy1gkS3k/pQtVlP3TmFEOIokV8GVR6ZuSqwsLbeDuquB2saoAr8ERLCNhA0mn7Vt0ISjD402FIYtPT4eAqc/v0zsarVtKEReiPmJGv2toRzuzpko+nqN34TEBRRvpz/S/pMYGILa+i4DIXZ6MI4uH3Plsu92a+z7lAOi7d6u5J3T5w1MQklRqmX82y62tkO+PiGsD5c00UBpopWMuk8kTeRQvZpitBZlmoHvf0SnQ2LfN615+IXG79SNv/faVrxbuZiWK50cJSsS77v9UgUlW3wTKkxtP84w/nwWp1ezj4GawQFTq7cncSlZ7pjKAMEpiP9MlFiJ3EMXgiAHlZuAKPg1VR+7q8Ws3V15YHSVb3oef/rRikNlbSY2PpwKRck9EYoNzBK34LnVS5OmIWc22GunzYA8beAM/MAK2Hi2tW7jrSDX+Lbg7x7Umnnt0Dq3ixJAL33xCz7+rG9+L7xUalC060as1nvG6s4x8H9I/HAQXo42VBZemjVngpc7YuE1iCom7wiRsIZhrUlIDdyvIIfIbJzKcYTiCYLUVsxnfqyrgHG1ckfIXwo90UcyZozXWWz/bq1GYDho4lu8eE+0vzpDqw= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 39102ebe-4d2b-4d5e-f6a5-08d9c62d8dbd X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:02:00.4438 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: ESUBRW7Of3T6JGsbXPr2dPDKSGrtPv0tQjIdxbXZub2/3Vx3y8zbjwNj9sqfv5FzRFaLc/Dx/atLOJPRXIktbpVISUajrmNDJMtSdMfrmfQ= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.15.124; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" _qcow2_dump_header has filter for compression type, so this change makes test pass with IMGOPTS='compression_type=zstd'. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz --- tests/qemu-iotests/039 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qemu-iotests/039 b/tests/qemu-iotests/039 index 8e783a8380..00d379cde2 100755 --- a/tests/qemu-iotests/039 +++ b/tests/qemu-iotests/039 @@ -142,7 +142,7 @@ $QEMU_IMG commit "$TEST_IMG" # The dirty bit must not be set _qcow2_dump_header | grep incompatible_features -$PYTHON qcow2.py "$TEST_IMG".base dump-header | grep incompatible_features +_qcow2_dump_header "$TEST_IMG".base | grep incompatible_features _check_test_img TEST_IMG="$TEST_IMG".base _check_test_img From patchwork Thu Dec 23 16:01:41 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698485 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id F2900C433EF for ; Thu, 23 Dec 2021 16:19:57 +0000 (UTC) Received: from localhost ([::1]:58506 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0Qou-00013P-Rm for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:19:56 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43414) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QY0-0005yv-7I; Thu, 23 Dec 2021 11:02:28 -0500 Received: from mail-eopbgr70094.outbound.protection.outlook.com ([40.107.7.94]:61158 helo=EUR04-HE1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXx-0005KZ-Rl; Thu, 23 Dec 2021 11:02:27 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HvQpDgQzDG2yFxg7eads1odiI9A+cGHwYVfN69SeHVeEvKTzMrCKBl+ilgAExZZL//vw7O4q1B2WfaWR+Weo57GeoB1VQ4W9ahVcnnwhXRGtyPJZrFQCl9K6fQzdTVKuXSMaInZ4ZjgcqElloES155Krrdm24zAwrhr1lGjctRUhm+ao7ssVegdExeDoFs6ggZFdlOc4nMH/jpzUdQOLoB4DygS7YGz7LQgk+9t0k4bWI61m4vb6PGPrOJCbmr6U6v37p251pLNttj3y2Lar7SMHmJ2Gnx8YX3BZfsvgBaKaXM6v1Ws0IbWmqo8YQEncCM5Frd2tB4OXs7ajJE3WTA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=hXu3FmnQgyJT9YuFbr3lHECaL5vJaHc5sDd1ZHx1QRY=; b=C6cElHrW+kgVMKU9weaBYS6xAnUZi9UbUL1gOpkSUZoR4h/+D70kT1WzC4qpoCF3cG3mV77rhCx/k4cGkpMcmkcGRhQOzEjyMlvkMk4b4Z8PQj1vCEmyqlq5t3sieHXWsviHvY4WvNR5Qj4sIhz4RU5zk56Wew6FzOZNPDBqETO0x/EjOCcOvhjO7p/K/It9h6ph+kTq/FMYzoIIxiqfYWo4ndUxg2MBy9RmzlJtqVlIss/h6sIQSaWHpCrLo3dWS77UM+lnDiFtOECw4nIWKiB8SQIQgQox/wMBDsYgmG/IdHFvfp5b0VleCIi/mBaYRyvnUEMBq31ENqP4w3V6zA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=hXu3FmnQgyJT9YuFbr3lHECaL5vJaHc5sDd1ZHx1QRY=; b=HziHEFR/LwsiGKngc+AXq2qBx48hlFpEdDbZLlYr8lVnGoiGaUWqS8SDe2mfDKl0uHTBm/fwDN/mr/MsrAW1lmVvh8kbKp8E/7u9SWvTVnRhaMoCi+8hT8nh7s3iLJWWv3GRK3jIb9NX/Nrr9utI/T2iYoF/GWv/dTInwP//MpA= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:02:01 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:02:00 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com Subject: [PATCH v5 16/19] iotests: bash tests: filter compression type Date: Thu, 23 Dec 2021 17:01:41 +0100 Message-Id: <20211223160144.1097696-17-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 17f54069-d72b-49bf-ac0c-08d9c62d8df6 X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:2201; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Y8109oRm22qLai0kdu3iNi0udUh2Kr2bDshlm0h76BXeQTH2E65qlREfoQ8JeV+tjiopeMkUmqKW1LAOdAEQdy+o9COxEi3ZbeCQJWSgW+BTzrU/Z48Jh3DZv4AQDJ0oKqeNEZUqWmmQOI4as2lssGzZIFxBc7K0potm/7bMrzG9FfNlA3J4k9zknfg2E0ii9CQBR/l1qH7HhY6se9TLSSM18BAdFkOKTpezZphTKf8abg2fzt0xciu3getALznak+CBSJn8xdHT8ZsMTKCioVvxKc8WytUGwNCBCkSPQlN+nVHrQEduQAv/qAGqb2EB9LlJExE6+V8ZBZ+PINt1RS3wkNbxgb5iTlOs6Fwl0lBQLsICx+w/tGhXPa04AyhrCq/jEkJK1bAHEULWQW5d952G0wv7AlwOEjiuLw/SxSGh5DfcG3Ho4kxqCC905z3DsNxYl5mhLqY/oOtfKiIPcD4bIJ0dRV7y2ysNasYg+lM8vHC0hsvAwkV7HVhifHbK+qb8yyun5xNVB965N4vAkcGzGTSBFghKNuXoE+p7KsiOcy6+ok//m1GD6i7GI57egdLGiM6NsoaVEdWEMO0QLxLDDVdkbQQR/s3KoVyvOJW9CaIS0fh6G33DBXTgl8Y/O2h1W+OnNHSBTyzIcJASTpAoy4a5nHA7jNDRA1Qwa+Y6yEu7NVfmoklvUXQp3oagSYA2UkXlhpzHzJTyJfnt3g== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: xquit3CG+yMmRsaqAQhgAKG5Euu08REZXMMwjGs7GqkvoU62biURXvZnFx9QvXJo1s0bpoGLSKnSoz9ucxk8V0qqiVD9GAsSR7tsgl2Skx33RcQhw9pAIQLlWxQQNlMXFR4UejlVQ89T9mUeBndp4oLuiqdmmOo+yOM8oU7ucdumWeEs5jH7ROqU/6nk1K3SWejeApdn8r7X/XAqDl2z0StedX2JyIBjtUSMeqKCjbA8Hb6auXd4UEE0r8YyZQkVaWE1aXXZLZ8FcQ0oxmzKVg9yHZ1wX/zhfGYWPQnw9RPFq6lAhTWVrhuNrABaiR9Q+j/Gx87vWzTxXyl+agpkzqDKEtyWzmSSjgj3ROI1ySsLJ8mCBQnZyo1U1H64W7hWUGHMKOo4bq4e9ygyWB4UgKW5VFHewoGcvi6OA4A+qut78zOUdNrWMA5r7D/RpJ/XvOaqhHMzDPiOS3T+C6i+abnt72InXl4bzre4Erq5q9uZDOuHMTvBtnDPU4xnDCr2NLi6ZzHXSI2YRBAtVpypbV2haMQu8r6Ja2wv1ld4xi5svW80GEWSui+mx11fQ5+4oQow9Pxu9hkGcFIq8Gp+zH1hZsb/ngbkkiuIRNVPOIFNxykz3qikFCgfWtsGuQxk9pZMoypFFToJRyNxspMOL5Pg/TEMiW6L9purwgCBBKF5BwITIVa/OUD3bIqENKbdYgsEpTUJ7FrDi71cMCtw6DTe7US3B2uEWRMF7QX8AVKYye+8TF3jOs74+Oxe1FG1UxN4WPg/FaswjeME/DzlCDkY8xvOvv1fLCJfIF4INd1uST6ngW8OpmtOj0sCfuPxpDcDA4BZHOpmwqUOVjrBdDnLe15aRxclvjh1z3d9agnCFdIyQatZWatr8kfky05qUmSsFD7zXbfAFcjjPpiRl+Dr3wv+3sLKxymSY6nTpmnfY+Bu7jcNdCkKrAWKD9QmtmT7nSRaQZ/GkxXbzrNYSWMbw9nKFnJiUYie06SGzyCB9cA1uBr/2rToLhiVHNynAjyxd2xYBmzrp7U5trQ2y39JXOyJhABldIY73i0SKSH6uZG6WrYTA+wVSPGIhyCAqkxidlMkOaw+anS4apDz9du9gK6TymPk43QCgNFO3LdnNNF+KQIZH5JuGIsEBcglFUV0j2hgzq1EsgquyI41IWtiu+dmUc9s4/5LH8aTwh5xWqLhN8WDHT1peUSCl1ownV7ENVgzqegwO4btLEya6JR9WOVq/SulGcki9cI7YDnNz3wowV0dHDaYqCFY3LkSwJcJEGrsT08SPO3wY8cpZZRvKEzplbILf6BKe+bkP0p3cJADmfenhhKM9mjFpDWb0p4rFMNOvsNRvbmf9c1D1IxqcJqn7pWI9enRX4i/Q/Rg/llv9SyxasZxmu9+12SYxY+kV/tt6z8asCxIxzt41kGSMH1Jof5rOT5SCLyn4YfR4FDuAw+aeKl6ytTjSSEsnLD6L4LJo4IzfBBZ4NBa3YTKBB2j9H8xCubEQCZuoaxRZCMdBwoJhiSEU46sHu3XWK5QtZCf6xjhic0VYtNip6o89qP3h+ubPwfnMoP2PaQ3U06pz9wEp/RfXl+jJzp+YaoOoIaKQ26gNL9q7Qb6c8tMsx1TxPQHF89ThHNbdaKxy3bAD+fRVuwaYoKFxZNsepl6A2qtwW9iGcqusTsQo58hDQE7/tQZS/ngp0f0GHI= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 17f54069-d72b-49bf-ac0c-08d9c62d8df6 X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:02:00.8487 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: kSR5UtzjD6QGG7i9nGXkxaSaIYmUBAUwMCg1/BHah6i9oFS2nX7Uzz2k6+AfE8JBSfYoqV/L+vJkSF3K5gfZnJWiRUluF1G6J+ITGQXJX0A= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.7.94; envelope-from=vsementsov@virtuozzo.com; helo=EUR04-HE1-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" We want iotests pass with both the default zlib compression and with IMGOPTS='compression_type=zstd'. Actually the only test that is interested in real compression type in test output is 287 (test for qcow2 compression type), so implement specific option for it. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Hanna Reitz --- tests/qemu-iotests/060.out | 2 +- tests/qemu-iotests/061.out | 12 ++++++------ tests/qemu-iotests/082.out | 14 +++++++------- tests/qemu-iotests/198.out | 4 ++-- tests/qemu-iotests/287 | 8 ++++---- tests/qemu-iotests/common.filter | 8 ++++++++ tests/qemu-iotests/common.rc | 14 +++++++++++++- 7 files changed, 41 insertions(+), 21 deletions(-) diff --git a/tests/qemu-iotests/060.out b/tests/qemu-iotests/060.out index b74540bafb..329977d9b9 100644 --- a/tests/qemu-iotests/060.out +++ b/tests/qemu-iotests/060.out @@ -17,7 +17,7 @@ virtual size: 64 MiB (67108864 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 corrupt: true diff --git a/tests/qemu-iotests/061.out b/tests/qemu-iotests/061.out index 7ecbd4dea8..139fc68177 100644 --- a/tests/qemu-iotests/061.out +++ b/tests/qemu-iotests/061.out @@ -525,7 +525,7 @@ virtual size: 64 MiB (67108864 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 data file: TEST_DIR/t.IMGFMT.data @@ -552,7 +552,7 @@ virtual size: 64 MiB (67108864 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 data file: foo @@ -567,7 +567,7 @@ virtual size: 64 MiB (67108864 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 data file raw: false @@ -583,7 +583,7 @@ virtual size: 64 MiB (67108864 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 data file: TEST_DIR/t.IMGFMT.data @@ -597,7 +597,7 @@ virtual size: 64 MiB (67108864 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 data file: TEST_DIR/t.IMGFMT.data @@ -612,7 +612,7 @@ virtual size: 64 MiB (67108864 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 data file: TEST_DIR/t.IMGFMT.data diff --git a/tests/qemu-iotests/082.out b/tests/qemu-iotests/082.out index 077ed0f2c7..d0dd333117 100644 --- a/tests/qemu-iotests/082.out +++ b/tests/qemu-iotests/082.out @@ -17,7 +17,7 @@ virtual size: 128 MiB (134217728 bytes) cluster_size: 4096 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: true refcount bits: 16 corrupt: false @@ -31,7 +31,7 @@ virtual size: 128 MiB (134217728 bytes) cluster_size: 8192 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: true refcount bits: 16 corrupt: false @@ -329,7 +329,7 @@ virtual size: 128 MiB (134217728 bytes) cluster_size: 4096 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: true refcount bits: 16 corrupt: false @@ -342,7 +342,7 @@ virtual size: 128 MiB (134217728 bytes) cluster_size: 8192 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: true refcount bits: 16 corrupt: false @@ -639,7 +639,7 @@ virtual size: 128 MiB (134217728 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: true refcount bits: 16 corrupt: false @@ -652,7 +652,7 @@ virtual size: 130 MiB (136314880 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: false refcount bits: 16 corrupt: false @@ -665,7 +665,7 @@ virtual size: 132 MiB (138412032 bytes) cluster_size: 65536 Format specific information: compat: 1.1 - compression type: zlib + compression type: COMPRESSION_TYPE lazy refcounts: true refcount bits: 16 corrupt: false diff --git a/tests/qemu-iotests/198.out b/tests/qemu-iotests/198.out index 3952708444..805494916f 100644 --- a/tests/qemu-iotests/198.out +++ b/tests/qemu-iotests/198.out @@ -36,7 +36,7 @@ image: json:{ /* filtered */ } file format: IMGFMT virtual size: 16 MiB (16777216 bytes) Format specific information: - compression type: zlib + compression type: COMPRESSION_TYPE encrypt: ivgen alg: plain64 hash alg: sha256 @@ -81,7 +81,7 @@ virtual size: 16 MiB (16777216 bytes) backing file: TEST_DIR/t.IMGFMT.base backing file format: IMGFMT Format specific information: - compression type: zlib + compression type: COMPRESSION_TYPE encrypt: ivgen alg: plain64 hash alg: sha256 diff --git a/tests/qemu-iotests/287 b/tests/qemu-iotests/287 index 5427ad5456..6414640b21 100755 --- a/tests/qemu-iotests/287 +++ b/tests/qemu-iotests/287 @@ -61,13 +61,13 @@ echo echo "=== Testing compression type incompatible bit setting for zlib ===" echo _make_test_img -o compression_type=zlib 64M -_qcow2_dump_header | grep incompatible_features +_qcow2_dump_header --no-filter-compression | grep incompatible_features echo echo "=== Testing compression type incompatible bit setting for zstd ===" echo _make_test_img -o compression_type=zstd 64M -_qcow2_dump_header | grep incompatible_features +_qcow2_dump_header --no-filter-compression | grep incompatible_features echo echo "=== Testing zlib with incompatible bit set ===" @@ -75,7 +75,7 @@ echo _make_test_img -o compression_type=zlib 64M $PYTHON qcow2.py "$TEST_IMG" set-feature-bit incompatible 3 # to make sure the bit was actually set -_qcow2_dump_header | grep incompatible_features +_qcow2_dump_header --no-filter-compression | grep incompatible_features if $QEMU_IMG info "$TEST_IMG" >/dev/null 2>&1 ; then echo "Error: The image opened successfully. The image must not be opened." @@ -87,7 +87,7 @@ echo _make_test_img -o compression_type=zstd 64M $PYTHON qcow2.py "$TEST_IMG" set-header incompatible_features 0 # to make sure the bit was actually unset -_qcow2_dump_header | grep incompatible_features +_qcow2_dump_header --no-filter-compression | grep incompatible_features if $QEMU_IMG info "$TEST_IMG" >/dev/null 2>&1 ; then echo "Error: The image opened successfully. The image must not be opened." diff --git a/tests/qemu-iotests/common.filter b/tests/qemu-iotests/common.filter index 2b2b53946c..75cc241580 100644 --- a/tests/qemu-iotests/common.filter +++ b/tests/qemu-iotests/common.filter @@ -247,6 +247,7 @@ _filter_img_info() -e "/block_state_zero: \\(on\\|off\\)/d" \ -e "/log_size: [0-9]\\+/d" \ -e "s/iters: [0-9]\\+/iters: 1024/" \ + -e 's/\(compression type: \)\(zlib\|zstd\)/\1COMPRESSION_TYPE/' \ -e "s/uuid: [-a-f0-9]\\+/uuid: 00000000-0000-0000-0000-000000000000/" | \ while IFS='' read -r line; do if [[ $format_specific == 1 ]]; then @@ -337,5 +338,12 @@ _filter_authz_check_tls() $SED -e 's/TLS x509 authz check for .* is denied/TLS x509 authz check for DISTINGUISHED-NAME is denied/' } +_filter_qcow2_compression_type_bit() +{ + $SED -e 's/\(incompatible_features\s\+\)\[3\(, \)\?/\1[/' \ + -e 's/\(incompatible_features.*\), 3\]/\1]/' \ + -e 's/\(incompatible_features.*\), 3\(,.*\)/\1\2/' +} + # make sure this script returns success true diff --git a/tests/qemu-iotests/common.rc b/tests/qemu-iotests/common.rc index 5dea310ea0..9885030b43 100644 --- a/tests/qemu-iotests/common.rc +++ b/tests/qemu-iotests/common.rc @@ -699,6 +699,7 @@ _img_info() -e "s#$TEST_DIR#TEST_DIR#g" \ -e "s#$SOCK_DIR/fuse-#TEST_DIR/#g" \ -e "s#$IMGFMT#IMGFMT#g" \ + -e 's/\(compression type: \)\(zlib\|zstd\)/\1COMPRESSION_TYPE/' \ -e "/^disk size:/ D" \ -e "/actual-size/ D" | \ while IFS='' read -r line; do @@ -998,12 +999,23 @@ _require_one_device_of() _qcow2_dump_header() { + if [[ "$1" == "--no-filter-compression" ]]; then + local filter_compression=0 + shift + else + local filter_compression=1 + fi + img="$1" if [ -z "$img" ]; then img="$TEST_IMG" fi - $PYTHON qcow2.py "$img" dump-header + if [[ $filter_compression == 0 ]]; then + $PYTHON qcow2.py "$img" dump-header + else + $PYTHON qcow2.py "$img" dump-header | _filter_qcow2_compression_type_bit + fi } # make sure this script returns success From patchwork Thu Dec 23 16:01:42 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698482 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id EF22FC433F5 for ; Thu, 23 Dec 2021 16:16:33 +0000 (UTC) Received: from localhost ([::1]:50192 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0Qld-0003hz-1C for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:16:33 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43416) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QY0-0005z0-8E; Thu, 23 Dec 2021 11:02:28 -0500 Received: from mail-eopbgr150124.outbound.protection.outlook.com ([40.107.15.124]:2176 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXy-0005Js-HG; Thu, 23 Dec 2021 11:02:27 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UJ78YIbQr/xi/RZaL2NHOUXZtSlVsR2XJsHVWz93+VV90XbngRz1Mib1IK2tcUFGwIZO5Sd/ZimYQARyE3DUg/w9FNH5jvMdyGosyBG+odE8E7Oq0De3GA77iH1+Qu6bGosP4uZgFiJZzxEbx0toyzNIyXPWiZ24Lkg7DaiYsebZp+EQEpiJiqu/63RWGrAfwyJhAgdn6uTjOnEGI++jtu6oAi3rPt4ctPCS70MtsQmZpfUurCl3inqCm/JiqA574emKKInSmsU6mOY+3LpEUjMBXuThn26h4EHtSMGHMaSQzOzl9xPUF0fI1w/rsydPJugxlWYhJlFYtXo1KyvAFA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=5RU88eMYqH5FMqCplfNXc+E/GqCiMwnkaRc630GvQCs=; b=ikW4INPSgiLykYBdrIl5HOaEL3A6XbFB8scKgTlXEqrRPvpoTikUgIxG4d7t8PcUN+RM5hzmBPXn2OatQHg6EamJX8zRp2sPeSMBqFqI+G9+BOXQDBhhYYLmEIBpZ1S+sfkNcKevOchIfe01kMc5knT7Pi3rHg6WZRxBAd3VDdDP8Q7uzx5ryvw5EV6BOD9AdtnmXDm9Qdr8O1qaasHRDgAL8f9sCzquOhci2q2b6C0NqTnSutk/4vY5WS4xLLTENg8rG8gnr2h4RHx3OUyKL6HfWirrSBVaqXRnILnhZO9G44Sbce6RerW/uUC+5Ur2S8gSctSlMHvEYerVgdsw3Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=5RU88eMYqH5FMqCplfNXc+E/GqCiMwnkaRc630GvQCs=; b=jvcKlrdrQkW/emBxXnLU8HJRJrneUmUd79cnGFkAtizBvOTVQzoEiNByq8hBkg34vngqmY23nsz+8R1JFSu+dVvRdFgnNNLZuy9fKiVdwYbAeQgxgF2hwN+QV0egEthSfojQNo8TDfjjlcUDZYlLkfYgbHnJzTNUpUGwvnPZGhM= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM9PR08MB6148.eurprd08.prod.outlook.com (2603:10a6:20b:284::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:02:01 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:02:01 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com, Max Reitz Subject: [PATCH v5 17/19] iotests 60: more accurate set dirty bit in qcow2 header Date: Thu, 23 Dec 2021 17:01:42 +0100 Message-Id: <20211223160144.1097696-18-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: d987bfa7-5758-4694-93ea-08d9c62d8e32 X-MS-TrafficTypeDiagnostic: AM9PR08MB6148:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:256; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: rUjjLBRC8dQbojEwXZmsj0Af119b9OxG6mxvT+gpx7h/fRK/msHrpqUIaomNN+Bv+GKtJi+Y7bKb1jbRLuj5ivhEzskvpAvj+a92jMVj+prtRiCswKCNEgHMktO2WTTJpWK+/fS6vdrOZBWmo6g39qqWmfiT8TyxPqj1nQUACxqfY/ner+pBzwYeDQ6+5g6vc7WcFIk1Vrqp0XZUJkbI3yIPzkZwQm4ih7oMmsgTnTxJ4+JDFQKwg/XPozhDX7UPEJyfFH1dYQ0Z0xC2/oLCW/73N9rJ4nk+9hWAMa/mPnhAaPvy5jM2PIsCUfgEncQFdKrwA5kvVL7AF+xuq5diRzpom23MXEpQ6AGy2oFbCsIcvPwkzkJXqga3vu3fvjTKkzTKfhCjbmrNm8EMIjEBA97cSdCykCJYQYvuyOOoSaJKX5AFnXfh9iy2mebPPNIlPh5TnnjAMI/uA+kcp6uRlnpwaG2Uqg0kXKhva6ayh2RmmtzW+LFx4Ry9nz4SFuCfBGXl9Vw4sJq/3BLArgGcsnLI1m3QqpC1ure7OcJKjvNd34RClWp/Wq3n7fmaEziOYeEdja8Bb1IIc/ElLETmWA/Jx5D83M/+Jx3jDNlvLwnlXpTHjZ3EiHmYgx4PnIhND4yHL05lEDpdBSOHwD3/lC8/ulCD4qrHM8+K1xfSSOxzn/9k2n1NWpx9O8hXaASqHdrclE9mdrSFEVDpSAJzKdRnvt4H3FgdgxXFIi+4AXo= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(36756003)(5660300002)(8936002)(508600001)(38100700002)(66946007)(316002)(38350700002)(66476007)(66556008)(1076003)(2906002)(4326008)(6666004)(83380400001)(6506007)(2616005)(6916009)(26005)(4744005)(6486002)(6512007)(86362001)(8676002)(52116002)(186003)(14143004); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: wZ0rNEAW8Evm6kzwUQl3JKEeeftWAyouM5PH4lLvA5OUfZbYGPE1HZwsc6F0Fddzdj5esEwzrg07J0ylPN43jwfqG2oHB8/3T4u4gvBnuRh4BRvi23j8IUnOLV/F+9zEffNyWQxn6y60yN9ikGYjCTGABjGSDLBDygGaofbiVlP3JjsQJYJcA6tzFStBbbqiOegZUznRY+9nf8tf9Eyvz9opik9nz0dm/wU/iXGR4HN/VMGakH3ES1sRkviQ0pS8QRoGVejb+RZAlgiXgOU+KImOiBLKymDhZWz1/Nzjekr5hCGvizAtC3fm9+ywEDYv2dvXUO4UV89Cn6kT4fEcXOkLxMg/Q4RHcTUbQWBSSWzdirKtJOGurPxvdaf5kSifjNIs3gJgBUiBr0W3HjcQqEf/sYk4vwKpTKepA5EE0oS+CiLulIgEK73/Z2mOVn8QvF9VNzqngAt6Rl5wTA6FSUDEjGtOCg7pe6OulCbu6UXVcngoKY6m+wUDpKgVmXoEEgZcPCfB4lOyODw+W+a0PfSU5i+F3pjmj+2A41o/zDPPmoUYzrVejXNc3C7klc9exPuZuF9fnsK5Pl9T1vs26gwElRFeABB6JipTEFyNyDaaih0t2+8HsjubStRgFGtW6oY78Rt9+wRFU8VMULJRuZEZyB0BS8upwe8EgVaG3ogQscN/m3RSTcX1z8HfDJAR9wAm4V3ofgvepStP6WVpWQzrCNNfIpaEUeAp6muLqI+wp9LO1PqE5L995L26qhmwGQyx5emewVLWY/yos8PpTIAs8jVEQqe7UUCEdAB7JR2FabCnbTG1KHmb7xBbtAEj2f5hyM3Sg9r068hyzG5PWL7wSzEhn5N7ucjdei7QUe9HSAWsaSnXWlCfed2bbXPYnS1OfBJ7EKiod+lpep3eJpkNPd1EIKiPnXO7M5416u8zhvzgn+zQzGiJWUcoyLgYWtlKenUxwrqOtgSar1WnAGk6EYMDn0O78sNqn5NcT1Fluna8prxMNc4/Glj7hH80DVw1PFjM+SBvYVGUCnsjd7ExzMw4p/zzwMW4Q1O42xg7zzab8rhFTSpGz2/8AZrXFPlcjYu2U7cucHur09MYAoOggAUviEz6pEELkhuEqYbxKbRu4fxM5ybipoXj9wrUzBWnCzx6d/ys3JgHfAIU8pfvfJQv524q6hqVN1sLsSitGFSE7+i7Y3giHW3zZx6VLol68mOwwkvH1VHZ+Hd8hmYUD1r1+u710xvHXVWQI66JgnFIBZXAcg+ren0rF+3JW4HwL6T6U2xYrJuQtHDsTYiFwcB7BriZ9r7tOev1rAR+1DoyeDGkqja1aaGYbl5THM1sWRqKzJAc44ZJWktB6qYva8L2jRuCNlhwTWnbD0crGFgcvhGtD2EMoj07yQwud/y8pUv/I326aC42I4cHHTL698ROHT7XImRS8uewTfwNW8Y8R0In8dFix1A0dOAG9lpYeaxojNpHcMCRw9xPjJRDjFgfzySML7r6BS95Bz6taAZGZPWkUajujDTBIGeJXkYgTsWE+3yZ3j+RCqmzvokGB63TDGfmkEwx7VAq9cXM5RHp3FKr62zOn1oh62K7eASwIXLZwokaN5NOdt/fVfXyWQDFyaJBIp0Kkre7ycZtwgIJzrBTJ/rFbcXhkHA2avdSK3hbGt/meecr4d5bzgZvswrkkBWL1QV4+fto0wo= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: d987bfa7-5758-4694-93ea-08d9c62d8e32 X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:02:01.2705 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: zzb30PBrwP/ho8xdvwOSBrcYcyeAu041w09+S9RmStBRiGqf8v1qgmYxu4KG+cF1bnKfmKAMScDVvdu0xY/RiVmlvEdudZdMeky1Luq2Oto= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM9PR08MB6148 Received-SPF: pass client-ip=40.107.15.124; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" Don't touch other incompatible bits, like compression-type. This makes the test pass with IMGOPTS='compression_type=zstd'. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz --- tests/qemu-iotests/060 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qemu-iotests/060 b/tests/qemu-iotests/060 index d1e3204d4e..df87d600f7 100755 --- a/tests/qemu-iotests/060 +++ b/tests/qemu-iotests/060 @@ -326,7 +326,7 @@ _make_test_img 64M # Let the refblock appear unaligned poke_file "$TEST_IMG" "$rt_offset" "\x00\x00\x00\x00\xff\xff\x2a\x00" # Mark the image dirty, thus forcing an automatic check when opening it -poke_file "$TEST_IMG" 72 "\x00\x00\x00\x00\x00\x00\x00\x01" +$PYTHON qcow2.py "$TEST_IMG" set-feature-bit incompatible 0 # Open the image (qemu should refuse to do so) $QEMU_IO -c close "$TEST_IMG" 2>&1 | _filter_testdir | _filter_imgfmt From patchwork Thu Dec 23 16:01:43 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698473 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 65576C433F5 for ; Thu, 23 Dec 2021 16:09:44 +0000 (UTC) Received: from localhost ([::1]:59788 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0Qez-0007iW-DP for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:09:43 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43172) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXl-0005CG-Km; Thu, 23 Dec 2021 11:02:13 -0500 Received: from mail-eopbgr150094.outbound.protection.outlook.com ([40.107.15.94]:1607 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXg-0005Ky-4y; Thu, 23 Dec 2021 11:02:13 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=EFLvdOFlIWW0orY69KHwEkJZWTg7k6XbSYJ3Ibnqftd1mNBSNCm+qeJrPoZJD/9+fufxR81yEjZbj/4045uNH8WMnAw4pxVNEFCIM60bgFcA/YWKwcEcBU+/qA/IGGW/lvyKyOpIGx4KISTc0S8MJRWvcP5sw2G/UTZv0eny2nlMrw2tU79a7zWnc2Ja8SYr5DoDoDFIQF4KPk/S7lzTFyg0rEug75BUNTz92eIBzSs9Yc3TDKHpxHnAdXOOxbANnMeHOS2f+OVzJjYBy2a0KcNf/mKpu1g8O/fLPqegkKyczDlpP73IopUWsD5nJis540Mvz7YdHT7W/g+RvDhm2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=YBPMoASQarVNPpivG6QfxwVne5VyP6pZdhBUnZyQXb4=; b=GgXJPQEYiG+7/ZG+Yzjz/HebQrdh2WM674HWajBJqtXKeDEZarll4mflhPdPjtDbgeCYSCaWEt8WXVsXWnPCq/ujcXxV1caLjTLRbH6q6rlgYTr8Fsf0f5k2pmROHxMsWowlYsc+989cnfH+svstcm+XHv0gnB3BdrfJp3hFNMSP4Pondl0RS1kXLZFihKLaZN7SKLMi+ROONCOMHZLaQ9VOggYK8oE/ef04/6+OtRQKvwMQfJfQmRSpzQ6D/+tRSHdbYpajj8puM3NSOmL6UEhdxlrnzT5fsb+sJDBn1xpfxa47HHtKQPnlAd0NFWcPQpmnfNgnhTMVK46pwgiDiw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=YBPMoASQarVNPpivG6QfxwVne5VyP6pZdhBUnZyQXb4=; b=ds4bQzccYDI4HrGJWNkU/reyc58xuEfs6ea6Mbn3STQuUAzyAfgmJNNNpG5Ig5/x5578lHMaHeS2gCa2Xnq9Tdhr0niTtPMgcglrtzBPZo/bp4AZAXppYa+/KFFIWnvgUsYJFdx+5wOuNtFslVtReSqiT2AfZCJ2T/ejKOH8IAw= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM0PR08MB4147.eurprd08.prod.outlook.com (2603:10a6:208:12c::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:02:01 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:02:01 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com, Max Reitz Subject: [PATCH v5 18/19] iotest 214: explicit compression type Date: Thu, 23 Dec 2021 17:01:43 +0100 Message-Id: <20211223160144.1097696-19-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 3686b378-2d58-403b-f225-08d9c62d8e72 X-MS-TrafficTypeDiagnostic: AM0PR08MB4147:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:3513; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: CmPOdkUHzeqhJn8FS5qWnuEWU4RLC7J2OdsCTXIAe5n7KM9GUUPw57BbHlUoNN1JNwPs4EEoGxQg0uJIPrT+B5MkR4hiHDUcspa5lYjW9VsjxVy9m60GznEEgNQ0w4tD20umKKlTDN2tLuX4TLdrmZP40Aq+6AfollX4WB28jrz0eJ378YgYhgkMgddEgBM7J1czxh4bpdPh6udnlQNiBz3UiNvZTO6nbPCItBVgQ5C7a+83NIt0WC1MCdPqZFZCrLSKt+f/RW3EaVUSzoqePhdEoJmKcpUAyBaybiLNQtTsoCm1tYYqelPNwmSpccIAV006vrozIP5dhYyypenOLOMaDvpAUrJCmSrWisSuAv8aYFjaPDH1906zodvHJHeA8PAmbVGYrKSPh25ZrnM9iDU1bA84S7wcLvmVabehXqfnOdbhBfj7l/LlUPxJyrH4cLlm14KjUaEVYgwniUJ+QoFXGvMmY1M+0rKAW0xErqRHGIZm51IObnzTHTVq+dvk2QaDEewKP4/sgV/wDLQj3eaKuIFuscT/gYQPn9881YyfFoU9pZMMRr6nx+vzRqyr9k0/BbzDooafjL1uS+3XkFFUk5v68V5SqpzXJzDyn6alkI1OKGBJRD4D3NoHiETWNw4ljHIk2kHBuWSg840x2ShL/i4CWEZMx7+CGL070cvYn2AS255ag8TWJkkeSAmhA8YzNZeXdPWl1xVz2ZhISw== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(6506007)(186003)(26005)(36756003)(508600001)(2906002)(6666004)(86362001)(1076003)(8936002)(316002)(52116002)(8676002)(6916009)(2616005)(5660300002)(6512007)(6486002)(38100700002)(66946007)(38350700002)(4326008)(4744005)(66476007)(66556008)(83380400001); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: eMAAC0fr/2sWa4qZ5W25f3an7fsFp9tE5EKq5e4ZaWIdpv7aEgp1j/aCS5cWvYlzKJe3RKLRgYXqDSvrn0YDunvw/lthuG+je33iHud8jBpsq1+q+JHCGrj40S7p2QZ506qbgk6pWTcF5vA/X3sniXavbfFdA46SSRxxiO40KNmoEOiedtHJN5opPQUYSVwAoHPblnPsvK5ZAyk/+b03c64wu0tthNT/8AltnWDGQx87Rn3WLo7gFlSI6KCF6zisv54PvfzpfuOoBItFfLBRlg0PKVWD9qu4AMTvIQBfFp2NOmTyZuQKgBcSNgHyXkdx5hBm25ZbAeXcJiSUFoIDS9HveiZPl3p7bdY2bJzSWsdeFc6oMbCplcyqmBjE4E1XbLQ356Pi5qDMqdeY6ioGy3gaFa6DXdcfjvTA8O9QyzKAOkarcYtFv1OXRBGac/YQqTkZZ25muGysPIZ3jJAPSQiS+x9hXTyl/a7rlbvHAywrvFWi5/b1ljQpjA8NAPE2LDctyLfTxZb4/xLdqhV1RXr2OvrW4i4sAm/aPioTrkePy1ktTdLbxmccf5MiaFE+pf8Gt8reYvPmWAnLRvi2pGNYmSpDdOyjZD0SJmCDbDXT4000XPykpkm152i9RibpFbiy0AbjxPgxZNpwT4oK/FBAf9QfboRgs0t1V3OijGQn6+97fikvLW3AvvnuCcLCPeHpYhWDl5Hr/+2+Tn6ceiEL2dWcYbGUpBtX0YQI5SdGMFDludEOli+bGtVUzYtl1xR5E9VVPzkAGGA+4uiUY5xBFiAS8c0aHRd+Go9eiqyyuEebkY+hYfflgEGWHKuGH3H2tPZFkHzbLcfRSYT212lK0ZagivHWQLPDxkK9yFmgdE48yCnL3VN9ioiwik7w9M1K6in3/IJaQocJrlgtdH/xHfaiDGK9AA+PbFZbUCVe+aJM8WkPXV44dXk6K20l6PLuK/SkfewpbzJTjtr+/XArZTuKRdubBcdUHuyCborMW3jGJv3m+zgbBSWmMXA6fAJaVzkhJMTxiqJMfscAql6IpY9AQOdlUVDvXmomffQzZRMg0dyjwPIRG9HvRoRINFauv8mE0D+FfD1gMKwfoFgIw/D+uL0Wkazm/LLxrSPKA/tIrLAJdHgKqGeSMN8e8PnWyFecrCQMF1UyTaZafRhTliiwZZCV040f/jywSy32iX8GrdVcp36QFiQDMT/MBpdAxGCZHbq0Z9Xt4OYCsd3iN6fuQ9l6ayyiDPpKCma9cIYVxFDnkDPDi3nvVrEMQtbVsh3en2wir7b1ROzU3T3iB+8tIyR5NXdYFbkyNdy4v/z63caaUZXdHIu4W0RWTk0GyBmkihHBCQZfyohs9zP2VB+vNxf9Xm6q6Fu/Z9dOYHs29aEZcW8Ogp2kwnerCOW2SOIfifvlLCPbs9Eh+WcaBxsFu887/u9hgIQymLTBLAYb4lZypoYiiudoZTH74GLbYtava8NCKSsvR0ErpYZqKnvTkNXpOKqn+jtORCNuUynYVpqxV2F2NzRD+IVlhARQ4OK98Ybck4S4Bu5tGqbuCxNDFSUq/VXKLU3cftVA5YdJIiplFnoBmG9e/VbV93WKVuFd97lYc/XfnEbAJ85ZqC3lc4DzgKH27J7XJMykuqWSJ59k9EsVF+c0W1y/HWPk1QA7+Xoc8PmU28iOl/ArhD7HjzT5q5zq/rwgfUc= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3686b378-2d58-403b-f225-08d9c62d8e72 X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:02:01.6610 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 4uU2VVwvoH6UrlzxIrv8WaRA7atAjQiQ6uaSHNLiLM1FJ1zEXErPF0hw5BiTN8QtuS6jjhb54R6BgrxfmtBmhZrJENHeBwXQ+50NOPJXBj0= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR08MB4147 Received-SPF: pass client-ip=40.107.15.94; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" The test-case "Corrupted size field in compressed cluster descriptor" heavily depends on zlib compression type. So, make it explicit. This way test passes with IMGOPTS='compression_type=zstd'. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz --- tests/qemu-iotests/214 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qemu-iotests/214 b/tests/qemu-iotests/214 index 0889089d81..c66e246ba2 100755 --- a/tests/qemu-iotests/214 +++ b/tests/qemu-iotests/214 @@ -51,7 +51,7 @@ echo # The L2 entries of the two compressed clusters are located at # 0x800000 and 0x800008, their original values are 0x4008000000a00000 # and 0x4008000000a00802 (5 sectors for compressed data each). -_make_test_img 8M -o cluster_size=2M +_make_test_img 8M -o cluster_size=2M,compression_type=zlib $QEMU_IO -c "write -c -P 0x11 0 2M" -c "write -c -P 0x11 2M 2M" "$TEST_IMG" \ 2>&1 | _filter_qemu_io | _filter_testdir From patchwork Thu Dec 23 16:01:44 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Sementsov-Ogievskiy X-Patchwork-Id: 12698468 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 13DDBC433F5 for ; Thu, 23 Dec 2021 16:04:35 +0000 (UTC) Received: from localhost ([::1]:48594 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n0Qa1-0008Ry-Vd for qemu-devel@archiver.kernel.org; Thu, 23 Dec 2021 11:04:34 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43056) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXf-00050t-Az; Thu, 23 Dec 2021 11:02:07 -0500 Received: from mail-eopbgr150094.outbound.protection.outlook.com ([40.107.15.94]:1607 helo=EUR01-DB5-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n0QXd-0005Ky-LF; Thu, 23 Dec 2021 11:02:07 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Gc7K7bEPBgA4mHiuPwFrB51NCb4EwnsSdhVSZW75IbPM/FdfCtzJCNtz/g+aEeuBnr1+IJNC4Vkl08DYhzFP5axnySvmITXjlVvYfoBqRsiqA4Y0xh95U/Vbmv5Km45YG4wlPwK+syeMIKMMTEYdULrYvZ2jWj3RngxLnwp2rCYnmF91hwmkFKeo+FJ2zKnY/xdZlocLbvHdpMPa2myPcJ9yspL1aMIZXqmVT4pcj5wtBd6OQJk6MHiydFRb/8A3ZkLYBwiTgafhQpksmHSNUZZal8qSR0j0VFMqin10TvcuI8ywX681Gt7XPlKSbpLjtJxigSqvdwfbzUKZuC5uRw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=OMwXdZz7gBViyPMoWfGcrwQnD0M52NhNqrghnGxkZ4o=; b=PjKuB54fRaLLr1KLEWmhb2sjvE+KXmOExDAwKrm6G2TsOhkzqiwRzm/mldfxec2KtTy27qcWdoi6eTymOyZAGOdt+X2iJslS/mtZQ/oMnxmEZmJvwW1O/V65HZTCVyg/88UU9supAxoyPxFo6Z1LWYxdwpvyeCO7n/+Z+BuGm5GlT8eQjgv9m6ViyiBgtEb36kYQPPzaqmiNr+0WG2npRhlEiO8wy8BMjpMdwUNEebYarb6BKyQNvPfvaBu5YutdDnd4sKrKbmpzai2rzr1LLgOTvjA/0FfH4DpTDraEl54Kk5dvTsL15ZuvyNP415mLZJSLQuocRQUVGD3zGIhc0w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=OMwXdZz7gBViyPMoWfGcrwQnD0M52NhNqrghnGxkZ4o=; b=al6gwt770dnkCPdS0sLudc2PC9gkXY1KqQvffunY1qEhLq9eOgDHR2AaHEgkOsTTR13mHqAFfKqBjNaOoEhZdvVFHLTrUXbbGikkjYGelKOlmCjdGuGCkaUtyDZtD9OmZwSlu8pmSFw8ZGBsfWSVz22U5zIC+GM3ejy8ZHPxmfw= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) by AM0PR08MB4147.eurprd08.prod.outlook.com (2603:10a6:208:12c::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4823.18; Thu, 23 Dec 2021 16:02:02 +0000 Received: from AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112]) by AM9PR08MB6737.eurprd08.prod.outlook.com ([fe80::b118:483a:d003:3112%5]) with mapi id 15.20.4823.019; Thu, 23 Dec 2021 16:02:02 +0000 From: Vladimir Sementsov-Ogievskiy To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com Subject: [PATCH v5 19/19] iotests: declare lack of support for compresion_type in IMGOPTS Date: Thu, 23 Dec 2021 17:01:44 +0100 Message-Id: <20211223160144.1097696-20-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211223160144.1097696-1-vsementsov@virtuozzo.com> References: <20211223160144.1097696-1-vsementsov@virtuozzo.com> X-ClientProxiedBy: AS9PR0301CA0001.eurprd03.prod.outlook.com (2603:10a6:20b:468::8) To AM9PR08MB6737.eurprd08.prod.outlook.com (2603:10a6:20b:304::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: b9a010c1-6d38-4cc4-2630-08d9c62d8eac X-MS-TrafficTypeDiagnostic: AM0PR08MB4147:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:8882; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: oSekYwJ6C29hAINBH63sIOemiq3HjpCv4/bJQ2oNbn+P4R8MGF5uuC99k6JHb60e2n0Q0IJp7PYkFynSE9Mg5dXiQEiBOTGPWlB5bc3U650TzVv2BI4caDaT7x7mUuEIEz8LR6yb6WThOpOQE0xkSCDx9XH9xdiG0aksgLxLjFkNrp6rESMGW5ZJ6NeBwUNePXgkjYp8+J6iF9lpjpLK1Mzq13oLnQu8cVcg2LSvp17/JLzwmjH0ykz9EOuodzAiXnF/DwEAoF0mA/qI3u7d2nmq/ii7mDOvzNUB9AxERcuCHZhawAiDIALHkvPhC72AP14MFhnamOWexgnyaPDLwjffPoVg5blEIp0YL2VJPF4a6M7k33HpaFqhDtGrW9hQOSPgnPmC5xsfewcngarsn1s0ZZKDdkjhTDTk2xj2pSYkMds/1GWssI9PUrefuH3asJr3LiVEQjyGllfmVlw3U5wC2nnoK0gcIXc9iNmEX6Dd18lJVoHbeaLDwi/azXkO+wbkUwC2jkYTg/R2xQFyldxWZCg21Ci4zldE6XcUUL7kF1pH3F+mCU3GqxZg36v2o0YVgSe5E4K3zu0tRt+4u2bsNPSu4vDtK527t3zTnUDhLEjguxXZuZsLyK+KwwR3lLidCpEO3F78DaRn7F4+tg+/Yn6APTxO5qFPMFxWrvd64xNxWnz7i6WyEPl3qHmD5jAaZKdzhdKDywpK6qtVPQ== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM9PR08MB6737.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(6506007)(186003)(26005)(36756003)(508600001)(2906002)(6666004)(86362001)(1076003)(8936002)(316002)(52116002)(8676002)(6916009)(2616005)(5660300002)(6512007)(6486002)(38100700002)(66946007)(38350700002)(4326008)(66476007)(66556008)(83380400001); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: pUxeYnSbzrFbxM37o0XQowdj5SZsWo8XboNS0YopCdaNxJgRc03tZviz1iD5cb+MDFDjOL4Zi8lyTaX6u3rUe2iQ+VXMbJkF6VFm4qVMucPyYtVwZYBheHiCtsZLQNkXrYmZl5V1ptThs2ZqLsmvjto0tCWPnAL2/yq+rvEvD/zw93xK70ke8L9EB5PdaT/Gca2zYoz6HQSRsJrm9mk5qzRiGwZKuea6FwUSx7Qnr0V7Vw6cVpkk+OM2Tl/4nRRfL/hcL0pWipmLlg4c2IuV1wykezW/eQIeuDDZXBcdNkbykdMTxaAiHFne/0mOdNBPpt6Ky5h0REO6wfjqHyS4RQuSqsLiv89U+3IifnE83lRzXlM3vg5BCHxw51XWaVDc5MN5sS0sY0O3ah3PsecwVG8eUeSakhdw3+nGFJvqzAsxZriC4MTollr6Joz1zBhS2yfujha2vmzxtz9E/ol/yfhFG6vtuY3tykQLfh8j+V/rZbVL0c/XVtxVrdAf27PiIM+BXV/hmVi10C7lTcsBPSUDY2WvxT0g9JBW+R1gLrC3uoxlbDPPTQBq6vbfokm2QhfbQ33klFPYcpFzIHnE1Qp8/oi8uOiDZjKbKKPu2rMZtsRu5MzScZd0HsS/j+4j5Vu7wDyjIrQ0DJALBz5YAxcMmu90i3O62RXSwdVMfnDDMYkKNlDgQLijnAsCEdjNZJ42fadTmhJZIfS+t4N5766ttpxG8X1wGCYuqfHFceHGdivH8d++PniACLeHVMotEqoHlToUEHYRT4/8l/7m9f6kQZWpLxdlnXWwgQu+XjOfgYd/uXwpKV934wtliUxbWD0ZFeFr8Y4dAETkQsNdcW+jkBJyz1Utf8Dk9dip3nOlKj3pndLrDS3JaQnxLB372EHZlGaV0Q0VUiyRg67Z2hWKk0FDCGodtmyzgXPm4NdxdIPuXL8naanbVj0nNhS0hL0YL9cZGKFe0mxPlMq7zz/r6KHD8ri5L83FTSm6vAwbGjkWvdkyGdPbK+LzmXePBFeBhQYxDfYSpsWtFTtCzwT1w7Dmd/EZubvDbwYp6MjlY+HTA3mnttwr9kxO7FRETzHJ4Hc9sdqKj3XhXiTkWIaHlSngXNgjuz+cXmOOL6t7thUefPM5vaMNRwSr0WecyjLeZi3mubeOtMR6OA0rokWrcC/qNjHVKOxU+RDl+ywfGFOae0Sjuwm9cwuaQaqH0avDjT4KUJMU5lfRyWfqhgEn0eU3cD5CgNHb5Zvyu4/j9XC927nohKk65orNRxMRHoCyYsvszyVaIithNo9sjrQg1l/61r+NG35pNEfk2Tody+/7cmjT+nZoNdh9Rhf2m+TUJbNWo9iiX9nadbDmuikH1r1vdMhlyTJeAx/J2suHV8Tiw+I5x/S+Nb5czghycCSwE2fa32x9ZmMCgppxRhQ78WGXKcu2d2fNg+6DJlj7pzCsow45/8V/7JFQr/TUpjLcpWLqvtr9BPmW2jT7/5/7xjo2r/vJ1k5xuQFNjXQdW2nUEWZWYi3OaUH9PhMamwJMpeKP5FnNQuRGzvq7PqlpnrPHTWmcE9AP0IQGEivHEJPnQGBr21jQwXp8StJM342X+fFpIUVPTtPwp4lCX5SLSWYRk+rPOzHl5nljLm9OrOtbqH81CphQ9muY5eNRCn30vv5hYUsJroPowNCHC1tUvZCocp6dPFFa+sAk28g= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: b9a010c1-6d38-4cc4-2630-08d9c62d8eac X-MS-Exchange-CrossTenant-AuthSource: AM9PR08MB6737.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2021 16:02:02.0204 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Gzw2TjUbjNt54dTYBYkwKS0IhkGHqTysnPSSsopEszl5WfiK9BEQkG5KOR/lT/KRPh9b0mhvlfjjPzxaM3Wl+0/4aC/Us2coruRIX3tGLsw= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR08MB4147 Received-SPF: pass client-ip=40.107.15.94; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-DB5-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" compression_type can't be used if we want to create image with compat=0.10. So, skip these tests, not many of them. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Hanna Reitz --- tests/qemu-iotests/031 | 5 +++-- tests/qemu-iotests/051 | 5 +++-- tests/qemu-iotests/061 | 6 +++++- tests/qemu-iotests/112 | 3 ++- tests/qemu-iotests/290 | 2 +- 5 files changed, 14 insertions(+), 7 deletions(-) diff --git a/tests/qemu-iotests/031 b/tests/qemu-iotests/031 index 648112f796..ee587b1606 100755 --- a/tests/qemu-iotests/031 +++ b/tests/qemu-iotests/031 @@ -42,8 +42,9 @@ trap "_cleanup; exit \$status" 0 1 2 3 15 _supported_fmt qcow2 _supported_proto file fuse # We want to test compat=0.10, which does not support external data -# files or refcount widths other than 16 -_unsupported_imgopts data_file 'refcount_bits=\([^1]\|.\([^6]\|$\)\)' +# files or refcount widths other than 16 or compression type +_unsupported_imgopts data_file compression_type \ + 'refcount_bits=\([^1]\|.\([^6]\|$\)\)' CLUSTER_SIZE=65536 diff --git a/tests/qemu-iotests/051 b/tests/qemu-iotests/051 index 1d2fa93a11..da93587039 100755 --- a/tests/qemu-iotests/051 +++ b/tests/qemu-iotests/051 @@ -41,8 +41,9 @@ _supported_fmt qcow2 _supported_proto file # A compat=0.10 image is created in this test which does not support anything # other than refcount_bits=16; -# it also will not support an external data file -_unsupported_imgopts 'refcount_bits=\([^1]\|.\([^6]\|$\)\)' data_file +# it also will not support an external data file and compression type +_unsupported_imgopts 'refcount_bits=\([^1]\|.\([^6]\|$\)\)' data_file \ + compression_type _require_drivers nbd do_run_qemu() diff --git a/tests/qemu-iotests/061 b/tests/qemu-iotests/061 index 70edf1a163..513fbec14c 100755 --- a/tests/qemu-iotests/061 +++ b/tests/qemu-iotests/061 @@ -48,7 +48,11 @@ _supported_os Linux # not work with it; # we have explicit tests for various cluster sizes, the remaining tests # require the default 64k cluster -_unsupported_imgopts 'refcount_bits=\([^1]\|.\([^6]\|$\)\)' data_file cluster_size +# we don't have explicit tests for zstd qcow2 compression type, as zstd may be +# not compiled in. And we can't create compat images with comression type +# extension +_unsupported_imgopts 'refcount_bits=\([^1]\|.\([^6]\|$\)\)' data_file \ + cluster_size compression_type echo echo "=== Testing version downgrade with zero expansion ===" diff --git a/tests/qemu-iotests/112 b/tests/qemu-iotests/112 index 07ac74fb2c..5333212993 100755 --- a/tests/qemu-iotests/112 +++ b/tests/qemu-iotests/112 @@ -43,7 +43,8 @@ _supported_proto file fuse # This test will set refcount_bits on its own which would conflict with the # manual setting; compat will be overridden as well; # and external data files do not work well with our refcount testing -_unsupported_imgopts refcount_bits 'compat=0.10' data_file +# also, compression type is not supported with compat=0.10 used in test +_unsupported_imgopts refcount_bits 'compat=0.10' data_file compression_type print_refcount_bits() { diff --git a/tests/qemu-iotests/290 b/tests/qemu-iotests/290 index ed80da2685..776b59de1b 100755 --- a/tests/qemu-iotests/290 +++ b/tests/qemu-iotests/290 @@ -41,7 +41,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15 _supported_fmt qcow2 _supported_proto file fuse _supported_os Linux -_unsupported_imgopts 'compat=0.10' refcount_bits data_file +_unsupported_imgopts 'compat=0.10' refcount_bits data_file compression_type echo echo "### Test 'qemu-io -c discard' on a QCOW2 image without a backing file"