aboutsummaryrefslogtreecommitdiffstats
path: root/xen/include/public/xen.h
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2009-01-08 11:32:39 +0000
committerKeir Fraser <keir.fraser@citrix.com>2009-01-08 11:32:39 +0000
commitc6d8d541e9073453eb94d5450a4bac9826559b74 (patch)
tree91c693bbf1aa57a3b61be30bef4d3a5a3bea4c4b /xen/include/public/xen.h
parentf5bf427cd3f237a5d52549431bad79c0463a688d (diff)
downloadxen-c6d8d541e9073453eb94d5450a4bac9826559b74.tar.gz
xen-c6d8d541e9073453eb94d5450a4bac9826559b74.tar.bz2
xen-c6d8d541e9073453eb94d5450a4bac9826559b74.zip
x86-64: guest directed placement of initial p->m map
By adding another ELF note, the kernel can now direct the hypervisor (for Dom0) and in the future also the tools (for DomU-s) to place the initial phys->mach translation table at other than an address immediately above the kernel/initrd images. This eliminates the size restriction imposed on this table by Linux (the kernel loads above the -2Gb boundary, and hence the entire initial mapping cannot reach or even exceed 2Gb). There are a few items in this patch I'm not particularly happy with, but couldn't think of a better solution: - there is a hidden assumption that pages allocated for the domain are put on the domain's page list sequentially - the way backward compatibility is maintained is placing requirements on the kernel side that make the code somewhat convoluted (because it needs to check where the map is actually placed in quite a few places) - code is there to use 1Gb mappings for the hypervisor created table, but lacking a machine with 512G+ memory for immediate testing I can't verify this works; I know that 2Mb mappings work, and hence imply that 1Gb ones would too (of course, if the kernel replaces the table - like Linux does -, it cannot use 2Mb/1Gb mappings or even try to re-use the page table entries, but I don't consider this a problem) Signed-off-by: Jan Beulich <jbeulich@novell.com>
Diffstat (limited to 'xen/include/public/xen.h')
-rw-r--r--xen/include/public/xen.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/xen/include/public/xen.h b/xen/include/public/xen.h
index 5292232819..2f85ab3937 100644
--- a/xen/include/public/xen.h
+++ b/xen/include/public/xen.h
@@ -513,6 +513,7 @@ typedef struct shared_info shared_info_t;
* a. relocated kernel image
* b. initial ram disk [mod_start, mod_len]
* c. list of allocated page frames [mfn_list, nr_pages]
+ * (unless relocated due to XEN_ELFNOTE_INIT_P2M)
* d. start_info_t structure [register ESI (x86)]
* e. bootstrap page tables [pt_base, CR3 (x86)]
* f. bootstrap stack [register ESP (x86)]
@@ -554,6 +555,9 @@ struct start_info {
unsigned long mod_start; /* VIRTUAL address of pre-loaded module. */
unsigned long mod_len; /* Size (bytes) of pre-loaded module. */
int8_t cmd_line[MAX_GUEST_CMDLINE];
+ /* The pfn range here covers both page table and p->m table frames. */
+ unsigned long first_p2m_pfn;/* 1st pfn forming initial P->M table. */
+ unsigned long nr_p2m_frames;/* # of pfns forming initial P->M table. */
};
typedef struct start_info start_info_t;