From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Otte Subject: [patch 09/11] [PATCH] kvm-s390: fix assumption for KVM_MAX_VCPUS Date: Wed, 04 Jan 2012 10:25:28 +0100 Message-ID: <20120104093602.746999089@de.ibm.com> References: <20120104092519.060746143@de.ibm.com> Cc: Christian Borntraeger , Heiko Carstens , Martin Schwidefsky , Cornelia Huck , KVM , Joachim von Buttlar , Jens Freimann , agraf@suse.de To: Avi Kivity , Marcelo Tossati Return-path: Received: from e06smtp18.uk.ibm.com ([195.75.94.114]:34384 "EHLO e06smtp18.uk.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754944Ab2ADJgi (ORCPT ); Wed, 4 Jan 2012 04:36:38 -0500 Received: from /spool/local by e06smtp18.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Wed, 4 Jan 2012 09:36:36 -0000 Received: from d06av02.portsmouth.uk.ibm.com (d06av02.portsmouth.uk.ibm.com [9.149.37.228]) by d06nrmr1407.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id q049a3qr2277580 for ; Wed, 4 Jan 2012 09:36:03 GMT Received: from d06av02.portsmouth.uk.ibm.com (loopback [127.0.0.1]) by d06av02.portsmouth.uk.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id q049a3eC001265 for ; Wed, 4 Jan 2012 02:36:03 -0700 Content-Disposition: inline; filename=allow-more-than-64-vcpus.patch Sender: kvm-owner@vger.kernel.org List-ID: This patch fixes definition of the idle_mask and the local_int array in kvm_s390_float_interrupt. Previous definition had 64 cpus max hardcoded instead of using KVM_MAX_VCPUS. Signed-off-by: Carsten Otte --- Index: linux-2.5-cecsim/arch/s390/include/asm/kvm_host.h =================================================================== --- linux-2.5-cecsim.orig/arch/s390/include/asm/kvm_host.h +++ linux-2.5-cecsim/arch/s390/include/asm/kvm_host.h @@ -220,8 +220,9 @@ struct kvm_s390_float_interrupt { struct list_head list; atomic_t active; int next_rr_cpu; - unsigned long idle_mask [(64 + sizeof(long) - 1) / sizeof(long)]; - struct kvm_s390_local_interrupt *local_int[64]; + unsigned long idle_mask[(KVM_MAX_VCPUS + sizeof(long) - 1) + / sizeof(long)]; + struct kvm_s390_local_interrupt *local_int[KVM_MAX_VCPUS]; };