[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [RFC XEN PATCH 03/16] xen/x86: add a hypercall XENPF_pmem_add to report host pmem regions
On 10/10/16 01:32, Haozhong Zhang wrote: > Xen hypervisor does not include a pmem driver. Instead, it relies on the > pmem driver in Dom0 to report the PFN ranges of the entire pmem region, > its reserved area and data area via XENPF_pmem_add. The reserved area is > used by Xen hypervisor to place the frame table and M2P table, and is > disallowed to be accessed from Dom0 once it's reported. > > Signed-off-by: Haozhong Zhang <haozhong.zhang@xxxxxxxxx> > --- > Cc: Jan Beulich <jbeulich@xxxxxxxx> > Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> > Cc: Daniel De Graaf <dgdegra@xxxxxxxxxxxxx> Please consider the following scenario. A user installs Linux onto a server, formats a DAX filesystem and fills it with content. The user then installs Xen and reboots. With this current hypercall, there is an explicit expectation that Xen is destructive to a nominated part of the NVDIMM simply by reporting its existence. Xen (obviously) cannot blindly be destructive to the NVDIMM. Destructiveness is therefore a permission which must be granted by dom0 (as the logical owner of the content of the NVDIMM) to Xen, but this permission can only be granted once dom0 has initially accessed the NVDIMM to identify a safe area to use. Therefore, reporting the existence and details of an NVDIMM must necessarily be separate from dom0 allowing Xen to use regions for its own purposes. There should be two hypercalls; one which identifies the presence of the NVDIMM and its MFN/SPA location, and one which grants Xen permission to use an area for its own purposes. This approach is also more flexible. A dom0 policy decision could be that Xen may use an entire NVDIMM as RAM, while other NVDIMMs are exclusively preexisting DAX content which need keeping, or some part of an NVDIMM can be reserved for Xen's use by allocating a file and granting access to the MFNs/SPAs making up that file. ~Andrew _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |