From mboxrd@z Thu Jan 1 00:00:00 1970 From: Paolo Bonzini Subject: Re: [PATCH v2 08/18] nvdimm: init backend memory mapping and config data area Date: Thu, 17 Sep 2015 11:34:38 +0200 Message-ID: <55FA892E.6080207@redhat.com> References: <1439563931-12352-1-git-send-email-guangrong.xiao@linux.intel.com> <1439563931-12352-9-git-send-email-guangrong.xiao@linux.intel.com> <20150825160353.GD8344@stefanha-thinkpad.redhat.com> <55DD979A.70804@linux.intel.com> <20150828115851.GM4917@stefanha-thinkpad.redhat.com> <55E3F2EF.8070501@linux.intel.com> <20150901091400.GB5051@stefanha-thinkpad.redhat.com> <55F842D9.2010104@redhat.com> <55FA7C30.10208@linux.intel.com> <20150917110452.1ffaed44@nial.brq.redhat.com> <55FA8468.4000108@linux.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Cc: Stefan Hajnoczi , Stefan Hajnoczi , gleb@kernel.org, mtosatti@redhat.com, mst@redhat.com, rth@twiddle.net, ehabkost@redhat.com, kvm@vger.kernel.org, qemu-devel@nongnu.org To: Xiao Guangrong , Igor Mammedov Return-path: Received: from mx1.redhat.com ([209.132.183.28]:34231 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754348AbbIQJeo (ORCPT ); Thu, 17 Sep 2015 05:34:44 -0400 In-Reply-To: <55FA8468.4000108@linux.intel.com> Sender: kvm-owner@vger.kernel.org List-ID: On 17/09/2015 11:14, Xiao Guangrong wrote: > > > /* get the memory region from backend memory. */ > mr = host_memory_backend_get_memory(dimm->hostmem, errp); > > /* nvdimm_nr will map to guest address space. */ > memory_region_init_alias(&nvdimm->nvdimm_mr, OBJECT(dev), > object_get_canonical_path(OBJECT(dev)), mr, 0, > size - nvdimm->label_size); You can just use "memory" here for the name here. The name only needs to be unique for RAM memory regions, and dimm->hostmem will take care of it. Paolo