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 C2DE6817FB for ; Mon, 16 Nov 2026 15:42:44 +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 6AGFfWT2027379; Mon, 16 Nov 2026 18:41:32 +0300 DKIM-Filter: OpenDKIM Filter v2.11.0 mail.openvz.org 6AGFfWT2027379 Authentication-Results: mail.openvz.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=virtuozzo.com header.i=@virtuozzo.com header.b="UmlU4vRg" Received: from mail-wm1-f70.google.com (mail-wm1-f70.google.com [209.85.128.70]) by mail.openvz.org (8.14.4/8.14.4) with ESMTP id 6AGFfPRh027328 (version=TLSv1/SSLv3 cipher=AES128-GCM-SHA256 bits=128 verify=FAIL) for ; Mon, 16 Nov 2026 18:41:25 +0300 DKIM-Filter: OpenDKIM Filter v2.11.0 mail.openvz.org 6AGFfPRh027328 Received: by mail-wm1-f70.google.com with SMTP id 5b1f17b1804b1-4a20e41008cso22445785e9.1 for ; Mon, 16 Nov 2026 07:41:25 -0800 (PST) X-Forwarded-Encrypted: i=2; AL+hErEs1Cx3q6GA4e8xLXz3eZn2kaP2fOpdJvj0ZLFKOZYKpQqIEKJjqGqctNIQc8BLasoZKzGS6w==@openvz.org X-Gm-Message-State: APuU4Z/jbaydzCwCRAcZx3rTLL+MZIQJ3dQOdkcVTiU6cOzizAb/wqLs AtdIskXLk+KPTeFPnK+tCYZ1m/auJGCi7p9DSTeHAq5FJcmtSDjMDmcmCoItfBNrh6CAZ4YkJqb qKcj9hFyjICkE7ximNWQVBqi065hS0LoKt5TCPePOpBX2Hb16PCytXA== X-Gm-Gg: AYBFou2WHe+sOm3vJf0nyeqOwgpakJE2b+MhfMbRsu9NiAAGgFipRpURMe817e/E2uf Y6v0OUxS575h4iUwaU8J66hSpw59lpGOVsv7xS/vgQ+Eeiw1KmLZrQqXU4el793qSkrZm9Il7zM 5fM6rRVJ4mnGLj/MuphXNeREma3Q02u1c7D8uFRzgZRFi9sRk5uhrqTLPNAHbbh/5uqpqQ2e45g VfO7tczWsOE5bkydZeuirKEhthSKMFGhebTBh06TS6PaZLYcNh6Hb/m3Hgu06mtIgq2s9Bukjri 4eefQEvl9BlFbC0RPFv/owI3AoEjK5/5+DwmKHTvtO769Xbij2S16VY/175cm3icMm+IrMJ0vmH QBBiIKvWVPlI2VDO7fWzwoQZLSNg= X-Received: by 2002:a05:600c:608e:b0:4ac:da92:2bd4 with SMTP id 5b1f17b1804b1-4bb55a238bemr207194225e9.1.1794843685441; Mon, 16 Nov 2026 07:41:25 -0800 (PST) X-Received: by 2002:a05:600c:608e:b0:4ac:da92:2bd4 with SMTP id 5b1f17b1804b1-4bb55a238bemr207193575e9.1.1794843684937; Mon, 16 Nov 2026 07:41:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1794843684; cv=none; d=google.com; s=arc-20260327; b=gg5sqhlmvLPTmp8NG+T/J4mRD7Rn7K8uMHLP9GC2OM49UEn+BPsF2ZD6HbCJ5VdQiI tqZbbd6r5aB3aCwbJJCu6AtEcJvgQKlMDeinrAM64bE4Pa65OBMm1Q0cOhBqeMYTgJ6S c3MdfDlr36a/9SxxTnzNFAtuUuCuEjXSAqIZqMymQzdm9DXmnoBc8P/0ACkrV4eXz/lM /+3m+6aIUS0lDONxwMgZEwuHBhHyVPEHYwp5oUFjit0ODar/9nQ67YwFhB7JvxoDkVuB w+8kCvafjAchAYyWGtkqOeDAqJaWlrHdhwgvz+l2SPAQAd//nfgUDM0h/X45Esr/IvdB qnkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20260327; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:dkim-signature; bh=adCcmH0yOo7QuvUuzJyC/gKlmBSKgzhbS31d7ZWA0Uc=; fh=CMILZ+goaghq6B4UpCDhf0EQp6kYD0LAlmOkUiVCOvs=; b=sRPUlprX9SBp1EWXehsH5HN2foVR8o8XebAVMhz1TgVoZodhqs+9GrkV4NS9qcYvfN eNevt2PguT4/HrKb0f0aaYUnDst95qaRkYT52GiF4shDzuHj0D/O1INIxKLF0o/iWMzr lor0BA64jWrcEzAvvmN4+jFaBsX7ZHSa1BxZFqPlG4atE1BbOLNeVBHl9+RTN7v+pDTH hRus7XS875S22ORZp5wtMH6eN+6zo0i06RqtjDsTFV0KNnfAgFFVI2Q44vY9PhpZsgV1 THzlkwgN+YcbqSHd0zA5uvHUmvDhOflWNNnA5VwqlS7uKsEMkchzHEX8cGiLDkqbNLu4 33Zg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@virtuozzo.com header.s=relay header.b=UmlU4vRg; spf=pass (google.com: domain of alexander.ivanov@virtuozzo.com designates 130.117.225.111 as permitted sender) smtp.mailfrom=alexander.ivanov@virtuozzo.com; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=virtuozzo.com Received: from relay.virtuozzo.com (relay.virtuozzo.com. [130.117.225.111]) by mx.google.com with ESMTPS id ffacd0b85a97d-49c652b72e3si23036417f8f.499.2026.11.16.07.41.24 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Nov 2026 07:41:24 -0800 (PST) Received-SPF: pass (google.com: domain of alexander.ivanov@virtuozzo.com designates 130.117.225.111 as permitted sender) client-ip=130.117.225.111; Authentication-Results: mx.google.com; dkim=pass header.i=@virtuozzo.com header.s=relay header.b=UmlU4vRg; spf=pass (google.com: domain of alexander.ivanov@virtuozzo.com designates 130.117.225.111 as permitted sender) smtp.mailfrom=alexander.ivanov@virtuozzo.com; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=virtuozzo.com DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=virtuozzo.com; s=relay; h=MIME-Version:Message-ID:Date:Subject:From: Content-Type; bh=adCcmH0yOo7QuvUuzJyC/gKlmBSKgzhbS31d7ZWA0Uc=; b=UmlU4vRggyvA 4i37YeaeP1FFARk0mSPi93PTNB8fAUmfpwqrxfS96ahABXyw9wfQJ0tgpDVKuJHwrAa7OMd4oeuzd uZnxzylNEQ0N+rfozn1t0wzZXxQ7YeFEhYwv9W4v/b6lY5c8Yzd8PUhWuKBEHuRgHpMsJWY2f1BkD wBjhJBU6eA/8+ctQnHj+1kA59IUuvD6aftv2/c9Xq95IReErfWthP0G8neCbzKv4dTWpBsX2HA+ij +dbQu5vj2nXIDXkYUFPx9HgRsRvvUJlhiuc7UcF5ndgccw7dEEe/z3enhCFdrCPmz/w1f32gHssnV 2G6g6ENF8BOdOzCejIuMjw==; Received: from ch-vpn.virtuozzo.com ([130.117.225.6] helo=sky) by relay.virtuozzo.com with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1xSylR-005tLh-0l; Mon, 16 Nov 2026 16:41:15 +0100 From: Alexander Ivanov To: andrey.zhadchenko@virtuozzo.com Date: Mon, 16 Nov 2026 16:41:10 +0100 Message-ID: <20261116154119.2979718-1-alexander.ivanov@virtuozzo.com> X-Mailer: git-send-email 2.53.0 MIME-Version: 1.0 X-OZ-Fwd: true Cc: devel@openvz.org Subject: [Devel] [PATCH hci-8.1 0/9] dm-qcow2: support the werror/rerror policies for vhost-blk disks 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 QEMU disks have the werror/rerror policies: on an I/O error either report it to the guest, or pause the VM and retry the request on resume. A vhost-blk disk completes requests to the guest from the kernel, so QEMU never sees the error. This series lets dm-qcow2 hold a failed request according to the policy, tell QEMU about it, and retry or fail it on request from userspace. Patches 1-2 fix the existing ENOSPC delay: a use-after-free of the event work and timer on destroy, and a suspend stalled by a request delayed while the timer callback runs. Patches 3-4 rename the ENOSPC delay list to a held request list and arm the retry timer once per hold, so new failures do not postpone the retry of the held requests forever. Patch 5 sends an IO_ERROR change uevent when requests get held, as QEMU cannot wait for dm events without CAP_SYS_ADMIN. Patch 6 adds the resubmit and fail_held messages, so libvirt can retry the held requests on VM resume and drop them on VM destroy. Patch 7 adds the error_policy=, table argument with the report, enospc and stop policies. The default keeps the current behaviour for writes. Patch 8 requeues held requests to the dm queue on a noflush suspend, so a table reload or a snapshot of a paused VM does not deliver the error to the guest. Patch 9 fixes a vhost-blk hang on release when the vhost worker was killed with I/O in flight, which a VM destroyed while its requests are held runs into. https://virtuozzo.atlassian.net/browse/VSTOR-152175 Alexander Ivanov (9): drivers/md/dm-qcow2: cancel the event work and ENOSPC timer in the destructor drivers/md/dm-qcow2: always resubmit delayed ENOSPC requests in presuspend drivers/md/dm-qcow2: rename the ENOSPC delay list to a held request list drivers/md/dm-qcow2: arm the hold timer only for the first held request drivers/md/dm-qcow2: report held requests with an IO_ERROR uevent drivers/md/dm-qcow2: add the resubmit and fail_held messages drivers/md/dm-qcow2: add the error_policy table argument drivers/md/dm-qcow2: requeue held requests on a noflush suspend drivers/vhost/blk: fix a hang on release after the vhost worker is killed drivers/md/dm-push-backup.c | 2 +- drivers/md/dm-qcow2-cmd.c | 32 +++++++++- drivers/md/dm-qcow2-map.c | 110 +++++++++++++++++++++++++++++------ drivers/md/dm-qcow2-target.c | 104 ++++++++++++++++++++++++++++----- drivers/md/dm-qcow2.h | 26 +++++++-- drivers/md/dm-rq.c | 4 +- drivers/md/dm-rq.h | 2 +- drivers/vhost/blk.c | 52 ++++++++++++----- 8 files changed, 274 insertions(+), 58 deletions(-) -- 2.53.0 _______________________________________________ Devel mailing list Devel@openvz.org https://lists.openvz.org/mailman/listinfo/devel