[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [RFC Design Doc] Add vNVDIMM support for Xen
On 03/02/16 06:03, Jan Beulich wrote: > >>> On 02.03.16 at 08:14, <haozhong.zhang@xxxxxxxxx> wrote: > > It means NVDIMM is very possibly mapped in page granularity, and > > hypervisor needs per-page data structures like page_info (rather than the > > range set style nvdimm_pages) to manage those mappings. > > > > Then we will face the problem that the potentially huge number of > > per-page data structures may not fit in the normal ram. Linux kernel > > developers came across the same problem, and their solution is to > > reserve an area of NVDIMM and put the page structures in the reserved > > area (https://lwn.net/Articles/672457/). I think we may take the similar > > solution: > > (1) Dom0 Linux kernel reserves an area on each NVDIMM for Xen usage > > (besides the one used by Linux kernel itself) and reports the address > > and size to Xen hypervisor. > > > > Reasons to choose Linux kernel to make the reservation include: > > (a) only Dom0 Linux kernel has the NVDIMM driver, > > (b) make it flexible for Dom0 Linux kernel to handle all > > reservations (for itself and Xen). > > > > (2) Then Xen hypervisor builds the page structures for NVDIMM pages and > > stores them in above reserved areas. > > Another argument against this being primarily Dom0-managed, > I would say. Yes, Xen should, at least, manage all address mappings for NVDIMM. Dom0 Linux and QEMU then provide a user-friendly interface to configure NVDIMM and vNVDIMM: like providing files (instead of address) as the abstract of SPA ranges in/of NVDIMM. > Furthermore - why would Dom0 waste space > creating per-page control structures for regions which are > meant to be handed to guests anyway? > I found my description was not accurate after consulting with our driver developers. By default the linux kernel does not create page structures for NVDIMM which is called by kernel the "raw mode". We could enforce the Dom0 kernel to pin NVDIMM in "raw mode" so as to avoid waste. Haozhong _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |