qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
To: "Michael R. Hines" <mrhines@linux.vnet.ibm.com>
Cc: amit.shah@redhat.com, arei.gonglei@huawei.com,
	mrhines@us.ibm.com, qemu-devel@nongnu.org, quintela@redhat.com
Subject: Re: [Qemu-devel] [PATCH 04/10] Translate offsets to destination address space
Date: Tue, 19 May 2015 20:02:11 +0100	[thread overview]
Message-ID: <20150519190210.GJ2127@work-vm> (raw)
In-Reply-To: <555B87B6.9010701@linux.vnet.ibm.com>

* Michael R. Hines (mrhines@linux.vnet.ibm.com) wrote:
> On 05/19/2015 01:44 PM, Dr. David Alan Gilbert wrote:
> >* Michael R. Hines (mrhines@linux.vnet.ibm.com) wrote:
> >>On 04/20/2015 10:57 AM, Dr. David Alan Gilbert (git) wrote:
> >>>From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
> >>>
> >>>The 'offset' field in RDMACompress and 'current_addr' field
> >>>in RDMARegister are commented as being offsets within a particular
> >>>RAMBlock, however they appear to actually be offsets within the
> >>>ram_addr_t space.
> >>>
> >>>The code currently assumes that the offsets on the source/destination
> >>>match, this change removes the need for the assumption for these
> >>>structures by translating the addresses into the ram_addr_t space of
> >>>the destination host.
> >>I don't understand fully: If the offsets are not the same, then
> >>why would the RAMBlocks be the same? If a RAMBlock
> >>is hot-plugged on one side, shouldn't an identical one be
> >>hotplugged on the other side, including the offset into ram_addr_t?
> >If a RAMBlock is hotplugged on the source, it's normally passed in on
> >the command line at startup on the destination, not hotplugged.
> >
> >This difference in order of allocation of the RAMBlocks can cause
> >the allocation of space in ram_addr_t to be different.
> >
> >In addition changes between qemu versions as to the order in which
> >devices are initialised can cause differences in the allocation in ram_addr_t.
> >
> >Indeed the allocation algorithm isn't very deterministic, I think it looks
> >for the smallest gap that will fit for the allocation.
> >Also, lets say that you hot plugged 6 devices, and hot unplugged 5,
> >then migrated;  on the destination you only see one of them, not the history
> >of the other allocations that had to be performed.
> 
> I see ---- so until now, I just got "lucky" that the RAMBlocks were
> in the same order with the same offsets =).

Yep.

Dave
--
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK

  reply	other threads:[~2015-05-19 19:02 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-20 15:57 [Qemu-devel] [PATCH 00/10] Remove RDMA migration dependence on RAMBlock offset Dr. David Alan Gilbert (git)
2015-04-20 15:57 ` [Qemu-devel] [PATCH 01/10] Rename RDMA structures to make destination clear Dr. David Alan Gilbert (git)
2015-05-19 17:52   ` Michael R. Hines
2015-04-20 15:57 ` [Qemu-devel] [PATCH 02/10] qemu_ram_foreach_block: pass up error value, and down the ramblock name Dr. David Alan Gilbert (git)
2015-05-19 17:56   ` Michael R. Hines
2015-04-20 15:57 ` [Qemu-devel] [PATCH 03/10] Store block name in local blocks structure Dr. David Alan Gilbert (git)
2015-05-19 18:00   ` Michael R. Hines
2015-05-19 18:46     ` Dr. David Alan Gilbert
2015-04-20 15:57 ` [Qemu-devel] [PATCH 04/10] Translate offsets to destination address space Dr. David Alan Gilbert (git)
2015-05-19 18:28   ` Michael R. Hines
2015-05-19 18:44     ` Dr. David Alan Gilbert
2015-05-19 18:57       ` Michael R. Hines
2015-05-19 19:02         ` Dr. David Alan Gilbert [this message]
2015-04-20 15:57 ` [Qemu-devel] [PATCH 05/10] Rework ram_control_load_hook to hook during block load Dr. David Alan Gilbert (git)
2015-05-19 18:35   ` Michael R. Hines
2015-05-19 18:49     ` Dr. David Alan Gilbert
2015-04-20 15:57 ` [Qemu-devel] [PATCH 06/10] Remove unneeded memset Dr. David Alan Gilbert (git)
2015-05-19 18:35   ` Michael R. Hines
2015-04-20 15:57 ` [Qemu-devel] [PATCH 07/10] Simplify rdma_delete_block and remove it's dependence on the hash Dr. David Alan Gilbert (git)
2015-05-19 18:44   ` Michael R. Hines
2015-04-20 15:57 ` [Qemu-devel] [PATCH 08/10] Rework ram block hash Dr. David Alan Gilbert (git)
2015-05-19 18:49   ` Michael R. Hines
2015-05-19 18:55     ` Dr. David Alan Gilbert
2015-05-19 19:02       ` Michael R. Hines
2015-05-19 19:07         ` Dr. David Alan Gilbert
2015-04-20 15:57 ` [Qemu-devel] [PATCH 09/10] Sort destination RAMBlocks to be the same as the source Dr. David Alan Gilbert (git)
2015-05-19 18:51   ` Michael R. Hines
2015-06-01 11:53     ` Dr. David Alan Gilbert
2015-04-20 15:57 ` [Qemu-devel] [PATCH 10/10] Sanity check RDMA remote data Dr. David Alan Gilbert (git)
2015-05-19 18:52   ` Michael R. Hines
2015-05-18 22:01 ` [Qemu-devel] [PATCH 00/10] Remove RDMA migration dependence on RAMBlock offset Michael R. Hines

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=20150519190210.GJ2127@work-vm \
    --to=dgilbert@redhat.com \
    --cc=amit.shah@redhat.com \
    --cc=arei.gonglei@huawei.com \
    --cc=mrhines@linux.vnet.ibm.com \
    --cc=mrhines@us.ibm.com \
    --cc=qemu-devel@nongnu.org \
    --cc=quintela@redhat.com \
    /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).