From mboxrd@z Thu Jan 1 00:00:00 1970 From: Hanjun Guo Subject: Re: [PATCH v5 6/9] irqchip/gic-v3: Parse and export virtual GIC information Date: Wed, 13 Apr 2016 18:11:08 +0800 Message-ID: <570E1B3C.8010800@linaro.org> References: <1459769860-6629-1-git-send-email-julien.grall@arm.com> <1459769860-6629-7-git-send-email-julien.grall@arm.com> <570B35DA.5050600@linaro.org> <570BB461.4040704@arm.com> <570BC1ED.9080200@codeaurora.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: Received: from localhost (localhost [127.0.0.1]) by mm01.cs.columbia.edu (Postfix) with ESMTP id 60EEA49B4E for ; Wed, 13 Apr 2016 06:09:41 -0400 (EDT) Received: from mm01.cs.columbia.edu ([127.0.0.1]) by localhost (mm01.cs.columbia.edu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Ydg3hIRuxqzy for ; Wed, 13 Apr 2016 06:09:40 -0400 (EDT) Received: from mail-pa0-f44.google.com (mail-pa0-f44.google.com [209.85.220.44]) by mm01.cs.columbia.edu (Postfix) with ESMTPS id 6395849B46 for ; Wed, 13 Apr 2016 06:09:40 -0400 (EDT) Received: by mail-pa0-f44.google.com with SMTP id fs9so12240881pac.2 for ; Wed, 13 Apr 2016 03:11:20 -0700 (PDT) In-Reply-To: <570BC1ED.9080200@codeaurora.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kvmarm-bounces@lists.cs.columbia.edu Sender: kvmarm-bounces@lists.cs.columbia.edu To: Shanker Donthineni , Julien Grall , kvmarm@lists.cs.columbia.edu Cc: al.stone@linaro.org, kvm@vger.kernel.org, marc.zyngier@arm.com, linux-kernel@vger.kernel.org, gg@slimlogic.co.uk, linux-arm-kernel@lists.infradead.org, Thomas Gleixner , fu.wei@linaro.org, Jason Cooper List-Id: kvmarm@lists.cs.columbia.edu Hi Shanker, Julien, On 2016/4/11 23:25, Shanker Donthineni wrote: > Hi Julien, > > On 04/11/2016 09:27 AM, Julien Grall wrote: >> Hello Hanjun, >> >> On 11/04/16 06:27, Hanjun Guo wrote: >>> On 2016/4/4 19:37, Julien Grall wrote: >>>> +static void __init gic_acpi_setup_kvm_info(void) >>>> +{ >>>> + int irq; >>>> + >>>> + if (!gic_acpi_collect_virt_info()) { >>>> + pr_warn("Unable to get hardware information used for >>>> virtualization\n"); >>>> + return; >>>> + } >>>> + >>>> + gic_v3_kvm_info.type = GIC_V3; >>>> + >>>> + irq = acpi_register_gsi(NULL, acpi_data.maint_irq, >>>> + acpi_data.maint_irq_mode, >>>> + ACPI_ACTIVE_HIGH); >>>> + if (irq <= 0) >>>> + return; >>>> + >>>> + gic_v3_kvm_info.maint_irq = irq; >>>> + >>>> + if (acpi_data.vcpu_base) { >>> >>> Sorry, I'm not familiar with KVM, but I got a question here, will >>> KVM works without valid vcpu_base in GICv3 mode? >> > Yes, KVM works without vcpu_base in GICv3 mode. The vcpu_base will be used > for emulatingvGICv2 feature. The vGICv3 emulation isdone through the > system registers. > >> vcpu_base is only required for supporting GICv2 on GICv3. >> > Yes, you are right, Thanks for the clarify. Hanjun From mboxrd@z Thu Jan 1 00:00:00 1970 From: hanjun.guo@linaro.org (Hanjun Guo) Date: Wed, 13 Apr 2016 18:11:08 +0800 Subject: [PATCH v5 6/9] irqchip/gic-v3: Parse and export virtual GIC information In-Reply-To: <570BC1ED.9080200@codeaurora.org> References: <1459769860-6629-1-git-send-email-julien.grall@arm.com> <1459769860-6629-7-git-send-email-julien.grall@arm.com> <570B35DA.5050600@linaro.org> <570BB461.4040704@arm.com> <570BC1ED.9080200@codeaurora.org> Message-ID: <570E1B3C.8010800@linaro.org> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org Hi Shanker, Julien, On 2016/4/11 23:25, Shanker Donthineni wrote: > Hi Julien, > > On 04/11/2016 09:27 AM, Julien Grall wrote: >> Hello Hanjun, >> >> On 11/04/16 06:27, Hanjun Guo wrote: >>> On 2016/4/4 19:37, Julien Grall wrote: >>>> +static void __init gic_acpi_setup_kvm_info(void) >>>> +{ >>>> + int irq; >>>> + >>>> + if (!gic_acpi_collect_virt_info()) { >>>> + pr_warn("Unable to get hardware information used for >>>> virtualization\n"); >>>> + return; >>>> + } >>>> + >>>> + gic_v3_kvm_info.type = GIC_V3; >>>> + >>>> + irq = acpi_register_gsi(NULL, acpi_data.maint_irq, >>>> + acpi_data.maint_irq_mode, >>>> + ACPI_ACTIVE_HIGH); >>>> + if (irq <= 0) >>>> + return; >>>> + >>>> + gic_v3_kvm_info.maint_irq = irq; >>>> + >>>> + if (acpi_data.vcpu_base) { >>> >>> Sorry, I'm not familiar with KVM, but I got a question here, will >>> KVM works without valid vcpu_base in GICv3 mode? >> > Yes, KVM works without vcpu_base in GICv3 mode. The vcpu_base will be used > for emulatingvGICv2 feature. The vGICv3 emulation isdone through the > system registers. > >> vcpu_base is only required for supporting GICv2 on GICv3. >> > Yes, you are right, Thanks for the clarify. Hanjun From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1030791AbcDMKLX (ORCPT ); Wed, 13 Apr 2016 06:11:23 -0400 Received: from mail-pa0-f53.google.com ([209.85.220.53]:33692 "EHLO mail-pa0-f53.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1030725AbcDMKLU (ORCPT ); Wed, 13 Apr 2016 06:11:20 -0400 Subject: Re: [PATCH v5 6/9] irqchip/gic-v3: Parse and export virtual GIC information To: Shanker Donthineni , Julien Grall , kvmarm@lists.cs.columbia.edu References: <1459769860-6629-1-git-send-email-julien.grall@arm.com> <1459769860-6629-7-git-send-email-julien.grall@arm.com> <570B35DA.5050600@linaro.org> <570BB461.4040704@arm.com> <570BC1ED.9080200@codeaurora.org> Cc: al.stone@linaro.org, kvm@vger.kernel.org, marc.zyngier@arm.com, linux-kernel@vger.kernel.org, fu.wei@linaro.org, Thomas Gleixner , Jason Cooper , linux-arm-kernel@lists.infradead.org, gg@slimlogic.co.uk From: Hanjun Guo Message-ID: <570E1B3C.8010800@linaro.org> Date: Wed, 13 Apr 2016 18:11:08 +0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.7.2 MIME-Version: 1.0 In-Reply-To: <570BC1ED.9080200@codeaurora.org> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Shanker, Julien, On 2016/4/11 23:25, Shanker Donthineni wrote: > Hi Julien, > > On 04/11/2016 09:27 AM, Julien Grall wrote: >> Hello Hanjun, >> >> On 11/04/16 06:27, Hanjun Guo wrote: >>> On 2016/4/4 19:37, Julien Grall wrote: >>>> +static void __init gic_acpi_setup_kvm_info(void) >>>> +{ >>>> + int irq; >>>> + >>>> + if (!gic_acpi_collect_virt_info()) { >>>> + pr_warn("Unable to get hardware information used for >>>> virtualization\n"); >>>> + return; >>>> + } >>>> + >>>> + gic_v3_kvm_info.type = GIC_V3; >>>> + >>>> + irq = acpi_register_gsi(NULL, acpi_data.maint_irq, >>>> + acpi_data.maint_irq_mode, >>>> + ACPI_ACTIVE_HIGH); >>>> + if (irq <= 0) >>>> + return; >>>> + >>>> + gic_v3_kvm_info.maint_irq = irq; >>>> + >>>> + if (acpi_data.vcpu_base) { >>> >>> Sorry, I'm not familiar with KVM, but I got a question here, will >>> KVM works without valid vcpu_base in GICv3 mode? >> > Yes, KVM works without vcpu_base in GICv3 mode. The vcpu_base will be used > for emulatingvGICv2 feature. The vGICv3 emulation isdone through the > system registers. > >> vcpu_base is only required for supporting GICv2 on GICv3. >> > Yes, you are right, Thanks for the clarify. Hanjun