From: Konstantin Khorenko <khorenko@virtuozzo.com>
To: Andrey Zhadchenko <andrey.zhadchenko@virtuozzo.com>
Cc: devel@openvz.org
Subject: Re: [Devel] [PATCH hci-8.1 0/3] dm-qcow2: do not free a discarded cluster under in-flight writes
Date: Thu, 12 Nov 2026 19:59:48 +0100 [thread overview]
Message-ID: <179450998877.4060562.6491294425653598184.b4-review@b4> (raw)
In-Reply-To: <20261112111205.736027-1-andrey.zhadchenko@virtuozzo.com>
Applying with these fixes on my side:
- patch 1: "The counting is done from the main work only" -> "The
counters are increased from the main work only".
- patch 2: "refer the cluster" -> "refer to the cluster", and the
comma splice "of a page, others wait" -> "of a page; the others
wait".
On Thu, 12 Nov 2026 14:12:02 +0300, Andrey Zhadchenko <andrey.zhadchenko@virtuozzo.com> wrote:
> Make such a discard wait for these writes before the cluster is freed:
The code is right: every data write decrements exactly once, also on
error and on a resubmitted short write, and the generation switch
cannot lose the wakeup of the waiting discard.
Separate patches, not needed for this series; I created a task for
it:
1. Reads are not counted. A guest read resolved to the cluster before
the discard locked the index can land after the cluster went to
another LBA or to an L2 or refcount table, and return that content.
It is older than this series (6e1c3e5a91fd). ext4 and xfs close the
window, their hole punch waits for in-flight direct I/O, but
fuse_file_fallocate() does not, so images on vstorage are exposed.
https://virtuozzo.atlassian.net/browse/VSTOR-154939
--
Konstantin Khorenko,
Virtuozzo Linux Kernel Team
_______________________________________________
Devel mailing list
Devel@openvz.org
https://lists.openvz.org/mailman/listinfo/devel
next prev parent reply other threads:[~2026-11-12 19:01 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-12 11:12 Andrey Zhadchenko
2026-11-12 11:12 ` [Devel] [PATCH hci-8.1 1/3] dm-qcow2: count in-flight data writes per L2 page Andrey Zhadchenko
2026-11-12 11:22 ` no-reply
2026-11-12 18:59 ` Konstantin Khorenko
2026-11-12 11:12 ` [Devel] [PATCH hci-8.1 2/3] dm-qcow2: wait for in-flight writes before freeing a discarded cluster Andrey Zhadchenko
2026-11-12 11:26 ` no-reply
2026-11-12 11:47 ` Andrey Zhadchenko
2026-11-12 18:59 ` Konstantin Khorenko
2026-11-12 11:12 ` [Devel] [PATCH hci-8.1 3/3] dm-qcow2: let discards of one L2 page wait for in-flight writes together Andrey Zhadchenko
2026-11-12 11:24 ` no-reply
2026-11-12 18:59 ` Konstantin Khorenko
2026-11-12 12:40 ` [Devel] [PATCH hci-8.1 0/3] dm-qcow2: do not free a discarded cluster under in-flight writes Alexander Ivanov
2026-11-12 18:59 ` Konstantin Khorenko [this message]
2026-11-12 19:00 ` Konstantin Khorenko
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=179450998877.4060562.6491294425653598184.b4-review@b4 \
--to=khorenko@virtuozzo.com \
--cc=andrey.zhadchenko@virtuozzo.com \
--cc=devel@openvz.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox