From mboxrd@z Thu Jan 1 00:00:00 1970 From: Xiao Guangrong Subject: Re: [Qemu-devel] [PATCH 00/16] implement vNVDIMM Date: Wed, 29 Jul 2015 16:41:48 +0800 Message-ID: <55B891CC.4060507@linux.intel.com> References: <1435762232-15543-1-git-send-email-guangrong.xiao@linux.intel.com> <20150702092044.GB20198@stefanha-thinkpad.redhat.com> <559509FA.20509@redhat.com> <55957C7A.9050200@linux.intel.com> <55957EE5.6090307@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: ehabkost@redhat.com, kvm@vger.kernel.org, mst@redhat.com, gleb@kernel.org, mtosatti@redhat.com, qemu-devel@nongnu.org, =?UTF-8?B?TWFyYy1BbmRyw6kgTHVyZWF1?= , stefanha@redhat.com, imammedo@redhat.com, rth@twiddle.net To: Paolo Bonzini , Stefan Hajnoczi Return-path: Received: from mga11.intel.com ([192.55.52.93]:43627 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750791AbbG2IrO (ORCPT ); Wed, 29 Jul 2015 04:47:14 -0400 In-Reply-To: <55957EE5.6090307@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On 07/03/2015 02:11 AM, Paolo Bonzini wrote: > > > On 02/07/2015 20:01, Xiao Guangrong wrote: >> >> Thanks for your review, Stefan and Paolo! >> >> On 07/02/2015 05:52 PM, Paolo Bonzini wrote: >>> >>> >>> On 02/07/2015 11:20, Stefan Hajnoczi wrote: >>>>> Currently, the NVDIMM driver has been merged into upstream Linux >>>>> Kernel and >>>>> this patchset tries to enable it in virtualization field >>>> >>>> From a device model perspective, have you checked whether it mak= es >>>> sense >>>> to integrate nvdimms into the pc-dimm and hostmem code that is use= d for >>>> memory hotplug and NUMA? >>>> >>>> The NVDIMM device in your patches is a completely new TYPE_DEVICE = so it >>>> doesn't share any interfaces or code with existing memory devices. >>>> Maybe that is the right solution here because NVDIMMs have differe= nt >>>> characteristics, but I'm not sure. >>> >>> The hostmem code should definitely be shared, e.g. by adding a new >>> "file" property to the memory-backend-file class. ivshmem can also= use >>> it---CCing Marc-Andr=EF=BF=BD. >> >> However, file-based memory used by NVDIMM is special, it divides the= file >> to two parts, one part is used as PMEM and another part is used to s= tore >> NVDIMM's configure data. >> >> Maybe we can introduce "end-reserved" property to reserve specified = size >> at the end of the file. Or create a new class type based on >> memory-backend-file (named nvdimm-backend-file) class to hide this m= agic >> thing? > > I need to read the code then. :) Paolo, do you have any comment? :)