aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2008-07-31 12:38:32 +0100
committerKeir Fraser <keir.fraser@citrix.com>2008-07-31 12:38:32 +0100
commit52c456a522e1efd841fcbfe137c8ed24d81d9113 (patch)
tree18555982e59018c996d5483152d024faea11a7fe /tools
parente00bff2cd33a2fbbef8a250865bc39e9cbe10a32 (diff)
downloadxen-52c456a522e1efd841fcbfe137c8ed24d81d9113.tar.gz
xen-52c456a522e1efd841fcbfe137c8ed24d81d9113.tar.bz2
xen-52c456a522e1efd841fcbfe137c8ed24d81d9113.zip
hvm builder: Cleaner sp_extents allocation
We do not need more than count elements in the sp_extents array. Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/libxc/xc_hvm_build.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/libxc/xc_hvm_build.c b/tools/libxc/xc_hvm_build.c
index a174b430a1..752c4e76dc 100644
--- a/tools/libxc/xc_hvm_build.c
+++ b/tools/libxc/xc_hvm_build.c
@@ -229,7 +229,7 @@ static int setup_guest(int xc_handle,
if ( ((count | cur_pages) & (SUPERPAGE_NR_PFNS - 1)) == 0 )
{
long done;
- xen_pfn_t sp_extents[2048 >> SUPERPAGE_PFN_SHIFT];
+ xen_pfn_t sp_extents[count >> SUPERPAGE_PFN_SHIFT];
struct xen_memory_reservation sp_req = {
.nr_extents = count >> SUPERPAGE_PFN_SHIFT,
.extent_order = SUPERPAGE_PFN_SHIFT,