From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.openvz.org (mail.openvz.org [69.168.225.77]) by lore.virtuozzo.com (Postfix) with ESMTPS id 4656B8045D for ; Thu, 29 Oct 2026 11:28:15 +0000 (UTC) Received: from mail.openvz.org (localhost [127.0.0.1]) by mail.openvz.org (8.14.4/8.14.4) with ESMTP id 69TBQxCW032247; Thu, 29 Oct 2026 14:26:59 +0300 DKIM-Filter: OpenDKIM Filter v2.11.0 mail.openvz.org 69TBQxCW032247 Authentication-Results: mail.openvz.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=virtuozzo.com header.i=@virtuozzo.com header.b="NoE/Ef+o" Received: from mail-yw1-f200.google.com (mail-yw1-f200.google.com [209.85.128.200]) by mail.openvz.org (8.14.4/8.14.4) with ESMTP id 69TBQvGb032243 (version=TLSv1/SSLv3 cipher=AES128-GCM-SHA256 bits=128 verify=FAIL) for ; Thu, 29 Oct 2026 14:26:57 +0300 DKIM-Filter: OpenDKIM Filter v2.11.0 mail.openvz.org 69TBQvGb032243 Received: by mail-yw1-f200.google.com with SMTP id 00721157ae682-8b0cd41e7aaso31260707b3.3 for ; Thu, 29 Oct 2026 04:26:57 -0700 (PDT) X-Gm-Message-State: AFq9FYLV3NGzbx9X7ROPHPeKEX4/wY3uJkKUH48GlGWQKSF9r5SmLM1l 2Dz40STrsrVc6oHWuQ36Pz47PWjkJVeFTOjYUmNoYWYDNWODNfdswNXiOkbAsMUwfwh6+wsX6Rd nOItDMr4EzVdbaeNl/yMhBW4CpZVmVNxtwmEBOPFpNpWXG8LXgIBeww== X-Gm-Gg: AYBFou2qM1WLm2XqFNMN1K6/1CqiTlHs9DZ3fALwD9m4M3k0EmpMkXxOrECOyFmIGjy mauaHtCEKiMWtebPPsZx3kMdgyKBoRVBYHja483dkHXRAw4nLnmRVRjRdVENaAAKD1rvXLcUeVu FV7xw2LENtp8Z7cCJ++J7DjWlA16wI9+qwwaVKNgGN7SLlsZTKeY6QcUIjbHuSoTtH7az/lHZyK fBWzaDbJejUJmkJKh5EX/DCVVCgr3+KB6T/Y8V7O38A7az3Raj4gc0DwD5yPLVtZYWmY+etKYmD GBDrva40Wzvzh++zRrvaZhrMD44f7Zu658Q2sSH34hHO/XpGt5NADHS7BYd3EKbS/JkUJsH1mBS jo08Hg5CqItu4uEuDh57LeyHx3law58zVr5kaLRK8dxsHzl/07YSeLMNUtfZslPweMUVAgo+KVI +h80ank6UPM4TQLDVWHfGCmzg= X-Received: by 2002:a05:690c:6605:b0:8b0:c5bc:e87c with SMTP id 00721157ae682-8b1b5a56bf7mr34469457b3.6.1793273216531; Thu, 29 Oct 2026 04:26:56 -0700 (PDT) X-Received: by 2002:a05:690c:6605:b0:8b0:c5bc:e87c with SMTP id 00721157ae682-8b1b5a56bf7mr34469337b3.6.1793273215953; Thu, 29 Oct 2026 04:26:55 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1793273215; cv=pass; d=google.com; s=arc-20260327; b=kcUpMmeja63vnLDc75fJ0AAPIZaej2JkU7zd3p0wV29pMQt9tFb6HxORfX4cQIPce8 /4uyBnKgMuTTQQqia2Bbq8EqfLoq90VAXa8d8bebZPg/rNV3jqiK2TzFkd/Q5C4LO+Ml KmKPy4KloZtoo5axzVRLeVQJVCCK/Sb4lwEeykXSLc+nbvNVMUBpB/MqRhJwS29qNcgm l01yXlFNEc+B15AYjH3QTkL5wWCH79fgapvaVBe8tNSQe4ULTWi3Zmdh7zUqlvWQRqIS txXhjuzksw8E+Ef8ARjqYyqVhf+vClBYZS+gl4EkhIn9WHGacj54vBD4HOC8JsxuTLBG PBdw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20260327; h=mime-version:content-transfer-encoding:in-reply-to:from :content-language:references:cc:to:subject:user-agent:date :message-id:dkim-signature; bh=Dh5NFQVtz2u0QcOdot9thmA0mnTeVPWyzKeyvYsiAbA=; fh=0MfJN6E+yYtoDS6wSzByq06HeILO+USFAMhb0iCYnt4=; b=TOpHWX26OWn3dQmmj7JwDPXtpGJiIieTKP8skLh00FnTDtiNfQNHcpOz+578tmU5Bh CiBy+VzUkHR96H21BvKl3mr5JxEmn9GV1IDgpMPjID8NaCxpd+8OuZNbiKk2sQGVrScj fGR57UZiUt97OEQ8pxajIbfBz2dysPG5GbBGNA0BtrH3kj0gaNMAYEd/nPzZ2vcJetnq Nw2UhnZPCy809OFbM3XgaR9L7sqL79M0p/LoHVgfhj+aXFslzouafBpSm0jtuEbyNGEH 3YrvQ+Pwa4WHzs0nVPibf5IXfGt6G/I8EdxoVa7T7n/uLR+Aw7CI/xFGcrdOyUNosnx6 b0Ng==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@virtuozzo.com header.s=selector2 header.b="NoE/Ef+o"; arc=pass (i=1 spf=pass spfdomain=virtuozzo.com dkim=pass dkdomain=virtuozzo.com dmarc=pass fromdomain=virtuozzo.com); spf=pass (google.com: domain of khorenko@virtuozzo.com designates 2a01:111:f403:c20a::7 as permitted sender) smtp.mailfrom=khorenko@virtuozzo.com; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=virtuozzo.com Received: from PA4PR04CU001.outbound.protection.outlook.com (mail-francecentralazlp170130007.outbound.protection.outlook.com. [2a01:111:f403:c20a::7]) by mx.google.com with ESMTPS id 00721157ae682-8b19e640bfbsi53546217b3.151.2026.10.29.04.26.55 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 29 Oct 2026 04:26:55 -0700 (PDT) Received-SPF: pass (google.com: domain of khorenko@virtuozzo.com designates 2a01:111:f403:c20a::7 as permitted sender) client-ip=2a01:111:f403:c20a::7; Authentication-Results: mx.google.com; dkim=pass header.i=@virtuozzo.com header.s=selector2 header.b="NoE/Ef+o"; arc=pass (i=1 spf=pass spfdomain=virtuozzo.com dkim=pass dkdomain=virtuozzo.com dmarc=pass fromdomain=virtuozzo.com); spf=pass (google.com: domain of khorenko@virtuozzo.com designates 2a01:111:f403:c20a::7 as permitted sender) smtp.mailfrom=khorenko@virtuozzo.com; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=virtuozzo.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=sc0rMFBvSo/GQirWO9IdyWCbCLJ25W4GqKRlodX0hNZUOx6TPbOPfglewIHTNzY1U28AjX4yT0mWrp1rMS45ChKybONoGHXN+qITjQh9MutWjHuIcjddFnR0AukBrI3vMuCNzDPDF3tR8wWR0BPyRMuk9iB4QeYeH7gOxZAvLP/NpakXB/ZzHjlavMuh1SylZXO2FLwRWcTNwXGByjSVXwO2BZCfdc2KbttjX7jXS3/rRMdGKG8FTLBM8oB6YU3VPuw2r081zKeHpkg9f11qUvfruCD9NUFSL1UgmN3UT2xt6Omnj4fHlVqy6vJUy7jyhmlXKEl6zuj4HBB1FBFHXg== 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=Dh5NFQVtz2u0QcOdot9thmA0mnTeVPWyzKeyvYsiAbA=; b=v4IYOww/XiTRCnZt8+BZxFbKum8AdSsUcPAZabK5g71TMSBI6BLNqSI6VG4ZICs37OMZN2Uj4zW/HOjPHK+MzbREstOOAhjsjSZeRmw2Qc0jEnvNH4fq5+4wyG6Hb8VTEfKzdOmeGEF+jcUqJYFyA2xmcInuUSEPf1VhiP/bE1R7nmVkC+JdIClR2P2ycXHO2TwE10jXPDt/UElHWj+1vMXybgAyYlBH0hzBy7xWdHLtWH5SAgaIscRZ0O5gAtwioe/ZgBJ/M1BEt1y5e8ANrFfeFUbc3fvCrQ8o33IPjfix9Do+4/6nwJ5KTx86KUHMjRq0tqfUkv4BydnGE+xKMg== 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=Dh5NFQVtz2u0QcOdot9thmA0mnTeVPWyzKeyvYsiAbA=; b=NoE/Ef+oOqrtg1jZIcGJylWDHSQH4ebQ2etm1fH+08jAPThC611xm9sqpHcD/6KITlEniis4ajk1VkgY8ePnFMJtqPx+IRR+z41Xjlr5BPxkaXn7pGTYznsdc3w0BSuIc76RPqb4q4k57D2Qjw2I0geoDZ+3HbxYhA+9RVQrM3EiuDzcLaPtyF67o2aBVDPrfn8BBflDJSxyNLbKVCYeJOb8iYAMPN2PI/1wWPV2e+0j/llAeDHySPjuictMurQ3vnUxvuTVjl1swHkpPmSgyapQzlT7rM9ct5DFVnSAkqBbGcn8F2UIykyKn0vDgiXdK7mQlVt+C4XdoBMDmlIuWQ== Authentication-Results: mx.microsoft.com 1; dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AS2PR08MB9075.eurprd08.prod.outlook.com (2603:10a6:20b:5ff::9) by DB3PR08MB9109.eurprd08.prod.outlook.com (2603:10a6:10:430::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.569.9; Thu, 29 Oct 2026 11:26:50 +0000 Received: from AS2PR08MB9075.eurprd08.prod.outlook.com ([fe80::3f57:9ced:7a37:1bd8]) by AS2PR08MB9075.eurprd08.prod.outlook.com ([fe80::3f57:9ced:7a37:1bd8%4]) with mapi id 15.21.0569.007; Thu, 29 Oct 2026 11:26:50 +0000 Message-ID: <2f39ce07-cf48-4ebe-af40-58f3ff78587a@virtuozzo.com> Date: Thu, 29 Oct 2026 12:26:49 +0100 User-Agent: Mozilla Thunderbird To: Alexander Ivanov , andrey.zhadchenko@virtuozzo.com References: <20261021084610.1476738-1-alexander.ivanov@virtuozzo.com> Content-Language: en-US, ru, sr From: Konstantin Khorenko In-Reply-To: <20261021084610.1476738-1-alexander.ivanov@virtuozzo.com> X-ClientProxiedBy: AS4P189CA0004.EURP189.PROD.OUTLOOK.COM (2603:10a6:20b:5d7::7) To AS2PR08MB9075.eurprd08.prod.outlook.com (2603:10a6:20b:5ff::9) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AS2PR08MB9075:EE_|DB3PR08MB9109:EE_ X-MS-Office365-Filtering-Correlation-Id: 37db54c8-f6ba-415a-1f5e-08df35af865e X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|376014|23010399003|1800799024|366016|5023799004|56012099006|261026140227099003|261026121527099003|261028144727099003|10067099003|261022105027099003|261021135927099003|261021121427099003|18002099003|22082099003|6133799003; X-Microsoft-Antispam-Message-Info: DfQpieUzzUus9yWuHy8cuAN2/6+Oe+v5RrKlVJPcrk8c4iSJjd3I4FfU4n4G8lAPfRlw/dPdiafyTcmO69UYbjEIS7xwd6yrg9K8bo2+fosFotOi8SOQFlVCZyhhO7oy8Oaw3GRO0z3nSL3iJWwpuw6PQ8uoqYEqKWNlW+PUje2hRB27xG7SztmKpzEkc/WshIlb1XFSLhraBaeV/BPmIV2A4zGzcwyXLgtUV/3vCHLpqdoTsu807N4YS+tcCCeR4KcJ/EJy0LK6wZPWOA2ncMfT1OM8rteBsNRQ62CVEEL+50/ibNdy/mdyEKHLHlUN4Bq/Ot+sFCPYYO7qSMtqHbEDfL1NaFUs8AJ1pp0gmTpJPxfwRelW7R/BqE2baAarbkaJRqUp1SWA/NCVZ6Axs6xYHx+7W3aWC5Gt9YlmAFzxEv1QSyPdXk0LiKrCWmBOt2LjVEPCLmRIK/mXRb9+o59LMIJ9tNnJ28ISFbIsKyKChojswJ/Jp6680QrBtjpDC6qdzcP1jKeVu7Ix2otDK/bgzdeE1WMce9VwCcKRcEaQR+Y/4CGh4EaFpjmSQBNDDsY//K4oEoyOauo0tpnY9p3ZtRS4l+S00mUhkuOaPwk+I+0DlPEVY+C7dwaJGJg/IE7sJ+jyE9TWKJWDjZNsjSpFoVCDMD0/M0BSY4482VY= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AS2PR08MB9075.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230040)(376014)(23010399003)(1800799024)(366016)(5023799004)(56012099006)(261026140227099003)(261026121527099003)(261028144727099003)(10067099003)(261022105027099003)(261021135927099003)(261021121427099003)(18002099003)(22082099003)(6133799003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?aWZyZUkzemRmeGoxMDNoemtvN2dtblZtMytLeHpmMjBOY0JvTDh3YVhDa3k0?= =?utf-8?B?WkVEaklrZnVrZDY1aGttbWMvSmNFZ3NxK0ZSVEk1dzU1clB5bjdDWkRqeFZL?= =?utf-8?B?SnBaVWR3cDVqOVRsWVZ3bUNzSFU2SnprMHRaYWV6UWI1OTdkcmU0WWxOTzN0?= =?utf-8?B?VVRkQXNOb0puYnZJcGRwY2VycWVGMUtqaE1NWStyTWtrOEZuZ0Zkd3R2em9m?= =?utf-8?B?NlI1RmhFM2dvL3dMTy9UVDFTalJ6Rm1LM25GdTM0L1p1dDRLckt6dU1KbUEz?= =?utf-8?B?M0J6SlowYUtYTTN6a0UzTy85L3k2ZlN1NDRMMk8wQ2gyTE5NNGMyK3hsZ2Z1?= =?utf-8?B?L0VZQm12MnZLYXFKSldpSHZlM1dUU212UWJ6YjVvbnpmTnpCWmlQVWg0MHEx?= =?utf-8?B?enFzNjVVRUpTZ283aGs1VHNLQ2txUVV1RGQ2alVSb2E5UzJndDFyZ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ZWhVNC9oT09BMkxOcUxNZ2hQNDFESFlsRUph?= =?utf-8?B?NVd3RVdJR051Zzk4UmZkSHpxZjlWSE10NFpDb3NwSzRKa000RkJKUT09?= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 37db54c8-f6ba-415a-1f5e-08df35af865e X-MS-Exchange-CrossTenant-AuthSource: AS2PR08MB9075.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 29 Oct 2026 11:26:50.1127 (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: 2cqiQF4ySOQ2iiokSUBeWMz9HQAEp04uhgv0y96KLIoosWoo3Fvst6ryoin8dFvbWFJTmfjGNv99qBVhcqNrxg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB3PR08MB9109 X-OZ-Fwd: true Cc: devel@openvz.org Subject: Re: [Devel] [PATCH hci-8.1 0/3] drivers/vhost/blk: fix virtio-blk request header and payload parsing X-BeenThere: devel@openvz.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: OpenVZ development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: devel-bounces@openvz.org Errors-To: devel-bounces@openvz.org Hi Alexander, The code in all three patches is fine, I have nothing to change there. Two commit messages describe the old behaviour inaccurately, please fix them in place for v2. Patch 2, "take virtio_blk_outhdr only from the readable part": > The request header was moved from the whole descriptor chain, so a > chain with no readable part, or one shorter than the header, had header > bytes read from buffers the guest marked device-writable. The "shorter than the header" case was already rejected before the patch: VHOST_MAX_METADATA_IOV is 1, so move_iovec() fills one target segment and returns -1 when the header does not fit into the first readable iovec, and the kick handler drops the chain as "too split". Only a chain with no readable part at all had the header taken from a writable buffer. > Those bytes > were also trimmed in place from the writable segments, shifting the > status byte and the READ/GET_ID payload taken from them. The status byte did not move: it was taken as the last byte of the chain after req->len was computed. What shifted was the start of the READ/GET_ID payload, by sizeof(hdr). Suggested paragraph: The request header was moved from the whole descriptor chain, so a chain with no readable part had header bytes read from buffers the guest marked device-writable. Those bytes were also trimmed in place from the writable segments, shifting the start of the READ/GET_ID payload taken from them. Patch 3, "take req->len from one side of the descriptor chain": > Complete a read or write with VIRTIO_BLK_S_IOERR if its payload is > empty, above ALIGN_DOWN(INT_MAX, SECTOR_SIZE) or, for a write, not a > multiple of SECTOR_SIZE. Such requests used to fail in bio setup or > hit a WARN_ONCE() and leave the guest request hanging. Drop the now > unreachable WARN_ONCE(). Three things here. "Such requests used to fail" is true only for the empty payload and the unaligned write. A write above ALIGN_DOWN(INT_MAX, SECTOR_SIZE) was never rejected before: req->len is size_t, the bios are split per BIO_MAX_VECS and used_len for a write is one byte, so it was submitted as is. The bound is a new restriction for writes and the message should say so. For reads, the in_len > INT_MAX check still runs first, so a read above INT_MAX keeps getting -EINVAL; the new bound only covers the range below it. "Leave the guest request hanging" understates it. On -EINVAL the kick handler breaks out of the loop with the descriptor consumed and notifications still disabled, so with EVENT_IDX the guest never kicks again and the whole virtqueue stalls until QEMU resets it through error_ctx. The WARN_ONCE() was reachable from the guest: any write with an unaligned length triggered it, and with panic_on_warn that panics the host. That is the reason for the Fixes: 02ce37f62707 trailer and worth one sentence, "now unreachable" is a side effect. Suggested paragraphs: Complete a read or write with VIRTIO_BLK_S_IOERR if its payload is empty, above ALIGN_DOWN(INT_MAX, SECTOR_SIZE) or, for a write, not a multiple of SECTOR_SIZE. An empty payload used to fail in bio setup and an unaligned write hit a WARN_ONCE() reachable from the guest. In both cases the kick handler broke out with the descriptor consumed and notifications disabled, so the virtqueue stalled. Drop the WARN_ONCE(). The size bound is new for writes: the readable side had no limit and a write of any size was submitted. Reads above INT_MAX still get -EINVAL from the in_len check, the bound only covers the range below it. With the two messages fixed the series is good to go, no code changes needed. -- Best regards, Konstantin Khorenko, Virtuozzo Linux Kernel Team _______________________________________________ Devel mailing list Devel@openvz.org https://lists.openvz.org/mailman/listinfo/devel