From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52572) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YvRAz-0000CU-BE for qemu-devel@nongnu.org; Thu, 21 May 2015 10:10:25 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YvRAu-0005Au-8w for qemu-devel@nongnu.org; Thu, 21 May 2015 10:10:21 -0400 Received: from mailout4.w1.samsung.com ([210.118.77.14]:26881) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YvRAu-0005Ab-3Q for qemu-devel@nongnu.org; Thu, 21 May 2015 10:10:16 -0400 Received: from eucpsbgm1.samsung.com (unknown [203.254.199.244]) by mailout4.w1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0NOP006AHE10KHA0@mailout4.w1.samsung.com> for qemu-devel@nongnu.org; Thu, 21 May 2015 15:10:12 +0100 (BST) From: Pavel Fedin References: <1431624430-3996-1-git-send-email-ashoks@broadcom.com> <00c401d08eda$57394490$05abcdb0$@samsung.com> <555B31A4.9050708@linaro.org> <007101d09391$f20306d0$d6091470$@samsung.com> <555D9E71.5060703@linaro.org> In-reply-to: <555D9E71.5060703@linaro.org> Date: Thu, 21 May 2015 17:10:07 +0300 Message-id: <014801d093cf$da300d80$8e902880$@samsung.com> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii Content-transfer-encoding: 7bit Content-language: ru Subject: Re: [Qemu-devel] [RFC PATCH] hw/arm/virt: Added preliminary GICv3 support for kvm mode List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: 'Eric Auger' , 'Ashok Kumar' , qemu-devel@nongnu.org Cc: 'Shlomo Pongratz' Hello! > So to me it is sensible to instantiate GICV2 through legacy > KVM_CREATE_IRQCHIP API if both KVM_CREATE_DEVICE(test mode=true) failed. I disagree because at this point we already know which GIC version the user wants. This is because kvm_irqchip_create() is called after machine instance is created (and virt_instance_init() has been called). At this point we already know all the options. At this point i think the scenario should be: a) If we want GICv3 - test for KVM_CREATE_DEVICE(GICv3) and fail if we don't have one. b) If we want GICv2 - test for KVM_CREATE_DEVICE(GICv2). If it fails, try KVM_CREATE_IRQCHIP. IMHO there is little sense to fall back from v3 to v2 or vice versa because other important parameters (like number of CPUs) depend on it. Implementing this behavior costs only one more integer in MachineState structure. Is it too large ? If you want, i can post my patches as RFC, i think now they are more or less OK. Kind regards, Pavel Fedin Expert Engineer Samsung Electronics Research center Russia