From: Laszlo Ersek <lersek@redhat.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: Paolo Bonzini <pbonzini@redhat.com>,
"Michael S. Tsirkin" <mst@redhat.com>,
Gerd Hoffmann <kraxel@redhat.com>,
QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH v3 1/2] memory: export migration page size
Date: Mon, 19 Aug 2013 13:09:36 +0200 [thread overview]
Message-ID: <5211FCF0.2000702@redhat.com> (raw)
In-Reply-To: <CAFEAcA8vXbp+nQ9SGYtj+PMvHTBo7KXsFN_FCbZeqM6atnuScA@mail.gmail.com>
On 08/19/13 12:21, Peter Maydell wrote:
> On 19 August 2013 10:59, Laszlo Ersek <lersek@redhat.com> wrote:
>> On 08/13/13 00:43, Michael S. Tsirkin wrote:
>>> Migration code assumes that each RAM block is a multiple of target page
>>> size.
>>
>> Isn't that a valid assumption, considering the TARGET_PAGE_ALIGN() macro
>> call in qemu_ram_alloc_from_ptr() [exec.c]?
>
> That macro only makes the size we store in the ramblock data
> structure be a multiple of the page size -- it does nothing to ensure
> that the actual memory that was passed in by the caller is the
> right size. (It will have the right effect where qemu_ram_alloc_from_ptr
> is allocating the memory itself, obviously.)
Which is the case for 2/2, see my comments there:
memory_region_init_ram()
qemu_ram_alloc()
qemu_ram_alloc_from_ptr() <---- host==NULL
TARGET_PAGE_ALIGN()
Laszlo
next prev parent reply other threads:[~2013-08-19 11:07 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-12 22:43 [Qemu-devel] [PATCH v3 0/2] future proof rom loading for cross versiom migration Michael S. Tsirkin
2013-08-12 22:43 ` [Qemu-devel] [PATCH v3 1/2] memory: export migration page size Michael S. Tsirkin
2013-08-19 9:59 ` Laszlo Ersek
2013-08-19 10:21 ` Peter Maydell
2013-08-19 11:09 ` Laszlo Ersek [this message]
2013-08-19 11:18 ` Michael S. Tsirkin
2013-08-19 11:33 ` Laszlo Ersek
2013-08-19 11:05 ` Michael S. Tsirkin
2013-08-12 22:43 ` [Qemu-devel] [PATCH v3 2/2] loader: put FW CFG ROM files into RAM Michael S. Tsirkin
2013-08-19 11:06 ` Laszlo Ersek
2013-08-19 11:10 ` Michael S. Tsirkin
2013-08-19 11:15 ` Laszlo Ersek
2013-08-19 11:21 ` Michael S. Tsirkin
2013-08-18 13:41 ` [Qemu-devel] [PATCH v3 0/2] future proof rom loading for cross versiom migration Michael S. Tsirkin
2013-08-19 11:37 ` Laszlo Ersek
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=5211FCF0.2000702@redhat.com \
--to=lersek@redhat.com \
--cc=kraxel@redhat.com \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--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 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.