|
|
|
|
|
|
|
|
|
|
xen-devel
[Xen-devel] [PATCH] x86: make max_mfn returned from XENMEM_machphys_mapp
This helps debugging in the guest kernels, as then MFNs there can then
be range checked based on the reported value.
Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>
--- 2010-01-27.orig/xen/arch/x86/mm.c 2010-01-06 11:22:26.000000000 +0100
+++ 2010-01-27/xen/arch/x86/mm.c 2010-02-03 13:29:46.000000000 +0100
@@ -4457,12 +4457,14 @@ long arch_memory_op(int op, XEN_GUEST_HA
case XENMEM_machphys_mapping:
{
- static const struct xen_machphys_mapping mapping = {
+ struct xen_machphys_mapping mapping = {
.v_start = MACH2PHYS_VIRT_START,
.v_end = MACH2PHYS_VIRT_END,
.max_mfn = MACH2PHYS_NR_ENTRIES - 1
};
+ if ( !mem_hotplug )
+ mapping.max_mfn = max_page - 1;
if ( copy_to_guest(arg, &mapping, 1) )
return -EFAULT;
x86-restrict-machphys-mapping.patch
Description: Text document
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-devel] [PATCH] x86: make max_mfn returned from XENMEM_machphys_mapping dynamic,
Jan Beulich <=
|
|
|
|
|