From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: Michal Privoznik <mprivozn@redhat.com>, qemu-devel@nongnu.org
Subject: Re: [PATCH v3 4/4] backends/hostmem: Report error when memory size is unaligned
Date: Fri, 31 May 2024 17:39:25 +0200 [thread overview]
Message-ID: <d9ce4eb9-e211-40a9-8d71-4ee1c309ea00@linaro.org> (raw)
In-Reply-To: <025d0bdd5e76b334754c09c445fe621090121da5.1717168113.git.mprivozn@redhat.com>
On 31/5/24 17:10, Michal Privoznik wrote:
> If memory-backend-{file,ram} has a size that's not aligned to
> underlying page size it is not only wasteful, but also may lead
> to hard to debug behaviour. For instance, in case
> memory-backend-file and hugepages, madvise() and mbind() fail.
> Rightfully so, page is the smallest unit they can work with. And
> even though an error is reported, the root cause it not very
> clear:
>
> qemu-system-x86_64: Couldn't set property 'dump' on 'memory-backend-file': Invalid argument
>
> After this commit:
>
> qemu-system-x86_64: backend 'memory-backend-file' memory size must be multiple of 2 MiB
Thanks!
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
> Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
> ---
> backends/hostmem.c | 10 ++++++++++
> 1 file changed, 10 insertions(+)
prev parent reply other threads:[~2024-05-31 15:39 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-31 15:10 [PATCH v3 0/4] backends/hostmem: Report more errors on failures Michal Privoznik
2024-05-31 15:10 ` [PATCH v3 1/4] osdep: Make qemu_madvise() to set errno in all cases Michal Privoznik
2024-05-31 15:46 ` Philippe Mathieu-Daudé
2024-06-02 6:26 ` Akihiko Odaki
2024-06-03 7:56 ` Michal Prívozník
2024-06-03 8:50 ` Akihiko Odaki
2024-06-03 10:07 ` Michal Prívozník
2024-06-03 11:17 ` Akihiko Odaki
2024-06-03 7:50 ` Michal Prívozník
2024-05-31 15:10 ` [PATCH v3 2/4] osdep: Make qemu_madvise() return ENOSYS on unsupported OSes Michal Privoznik
2024-05-31 15:10 ` [PATCH v3 3/4] backends/hostmem: Report error on qemu_madvise() failures Michal Privoznik
2024-05-31 15:10 ` [PATCH v3 4/4] backends/hostmem: Report error when memory size is unaligned Michal Privoznik
2024-05-31 15:39 ` Philippe Mathieu-Daudé [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=d9ce4eb9-e211-40a9-8d71-4ee1c309ea00@linaro.org \
--to=philmd@linaro.org \
--cc=mprivozn@redhat.com \
--cc=qemu-devel@nongnu.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;
as well as URLs for NNTP newsgroup(s).