libxenlight resend: 8mb physmap slack for pv domains
PATCH 3/7 libxenlight resend: 8mb physmap slack for pv domains
Contemplate 8MB of slack for PV domains, since they do ballooning (or flipping network rx) and need some extra room in their pfn space.
Note that this does not allocate any extra memory to the domain, it simply extends the physmap with some extra room for "bounce bufffering back" pfn's that are yielded to dom0.
# HG changeset patch
# User Andres Lagar-Cavilla <[email protected]> # Date 1259252810 18000
# Node ID ac2ad391d9290a5c554c9b809a6a23bb73aa25a2 # Parent f5f07c0161eef51c265a1d0acbdf7da84cfc0fef Contemplate 8MB of slack for PV domains, since they do ballooning (or flipping network rx) and need some extra room in their pfn space.
Note that this does not allocate any extra memory to the domain, it simply extends the physmap with some extra room for "bounce bufffering back" pfn's that are yielded to dom0.
libxl_dom.c +2 -1
@@ -53,7 +53,8 @@ int build_pre(struct libxl_ctx *ctx, uinxc_set_hvm_param (ctx->xch, domid,HVM_PARAM_VPT_ALIGN , (unsigned long ) info->vpt_align);xc_domain_max_vcpus (ctx->xch, domid, info->max_vcpus);xc_domain_setmaxmem (ctx->xch, domid, info->max_memkb + info->video_memkb); -xc_domain_set_memmap_limit (ctx->xch, domid, info->max_memkb); +xc_domain_set_memmap_limit (ctx->xch, domid, + (info->hvm) ? info->max_memkb : (info->max_memkb + (8 *1024 )));if (info->hvm) {unsigned long shadow;
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Quoted 9 lines · Andres Lagar-Cavilla
Contemplate 8MB of slack for PV domains, since they do ballooning (or flipping network rx) and need some extra room in their pfn space.
Note that this does not allocate any extra memory to the domain, it simply extends the physmap with some extra room for "bounce bufffering back" pfn's that are yielded to dom0.
Vincent is probably traveling and for this reason he didn't reply to your last email about this patch.
I don't think he would be happy until you move the 8mb slack into a configurable parameter in libxl_domain_build_info, defaulted to 8mb in init_build_info.
Quoted 8 lines · Andres Lagar-Cavilla
Contemplate 8MB of slack for PV domains, since they do ballooning (or flipping network rx) and need some extra room in their pfn space.
Note that this does not allocate any extra memory to the domain, it simply extends the physmap with some extra room for "bounce bufffering back" pfn's that are yielded to dom0.
but the memory is still going off from somewhere isn't it ?
all those random memory constants spread around in xend took us quite some time to get things right in XCP and XenServer, and also for keeping the library as dumb as possible, I'ld rather have the toolstack set the field in the structure (even if it end up beeing 8M all the time) than starting adding those things.
Signature · 1 line
Vincent
No extra memory is being allocated at all in any way. The only impact is a wee bit larger p2m table. Andres
Quoted 19 lines · Vincent Hanquez
Quoted 9 lines · Andres Lagar-Cavilla
Contemplate 8MB of slack for PV domains, since they do ballooning (or flipping network rx) and need some extra room in their pfn space.
Note that this does not allocate any extra memory to the domain, it simply extends the physmap with some extra room for "bounce bufffering back" pfn's that are yielded to dom0.
but the memory is still going off from somewhere isn't it ?
all those random memory constants spread around in xend took us quite some time to get things right in XCP and XenServer, and also for keeping the library as dumb as possible, I'ld rather have the toolstack set the field in the structure (even if it end up beeing 8M all the time) than starting adding those things.
Quoted 2 lines · Andres Lagar-Cavilla
No extra memory is being allocated at all in any way. The only impact is a wee bit larger p2m table.
yes, and that consumes memory. not sure that's one we care about in XCP, but as a rule to not make any exceptions, i want the amount to be explicetly tracked.
note that also, whilst xend didn't have much done regarding memory stuff, xapi (the ocaml daemon running instead of xend in XCP) have load of changes regarding how we allocate and track things.
Signature · 1 line
Vincent
The p2m is *inside* the pv guest. So the only "impact" is infinitesimally increasing the chances of an oom_killer going postal. This is not for hvm's with external p2m's Andres
Quoted 14 lines · Vincent Hanquez
Quoted 2 lines · Andres Lagar-Cavilla
No extra memory is being allocated at all in any way. The only impact is a wee bit larger p2m table.
yes, and that consumes memory. not sure that's one we care about in XCP, but as a rule to not make any exceptions, i want the amount to be explicetly tracked.
note that also, whilst xend didn't have much done regarding memory stuff, xapi (the ocaml daemon running instead of xend in XCP) have load of changes regarding how we allocate and track things.
PATCH 3/7 libxenlight meta-resend: physmap slack for pv domains
In reply to Andres Lagar-CavillaContemplate a memory space slack for PV domains, since they do ballooning (or flipping network rx) and need some extra room in their pfn space.
Note that this does not allocate any extra memory to the domain, it simply extends the physmap with some extra room for "bounce bufffering back" pfn's that are yielded to dom0.
The default slack is set at 8MB.
# HG changeset patch
# User Andres Lagar-Cavilla <[email protected]> # Date 1259856754 18000
# Node ID 7315ca037a680d18a6c23d030139b5389a73000b # Parent e64cd1042530990b49647d6eeb1c4167f02d4f19 Contemplate a memory space slack for PV domains, since they do ballooning (or flipping network rx) and need some extra room in their pfn space.
Note that this does not allocate any extra memory to the domain, it simply extends the physmap with some extra room for "bounce bufffering back" pfn's that are yielded to dom0.
The default slack is set at 8MB.
libxl.c +2 -0
@@ -2034,6 +2034,8 @@ void init_build_info(libxl_domain_build_ b_info->u.hvm.acpi =1 ; b_info->u.hvm.nx =1 ; b_info->u.hvm.viridian =0 ; + }else { + b_info->u.pv.slack_memkb =8 *1024 ; } }
libxl.h +1 -0
@@ -80,6 +80,7 @@ typedef struct {char *timeoffset; } hvm;struct { +uint32_t slack_memkb;const char *cmdline;const char *ramdisk;const char *features;
libxl_dom.c +3 -1
@@ -53,7 +53,9 @@ int build_pre(struct libxl_ctx *ctx, uinxc_set_hvm_param (ctx->xch, domid,HVM_PARAM_VPT_ALIGN , (unsigned long ) info->vpt_align);xc_domain_max_vcpus (ctx->xch, domid, info->max_vcpus);xc_domain_setmaxmem (ctx->xch, domid, info->max_memkb + info->video_memkb); -xc_domain_set_memmap_limit (ctx->xch, domid, info->max_memkb); +xc_domain_set_memmap_limit (ctx->xch, domid, + (info->hvm) ? info->max_memkb : + (info->max_memkb + info->u.pv.slack_memkb));if (info->hvm) {unsigned long shadow;
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Re: [PATCH 3/7] libxenlight meta-resend: physmap slack for pv domains
I don't think this one got Acked. I've applied all your other patches however.
-- Keir
Quoted 13 lines · Andres Lagar-Cavilla
Contemplate a memory space slack for PV domains, since they do ballooning (or flipping network rx) and need some extra room in their pfn space.
Note that this does not allocate any extra memory to the domain, it simply extends the physmap with some extra room for "bounce bufffering back" pfn's that are yielded to dom0.
The default slack is set at 8MB.
Signed-off-by Andres Lagar-Cavilla <[email protected]>