From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <010701a0f2156310-702ae6dd-d7f2-4bb8-a01c-9f4bbdf1c8a2-000000@eu-central-1.amazonses.com> Received: from AS8PR04CU009.outbound.protection.outlook.com (mail-westeuropeazon11021075.outbound.protection.outlook.com [52.101.70.75]) by lore.virtuozzo.com (Postfix) with ESMTPS id A81F0802A7 for ; Wed, 30 Sep 2026 11:31:27 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=rFTnJKuMA55pUAcroRYaOT4J14IlXY7Wh+njPOqFkCNapDlAMFnFDWDhOoXw4sAMda3eNbwNWCF5vR9cCc0QW9Aqaz4WNCzxTLD2XHTAZnifFwOSTfw3teIIeIHfXcm/ecBGNWV/hldb9Oaswz9vgQfnldKA34lSfecrq8kVuASpqFHIjopM5sJAlprFWp62nDhZYwXDTIB/pOvtnkZCkEUb9WK6p9JmaflLt4ybSyRsn8Cl5k49VshgLR2Z3qz98xIQQpD1lDYJuu4Xuiyhfn4O5FU36UDrVh5W9RCXCpLWSfZ8/ffaKbapYfkFIerEVwTSwP785ajWgi+9PgmtzQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=KFlHjjOSR16AfQj1Rl4PCXMNPtb/2B9LF86pFl3iGMQ=; b=gBc/b2h1QL7o2dnlO78rt9Ynq8PBZVXr4VsnGu1svAzGvx8khRj0G4QAn6yX2Jnj2vvUySaK63JNaTt6sZzSmU8PjwRJFU6KK9ppmy7I2ay+4HbTA25TxOvNTO/P/yfnOUpbvSDOK9f8UyqaxPXFnC8NLIcmX0NHLUui5uQF/85tDnQe+BW2P+2A4XlqfNr1CPjmz0ynx5J30r142IdLtZx34YK7t9rqEEr+hG9zM60k2rqz4nRQq12Yc+QSkCDzm/g3GRmQ+Crgecc/ZCDCIfWCrbu4gy5uBr/GI7jyno95Ig75jXCA/gsbAW4o28FJTAKhHfzv2qcaazpUFc3Wtg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 69.169.224.6) smtp.rcpttodomain=virtuozzo.com smtp.mailfrom=eu-central-1.amazonses.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=sashiko.virtuozzo.com; dkim=pass (signature was verified) header.d=sashiko.virtuozzo.com; dkim=pass (signature was verified) header.d=amazonses.com; arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.onmicrosoft.com; s=selector2-virtuozzo-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=KFlHjjOSR16AfQj1Rl4PCXMNPtb/2B9LF86pFl3iGMQ=; b=f+N2Ie5Yw7qeRoMrdXuxXx0oCLngm0Mle65ZQwPDhEMNeQ5zBXWhdMk6C3L2W9zv5VeWSCUDqM7dQ6wuCbjhvpr5xtR3wVR48YkGQ/YPRmweqajqzTlJh4xDIGuMfbBUQozVTil+RpL0iHUAlv29+89M9HFL1I+0bMq7LaHd1Tg= Received: from AS4P251CA0011.EURP251.PROD.OUTLOOK.COM (2603:10a6:20b:5d2::7) by PA6PR08MB10565.eurprd08.prod.outlook.com (2603:10a6:102:3ca::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.472.14; Wed, 30 Sep 2026 11:31:23 +0000 Received: from AMS0EPF00000569.eurprd02.prod.outlook.com (2603:10a6:20b:5d2:cafe::59) by AS4P251CA0011.outlook.office365.com (2603:10a6:20b:5d2::7) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.472.16 via Frontend Transport; Wed, 30 Sep 2026 11:31:23 +0000 Authentication-Results: mx.microsoft.com 1; spf=pass (sender IP is 69.169.224.6) smtp.mailfrom=eu-central-1.amazonses.com; dkim=pass (signature was verified) header.d=sashiko.virtuozzo.com;dkim=pass (signature was verified) header.d=amazonses.com;dmarc=pass action=none header.from=sashiko.virtuozzo.com; Received-SPF: Pass (protection.outlook.com: domain of eu-central-1.amazonses.com designates 69.169.224.6 as permitted sender) receiver=protection.outlook.com; client-ip=69.169.224.6; helo=b224-6.smtp-out.eu-central-1.amazonses.com; pr=C Received: from b224-6.smtp-out.eu-central-1.amazonses.com (69.169.224.6) by AMS0EPF00000569.mail.protection.outlook.com (10.167.242.119) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.472.14 via Frontend Transport; Wed, 30 Sep 2026 11:31:23 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=23yjbh4k34hwzfubhuiim7m4inbd3ick; d=sashiko.virtuozzo.com; t=1790767883; h=From:Subject:To:Cc:In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date:Message-ID; bh=yIUDJWeNVXcOYlvfdN7KM5kOAsDIj/iaWcmFVlq0Dp8=; b=rROIwSwcc4HZYfABZeis8wc0ds6xfR8KSEIjoK5tvGZcrjJyki+rnCXKLQ6CLHJ8 pJxaAC5JWr7lM48xWgnAkqUAwgc5qtXfBtWN+NoYqEKH+af6pF9qyNpJWFKN3FTTy4+ PIkHMpzifDI0OXy9uvRHQOf6xDxPHYEwTDFzMAiRND1MBdFQHdZiH0NOJrW5D7jwAR9 yMmdtQv1ldDVQcFAteYlvnT/l3e5AbFmuBzik85+GG92WuGQ39vwl4nWF0rCkhnpqmH mSWEAeocRH/cWFS3Xnd85OKHBziT3abihc9jie7VnQkFhKTnDgkXOGclGzCc6L9m7zT JCQQec/D1Q== DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=sokbgaaqhfgd6qjht2wmdajpuuanpimv; d=amazonses.com; t=1790767883; h=From:Subject:To:Cc:In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date:Message-ID:Feedback-ID; bh=yIUDJWeNVXcOYlvfdN7KM5kOAsDIj/iaWcmFVlq0Dp8=; b=IhaT28SKmxo5a+5at9uKCLx9RNjXOI714DRtRWQ1HKaasxhywWucgp/vy5p3/lh0 OLduZTH0qE/sJMvmFRWI929aDYjVUiczb1hsdsPqfuH1869gumoGIh2LSRkE/OKDb2N eLxVyHWSm4An9YMCfXy+e3/neqFufXTZUUf2jKN4= From: no-reply@sashiko.virtuozzo.com Subject: Re: [PATCH hci-8.0 4/9] iotests/124: cover backup of zero clusters and holes #VSTOR-134085 To: svt-core@virtuozzo.com, "Denis V. Lunev" Cc: andrey.drobyshev@virtuozzo.com, den@virtuozzo.com In-Reply-To: <20260930111739.3866427-5-den@openvz.org> References: <20260930111739.3866427-1-den@openvz.org> <20260930111739.3866427-5-den@openvz.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Wed, 30 Sep 2026 11:31:23 +0000 Message-ID: <010701a0f2156310-702ae6dd-d7f2-4bb8-a01c-9f4bbdf1c8a2-000000@eu-central-1.amazonses.com> Feedback-ID: ::1.eu-central-1.2wRQJBpg9g1fGRYexx3dUuYGS25Bux+2TEOx72/m6U4=:AmazonSES X-SES-Outgoing: 2026.09.30-69.169.224.6 X-EOPAttributedMessage: 0 X-EOPTenantAttributedMessage: 0bc7f26d-0264-416e-a6fc-8352af79c58f:0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AMS0EPF00000569:EE_|PA6PR08MB10565:EE_ MIME-Version: 1.0 X-MS-Office365-Filtering-Correlation-Id: f076198b-340d-4001-18d2-08df1ee65b6f X-LD-Processed: 0bc7f26d-0264-416e-a6fc-8352af79c58f,ExtAddr X-MS-Exchange-AtpMessageProperties: SA List-Id: svt-core@virtuozzo.com X-MS-Exchange-Transport-Rules-Loop: 1 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|9140799003|48200799018|61400799027|376014|32142699015|10067099003|4113699003|56012099006|5113699003|6133799003|4143699003|5063699009|13003099007|22082099003|55112099003|18002099003|16102099003; X-Microsoft-Antispam-Message-Info: qwreTZ4B+sYyT5kZoRCvVyOeoT4qHJvYNBtYsPWNpZR89KL9Laub8rthl5ZiuCa7866ptu1IDaQcmBEfizg73yHcoXdUTfb/Ha0PDVjT5V7YlX2AMRJxoQJ+WrpXvab0LqhUjANXwvl6kS6U7ccWSvV7HrP0tEeP4u2sSoVlXg+2FrEFAn2oZYBgIhP0nlXJuSS6k3XB7Qiq0fSdE+nw7cK1g1KoIpEq2WWOQBhkanAcvwTEmCTJR+nSQM/FG/7Fv9BWCbIkJ3Bg5gVFclmjbyEPG4fv7wNZHweQwDlY2h2qxWhjhDXIx1QBE7X06RaryYhTzZDR203SwKeL+iyfRk+HgtX0BMdionSZRE8j2zmiH1h4PlEDaC1qhNoTnvd6LvwEEb/ifBAyABJ+gZ9LbyGy/qbmUW4s0wSvfd6qc1XKEb5M+Zta9UZbnI6bh9c2EJpZn8DKi+Muv/NVcrXXktJnu8hBp+T6QfOHrP7weztoP4WgL5xoGwTMGpSQTdjfCIcODsr5Mtv7+5zbL8+mmmejVAqUISCsi9dMiLdKvSaumtisa2g9ecm5o8fvvWDflEM1Z1XoQ3zPXYwyuAK7k2REPKkjVcnR5nrVnLSR5wsT7t2IcTQwflsZFUzpHthkVQJNkdDk7SIXwUNr0DUaZ/6BbHfh/AvXz+HtdOHP1dqegh88Zcce8TXHp6G80LKydbvhwaz/FD+oe/csx5A5lxLjvTdizm7G7w0SD0IYoDxHgxfCLLKJQHkpqLLh/K7LoyGzB+6Y4DZqjkSOtw3GySAVRCM2t+glHBT7RZErFjgP1VwaDpO7U+21JJD7aMfc3KT6elXM3arE4QzPmmGp7rbDg5hCTXa3K+CO96I4/YElOZ35L5N1I/zVs2P0vXOR X-Forefront-Antispam-Report: CIP:69.169.224.6;CTRY:US;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:b224-6.smtp-out.eu-central-1.amazonses.com;PTR:b224-6.smtp-out.eu-central-1.amazonses.com;CAT:NONE;SFS:(13230040)(9140799003)(48200799018)(61400799027)(376014)(32142699015)(10067099003)(4113699003)(56012099006)(5113699003)(6133799003)(4143699003)(5063699009)(13003099007)(22082099003)(55112099003)(18002099003)(16102099003);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: ebZDr/YIX/g8Oyubi2cXB8YTx5v2fJNo82Bt+IiIRYh29IdnMv94XOpFiVz29lbE4jubu9DcZeCc6IKFGpFymLe9bU3NoiUrACVdmLwlXTrkAFt02/2ZPz0tS+QrzVJjzFkWuFXAKnLrFrZpIlefkzWPFRaDGW/SnsSVxIlvbE+z6pfc/Qv31C+4sa59YfaJ6KUvmanJgOJGgzyRxgWQ/bGuKNYphAoRDm/mHu8Tm9z0LAqNNklT9BCZYrO+he2XN2BcEcjfWY4OZ1Sb6dQNptOjpgxo/nJ4fOpXqGI3rxQfpbve1BXRtX0TDUzuXjC7aWigyOkTakVp/kSMV60vXdWQ0s/BnipkmRLhjKHAophM5LsdUCw5IvM9xoq1GpyTaJ5AxD4JbMET3s4FOHRBf9wsMktLAt+K1wVYR4BVb7mlGlvLSYQrhf+fWm/ncz2t X-ExternalRecipientOutboundConnectors: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Sep 2026 11:31:23.4617 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: f076198b-340d-4001-18d2-08df1ee65b6f X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-AuthSource: AMS0EPF00000569.eurprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-Transport-CrossTenantHeadersStamped: PA6PR08MB10565 Thank you for your contribution! Sashiko AI review found 1 potential issue(= s) to consider: - [Medium] iotests: 124 TAIL_ZERO tests expect behaviour that only appears = in later patches -- commit 147936f45e8ec1c124ea1a5b3dbf035c9a679b89 Author: Denis V. Lunev iotests/124: cover backup of zero clusters and holes #VSTOR-134085 This commit adds iotest 124 cases that back up sources mixing data, write-zero and holes with sync=3Dfull, sync=3Dtop and sync=3Dbitmap. It che= cks the target layout with qemu-img map. It covers boundary, large-zero, tail-cluster and mixed-cluster cases. > diff --git a/tests/qemu-iotests/124 b/tests/qemu-iotests/124 > --- a/tests/qemu-iotests/124 > +++ b/tests/qemu-iotests/124 [ ... ] > +# A zero run past the old block_copy_chunk_size() 16M cap. > +LARGE_ZERO =3D Case(48 * MB, [ > + (0, MB, 'data'), > + (4 * MB, 32 * MB, 'zero'), > + (40 * MB, MB, 'data'), > +]) [Severity: Medium] The comment about the old block_copy_chunk_size() 16M cap refers to a chunk-cap removal that only lands in the later patch "block/block-copy: coalesce write-zeroes tasks". Is this comment accurate at this commit? > +# Image size not a multiple of the cluster size: a partial tail cluster. > +TAIL_SIZE =3D 4 * MB + 4096 > +TAIL_CLUSTER =3D (TAIL_SIZE // CLUSTER) * CLUSTER [ ... ] > +# The partial tail cluster falls out of zero_bitmap, so it copies as dat= a. > +TAIL_ZERO =3D Case(TAIL_SIZE, [ > + (0, MB, 'data'), > + (2 * MB, TAIL_SIZE - 2 * MB, 'zero'), > +], [ > + (0, MB, 'data'), > + (2 * MB, TAIL_CLUSTER - 2 * MB, 'zero'), > + (TAIL_CLUSTER, TAIL_SIZE - TAIL_CLUSTER, 'data'), > +]) [Severity: Medium] Can test_tail_zero and test_tail_zero_bitmap pass at this commit? The expected 'data' extent at TAIL_CLUSTER appears to hold only after later patches in the series. block/block-copy.c has no zero_bitmap at this point, and git grep finds it only in block/mirror.c. The zero_bitmap is added by the later patch "block/block-copy: track known-zero source clusters", and block_copy_mark_zero_prefix() there marks only QEMU_ALIGN_DOWN(zero_count, cluster_size). The tail cluster then falls outside the bitmap and is copied as data. Here is what seems to happen at this commit. TAIL_ZERO writes zeroes from 2M to EOF on a 4M+4096 source. qcow2_co_pwrite_zeroes() skips tail handling when offset+bytes equals the image end, so the whole partial last cluster becomes a zero cluster on the source. block_copy_block_status() then reports ZERO for the run and rounds it up to the cluster size, because offset+num =3D=3D s->len. After that, block_copy_dirty_clusters() selects the write-zeroes method: block/block-copy.c:block_copy_dirty_clusters() { ... if (ret & BDRV_BLOCK_ZERO) { task->method =3D COPY_WRITE_ZEROES; } ... } block_copy_do_copy() calls bdrv_co_pwrite_zeroes() with nbytes clipped to s->len. The request ends at the target EOF, so qcow2 again skips tail handling. The target would therefore report a zero extent up to EOF, while assert_map() expects a 4096-byte 'data' extent at TAIL_CLUSTER. The assert_map() comparison should fail at this commit and pass only at the end of the series. That breaks bisectability. The later patches that make the expectation true are "block/block-copy: track known-zero source clusters" and "block/backup: pre-fill zero_bitmap for full/bitmap". This was found by static reading and the tests were not run. Also, the commit message says the tests pin how backup treats zero clusters and holes. Is that accurate for the TAIL_ZERO and LARGE_ZERO cases, which depend on behaviour added later in the series? Could these cases, or at least their comments and expectations, move into the patches that introduce the behaviour? --=20 Sashiko AI review =C2=B7 https://sashiko.vzint.dev/#/patchset/2026093011173= 9.3866427-1-den@openvz.org?part=3D4