From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753449AbdBMVjy (ORCPT ); Mon, 13 Feb 2017 16:39:54 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:57116 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752781AbdBMVjx (ORCPT ); Mon, 13 Feb 2017 16:39:53 -0500 DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 2CB34607B3 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=shankerd@codeaurora.org Reply-To: shankerd@codeaurora.org Subject: Re: [RFC PATCH 02/33] irqchip/gic-v3: Add VLPI/DirectLPI discovery References: <1484648454-21216-1-git-send-email-marc.zyngier@arm.com> <1484648454-21216-3-git-send-email-marc.zyngier@arm.com> To: Marc Zyngier , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kvmarm@lists.cs.columbia.edu Cc: Thomas Gleixner , Jason Cooper From: Shanker Donthineni Message-ID: <778dd3ec-b395-6883-f047-bea56ac54572@codeaurora.org> Date: Mon, 13 Feb 2017 15:39:49 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 MIME-Version: 1.0 In-Reply-To: <1484648454-21216-3-git-send-email-marc.zyngier@arm.com> 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 On 01/17/2017 04:20 AM, Marc Zyngier wrote: > Add helper functions that probe for VLPI and DirectLPI properties. > > Signed-off-by: Marc Zyngier > --- > drivers/irqchip/irq-gic-v3.c | 22 ++++++++++++++++++++++ > include/linux/irqchip/arm-gic-v3.h | 3 +++ > 2 files changed, 25 insertions(+) > > diff --git a/drivers/irqchip/irq-gic-v3.c b/drivers/irqchip/irq-gic-v3.c > index 5cadec0..8a6de91 100644 > --- a/drivers/irqchip/irq-gic-v3.c > +++ b/drivers/irqchip/irq-gic-v3.c > @@ -514,6 +514,24 @@ static int gic_populate_rdist(void) > return -ENODEV; > } > > +static int __gic_update_vlpi_properties(struct redist_region *region, > + void __iomem *ptr) > +{ > + u64 typer = gic_read_typer(ptr + GICR_TYPER); > + gic_data.rdists.has_vlpis &= !!(typer & GICR_TYPER_VLPIS); > + gic_data.rdists.has_direct_lpi &= !!(typer & > GICR_TYPER_DirectLPIS); > + > + return 1; > +} > + > +static void gic_update_vlpi_properties(void) > +{ > + gic_scan_rdist_properties(__gic_update_vlpi_properties); > + pr_info("%sVLPI support, %sdirect LPI support\n", Would be better if we keep one space after 'no'? -- Shanker Donthineni Qualcomm Datacenter Technologies, Inc. as an affiliate of Qualcomm Technologies, Inc. Qualcomm Technologies, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project.