From: "KUWAMURA Shin'ya" Subject: [PATCH] [Linux] ia64, xencomm: fix XEN_SYSCTL_cpupool_op Date: Fri, 10 Sep 2010 17:29:15 +0900 (JST) Message-ID: <20100910.172915.326873435.kuwa@jp.fujitsu.com> Mime-Version: 1.0 Content-Type: Multipart/Mixed; boundary="--Next_Part(Fri_Sep_10_17_29_15_2010_818)--" Content-Transfer-Encoding: 7bit Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org ----Next_Part(Fri_Sep_10_17_29_15_2010_818)-- Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Hi, This patch is applied to linux-2.6.18-xen.hg. Because the cpumap member of struct xen_sysctl_cpupool_op is used only when the operation is XEN_SYSCTL_CPUPOOL_OP_INFO or XEN_SYSCTL_CPUPOOL_OP_FREEINFO, in case of others, xencomm_map to cpumap fails, thus XEN_SYSCTL_cpupool_op fails. This patch fixes it. Signed-off-by: KUWAMURA Shin'ya -- KUWAMURA Shin'ya ----Next_Part(Fri_Sep_10_17_29_15_2010_818)-- Content-Type: Text/X-Patch; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="fix-cpupool-xencomm.patch" # HG changeset patch # User KUWAMURA Shin'ya # Date 1283495302 -32400 # Node ID 800fb02afdce9f0bde4a95c9c1e6d97f1dc27313 # Parent 9b1adfb8b0b3b37c13f06c0adb8dd17b2a0a077d ia64, xencomm: fix XEN_SYSCTL_cpupool_op Because the cpumap member of struct xen_sysctl_cpupool_op is used only when the operation is XEN_SYSCTL_CPUPOOL_OP_INFO or XEN_SYSCTL_CPUPOOL_OP_FREEINFO, in case of others, xencomm_map to cpumap fails, thus XEN_SYSCTL_cpupool_op fails. This patch fixes it. Signed-off-by: KUWAMURA Shin'ya diff -r 9b1adfb8b0b3 -r 800fb02afdce arch/ia64/xen/xcom_privcmd.c --- a/arch/ia64/xen/xcom_privcmd.c Thu Aug 26 11:27:25 2010 +0100 +++ b/arch/ia64/xen/xcom_privcmd.c Fri Sep 03 15:28:22 2010 +0900 @@ -283,6 +283,9 @@ xencomm_privcmd_sysctl(privcmd_hypercall } case XEN_SYSCTL_cpupool_op: + if (kern_op.u.cpupool_op.op != XEN_SYSCTL_CPUPOOL_OP_INFO && + kern_op.u.cpupool_op.op != XEN_SYSCTL_CPUPOOL_OP_FREEINFO) + break; desc = xencomm_map( xen_guest_handle(kern_op.u.cpupool_op.cpumap.bitmap), ROUND_DIV(kern_op.u.cpupool_op.cpumap.nr_cpus, 8)); ----Next_Part(Fri_Sep_10_17_29_15_2010_818)-- Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel ----Next_Part(Fri_Sep_10_17_29_15_2010_818)----