qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v5 05/14] vl: handle "-device dimm"


From: Igor Mammedov
Subject: Re: [Qemu-devel] [PATCH v5 05/14] vl: handle "-device dimm"
Date: Tue, 16 Jul 2013 12:19:01 +0200

On Tue, 16 Jul 2013 08:19:48 +0200
Paolo Bonzini <address@hidden> wrote:

> Il 16/07/2013 03:27, Hu Tao ha scritto:
> > > I think it's the same.  One "-numa mem" option = one "-device dimm"
> > > option; both define one range.  Unused memory ranges may remain if you
> > > stumble upon a unusable range such as the PCI window.  For example two
> > > "-numa mem,size=2G" options would allocate memory from 0 to 2G and from
> > > 4 to 6G.
> > 
> > So we can drop -dimm if we agree on -numa mem?
> 
> Yes, the point of the "-numa mem" proposal was to avoid the concept of a
> "partially initialized device" that you had for DIMMs.
I've though -numa mem was for mapping initial memory to numa nodes.
It seem wrong to use it for representing dimm device and also limiting
possible hotplugged regions to specified at startup ranges.

we can leave -numa for initial memory mapping and manage of the mapping
of hotpluggable regions with -device dimm,node=X,size=Y.

It that case command line -device dimm will provide a fully initialized
dimm device usable at startup (but hot-unplugable) and
  (monitor) device_add dimm,,node=X,size=Y
would serve hot-plug case.

That way arbitrary sized dimm could be hot-pluged without specifying them
at startup, like it's done on bare-metal.

In addition command line -device would be used in migration case to describe
already hot-plugged dimms on target.

> BTW, how do you specify which module you are plugging in?  I.e., what if
> I have three 1G ranges at 0, 1G and 2G, and I want to plug the first and
> the third?
> This is especially important with hot-unplug, because then you can have
> this kind of hole in the address space.  If you migrate the VM, you have
> to reproduce the situation in the destination command line.
Could we add optional advising 'base-addr' property to replicate exact
source configuration on target?  some thing like:
 -device dimm,node=X,size=Y,base-addr=Z
where mgmt could get actual X,Y,Z inspecting dim device via qom-get.
and if base-addr is not set parent of dimm would auto-allocate address
where dimm is mapped.

> 
> Paolo
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]