From: "Jan Beulich" Subject: Re: [PATCH 02/19] xen: make two memory hypercalls vNUMA-aware Date: Fri, 21 Nov 2014 17:03:09 +0000 Message-ID: <546F7E5D0200007800049EA3@mail.emea.novell.com> References: <1416582421-10789-1-git-send-email-wei.liu2@citrix.com> <1416582421-10789-3-git-send-email-wei.liu2@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1416582421-10789-3-git-send-email-wei.liu2@citrix.com> Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Wei Liu Cc: xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org >>> On 21.11.14 at 16:06, wrote: > @@ -747,6 +786,17 @@ long do_memory_op(unsigned long cmd, XEN_GUEST_HANDLE_PARAM(void) arg) > return start_extent; > args.domain = d; > > + args.memflags |= MEMF_node(XENMEMF_get_node(reservation.mem_flags)); > + if ( reservation.mem_flags & XENMEMF_exact_node_request ) > + args.memflags |= MEMF_exact_node; > + > + rc = translate_vnode_to_pnode(d, &reservation, &args); > + if ( rc ) > + { > + rcu_unlock_domain(d); > + return rc; I'm afraid you got misguided here by the (buggy) adjacent XSM error path: You shouldn't return a negative error code but "start_extent" here. And I'll try to remember to fix the XSM path post-4.5. > +/* Guset can use XENMEMF_vnode to specify virtual node for memory op. */ > +#define XENFEAT_memory_op_vnode_supported 13 You introduce this flag but then don't use it? Also there's a typo in the comment. Jan