diff options
author | kfraser@localhost.localdomain <kfraser@localhost.localdomain> | 2007-03-19 16:48:24 +0000 |
---|---|---|
committer | kfraser@localhost.localdomain <kfraser@localhost.localdomain> | 2007-03-19 16:48:24 +0000 |
commit | 28f7888d7fc4aa75135ac1c566566eda1704db65 (patch) | |
tree | 7497496dd0c56c7c264f3b371d69b95abe50f06b /xen/common/compat | |
parent | b81cb0e6ae47ee9885ac2bfc006c6e5162d76cae (diff) | |
download | xen-28f7888d7fc4aa75135ac1c566566eda1704db65.tar.gz xen-28f7888d7fc4aa75135ac1c566566eda1704db65.tar.bz2 xen-28f7888d7fc4aa75135ac1c566566eda1704db65.zip |
hvm: Do not save/restore shared_info gpfn location.
Instead of kludging a max_gpfn estimate in shared_info, add a new
XENMEM command to discover the actual maximum gpfn value as known by
the shadow code.
This needs to be more robust when we support HVM ballooning in future
anyway. One interesting point is that max_gpfn may be close to 4GB
even for small-memory HVM guests since for example SVGA LFB is mapped
into the I/O hole. We may need to special case the I/O hole somehow,
or provide some finer-grained way to find out which parts of the GPFN
space are actually used (e.g., get Xen to fill in a bitmap with 1 bit
per 1024 pages, or similar).
Signed-off-by: Keir Fraser <keir@xensource.com>
Diffstat (limited to 'xen/common/compat')
-rw-r--r-- | xen/common/compat/memory.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/xen/common/compat/memory.c b/xen/common/compat/memory.c index 1301e42f04..53628d7a35 100644 --- a/xen/common/compat/memory.c +++ b/xen/common/compat/memory.c @@ -170,6 +170,7 @@ int compat_memory_op(unsigned int cmd, XEN_GUEST_HANDLE(void) compat) case XENMEM_current_reservation: case XENMEM_maximum_reservation: + case XENMEM_maximum_gpfn: { #define xen_domid_t domid_t #define compat_domid_t domid_compat_t @@ -325,6 +326,7 @@ int compat_memory_op(unsigned int cmd, XEN_GUEST_HANDLE(void) compat) case XENMEM_maximum_ram_page: case XENMEM_current_reservation: case XENMEM_maximum_reservation: + case XENMEM_maximum_gpfn: break; case XENMEM_translate_gpfn_list: |