From: Ian Campbell Subject: Re: [PATCH 2/2] libxl: xl mem-set should not enforce memory limits Date: Fri, 15 Mar 2013 16:32:53 +0000 Message-ID: <1363365173.520.33.camel@zakaz.uk.xensource.com> References: <1363364702-12885-1-git-send-email-daniel.kiper@oracle.com> <1363364702-12885-3-git-send-email-daniel.kiper@oracle.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1363364702-12885-3-git-send-email-daniel.kiper@oracle.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Daniel Kiper Cc: "xen-devel@lists.xensource.com" , Ian Jackson List-Id: xen-devel@lists.xenproject.org On Fri, 2013-03-15 at 16:25 +0000, Daniel Kiper wrote: > xl mem-set should not enforce memory limits. If it does NB the title says libxl but this is actually an xl change. > then after decreasing reservation there is no chance to > increase reservation directly from guest domain by > writing to /sys/devices/system/xen_memory/xen_memory0/target* This is a feature not a bug I think. It is intentional that if the host admin sets a memory target the a guest admin cannot exceed that limit. Ian. > > Signed-off-by: Daniel Kiper > --- > tools/libxl/xl_cmdimpl.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/tools/libxl/xl_cmdimpl.c b/tools/libxl/xl_cmdimpl.c > index a98705e..9add281 100644 > --- a/tools/libxl/xl_cmdimpl.c > +++ b/tools/libxl/xl_cmdimpl.c > @@ -2492,7 +2492,7 @@ static void set_memory_target(uint32_t domid, const char *mem) > exit(3); > } > > - libxl_set_memory_target(ctx, domid, memorykb, 0, /* enforce */ 1); > + libxl_set_memory_target(ctx, domid, memorykb, 0, 0); > } > > int main_memset(int argc, char **argv)