From mboxrd@z Thu Jan 1 00:00:00 1970 From: Haozhong Zhang Subject: Re: [PATCH 2/2] pc-nvdimm acpi: build ACPI tables for pc-nvdimm devices Date: Tue, 5 Jan 2016 10:14:16 +0800 Message-ID: <20160105021416.GG3619@hz-desktop.sh.intel.com> References: <1451388527-18009-1-git-send-email-haozhong.zhang@intel.com> <1451388527-18009-3-git-send-email-haozhong.zhang@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Stefano Stabellini Cc: Wei Liu , xen-devel@lists.xensource.com, Xiao Guangrong , Eduardo Habkost , "Michael S. Tsirkin" , Ian Jackson , Igor Mammedov , Anthony.Perard@citrix.com, Paolo Bonzini , Ian Campbell , Richard Henderson List-Id: xen-devel@lists.xenproject.org On 01/04/16 16:01, Stefano Stabellini wrote: > CC'ing the Xen tools maintainers and Anthony. > > On Tue, 29 Dec 2015, Haozhong Zhang wrote: > > Reuse existing NVDIMM ACPI code to build ACPI tables for pc-nvdimm > > devices. The resulting tables are then copied into Xen guest domain so > > tha they can be later loaded by Xen hvmloader. > > > > Signed-off-by: Haozhong Zhang > > How much work would it be to generate the nvdimm acpi tables from the > Xen toolstack? > I think at least two parts of work should be done if generating nvdimm ACPI tables from toolstack: (1) An AML builder. NVDIMM SSDT table contains a part of definition block, so an AML builder is required. If guest ACPI tables is going to be generated from toolstack, I think we can port QEMU's AML builder to toolstack. (2) Interface to pass information of vNVDIMM devices from QEMU to Xen. Currently, QEMU is responsible to decide the slot IDs of vNVDIMM devices, the address space where vNVDIMM devices are mapped to and other stuffs that need to be written in ACPI tables. In the future, there could be more as planed, including information about NVDIMM label areas. If generating NVDIMM ACPI tables from Xen, all those information should be passed from QEMU. Maybe we can pass them through xenstore. > Getting the tables from QEMU doesn't seem like a good idea to me, unless > we start getting the whole set of ACPI tables that way. > As most of current and future vNVDIMM implementation in QEMU would be related to ACPI, I really want to reuse those code as much as possible. Haozhong