From: Kevin Wolf <kwolf@redhat.com>
To: Andrey Drobyshev <andrey.drobyshev@virtuozzo.com>
Cc: qemu-block@nongnu.org, qemu-devel@nongnu.org, hreitz@redhat.com,
vsementsov@yandex-team.ru, den@openvz.org
Subject: Re: [PATCH v2] block: allocate aligned write buffer for 'truncate -m full'
Date: Fri, 25 Sep 2026 15:25:02 +0200 [thread overview]
Message-ID: <arZ2LmcWEnhiE-Y_@redhat.com> (raw)
In-Reply-To: <20260923162224.34946-1-andrey.drobyshev@virtuozzo.com>
Am 23.09.2026 um 18:22 hat Andrey Drobyshev geschrieben:
> In case we're truncating an image opened with O_DIRECT, we might get
> -EINVAL on write with unaligned buffer. In particular, when running
> iotests/298 with '-nocache' we get:
>
> qemu-io: Failed to resize underlying file: Could not write zeros for
> preallocation: Invalid argument
>
> Let's just allocate the buffer using qemu_blockalign0() instead.
>
> Signed-off-by: Andrey Drobyshev <andrey.drobyshev@virtuozzo.com>
> Reviewed-by: Denis V. Lunev <den@openvz.org>
> Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
Thanks, applied to the block branch.
Kevin
prev parent reply other threads:[~2026-09-25 13:25 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-23 16:22 [PATCH v2] block: allocate aligned write buffer for 'truncate -m full' Andrey Drobyshev
2026-09-25 13:25 ` Kevin Wolf [this message]
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=arZ2LmcWEnhiE-Y_@redhat.com \
--to=kwolf@redhat.com \
--cc=andrey.drobyshev@virtuozzo.com \
--cc=den@openvz.org \
--cc=hreitz@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=vsementsov@yandex-team.ru \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.