Re: [Qemu-devel] [PATCH 07/27] add memdev backend infrastructure

2013-11-27 Thread Igor Mammedov
On Wed, 27 Nov 2013 08:25:22 -0700 Eric Blake wrote: > On 11/20/2013 07:38 PM, Igor Mammedov wrote: > > Provides framework for splitting host RAM allocation/ > > policies into a separate backend that could be used > > by devices. It would allow to separate host specific > > options from device mo

Re: [Qemu-devel] [PATCH 07/27] add memdev backend infrastructure

2013-11-27 Thread Paolo Bonzini
Il 27/11/2013 15:37, Igor Mammedov ha scritto: > It looks like "realize" for -object / object-add implemented via > an interface. It does---but without unrealize and with the additional get_base_path. > Maybe it should be renamed from QOMCommandLineIface to QOMRealizeIface > and s/complete/realiz

Re: [Qemu-devel] [PATCH 07/27] add memdev backend infrastructure

2013-11-27 Thread Igor Mammedov
On Wed, 27 Nov 2013 16:21:23 +0100 Paolo Bonzini wrote: > Il 27/11/2013 15:37, Igor Mammedov ha scritto: > > It looks like "realize" for -object / object-add implemented via > > an interface. > > It does---but without unrealize and with the additional get_base_path. > > > Maybe it should be ren

Re: [Qemu-devel] [PATCH 07/27] add memdev backend infrastructure

2013-11-27 Thread Eric Blake
On 11/20/2013 07:38 PM, Igor Mammedov wrote: > Provides framework for splitting host RAM allocation/ > policies into a separate backend that could be used > by devices. It would allow to separate host specific > options from device model like it's done for netdev & co. Just an interface review: >

Re: [Qemu-devel] [PATCH 07/27] add memdev backend infrastructure

2013-11-27 Thread Igor Mammedov
On Mon, 25 Nov 2013 17:09:37 +0100 Paolo Bonzini wrote: > Il 25/11/2013 17:01, Igor Mammedov ha scritto: > >> > So this is why you need a new command-line option. > >> > > >> > I think we need a generic mechanism for post-initialization of whatever > >> > is given on the command line. Perhaps y

Re: [Qemu-devel] [PATCH 07/27] add memdev backend infrastructure

2013-11-25 Thread Paolo Bonzini
Il 25/11/2013 17:01, Igor Mammedov ha scritto: >> > So this is why you need a new command-line option. >> > >> > I think we need a generic mechanism for post-initialization of whatever >> > is given on the command line. Perhaps you can do that with an >> > interface, and get rid of -memdev and me

Re: [Qemu-devel] [PATCH 07/27] add memdev backend infrastructure

2013-11-25 Thread Igor Mammedov
On Mon, 25 Nov 2013 13:54:10 +0100 Paolo Bonzini wrote: > Il 21/11/2013 03:38, Igor Mammedov ha scritto: > > + > > +/* verify properties correctnes and initialize backend */ > > +bc = MEMORY_BACKEND_GET_CLASS(obj); > > +if (bc->get_memory) { > > +HostMemoryBackend *backend = M

Re: [Qemu-devel] [PATCH 07/27] add memdev backend infrastructure

2013-11-25 Thread Paolo Bonzini
Il 21/11/2013 03:38, Igor Mammedov ha scritto: > + > +/* verify properties correctnes and initialize backend */ > +bc = MEMORY_BACKEND_GET_CLASS(obj); > +if (bc->get_memory) { > +HostMemoryBackend *backend = MEMORY_BACKEND(obj); > +if (!bc->get_memory(backend, &local_err

[Qemu-devel] [PATCH 07/27] add memdev backend infrastructure

2013-11-20 Thread Igor Mammedov
Provides framework for splitting host RAM allocation/ policies into a separate backend that could be used by devices. It would allow to separate host specific options from device model like it's done for netdev & co. It adds new: -memdev CLI option and corresponding memdev-add QMP/HMP comma