Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp2268596ybn; Thu, 26 Sep 2019 09:21:14 -0700 (PDT) X-Google-Smtp-Source: APXvYqwyQCZkIx+T9ZxCI2EKhSTWWRjJF3RJE3+QZ2SPesyZuJ9pVF98yTfh6xGyUYGnf9oO6rlO X-Received: by 2002:a17:906:5284:: with SMTP id c4mr4011337ejm.39.1569514874318; Thu, 26 Sep 2019 09:21:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569514874; cv=none; d=google.com; s=arc-20160816; b=gpWJvlbB2doT6+0TQt4qTPu/J6GNR9RIub1Zt0l7a2MHwbjwGCXwaWwomGOsmIZN2h qfulz90co6OzKR9I7aq0VYQl48dsidwKAlOgOkIr2vEKm47dWMl8+0qQC5BJIXA9KZ1m W+JY9fxQMySgYe75yEcGajjD2GkC0NrnvrFOjR/EGFoAzXpEIJg9KQvD7iwKkDP0u/7k Yjwinaq8f4IGk6f6Vc7m+KeDVcTCFgMfvkCLO5Xpcr9rcKiC0ZNvVABD1yA8SnNtdJfl kFmq2AB00X2tWZTaNyBE0XK6qZIyad5wvpBBfiDXKVlBHYEYMIcZLgZt/0eljSFs7bZF YiaA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:organization:from:references:cc:to:subject; bh=0q16Nxqne1DLLk2umsc5VmmGEddhIXi+JuchttoYXms=; b=GuCkk7PlDvRhgPYMHjEPFdLmOk1A54wtOTNZ3VO5GygMqxlKhmdzNayLN8M1wwJiK2 LBQbd7L2cSUtQR2cPKdpC7k3KCbC2bcPU6hXXlmWoWoZmUqvxECmZqFqK9E5libZlcrp Qv75JmiuItLWsJuBRiRpMXzucKRN0qQAeihfExM24hYnpueOfCRrewEzRWmry0PoVuQT bzCtwWE8or687QR8p9WSFQYeoQrXUk+GqooA6l+OYvKp8LAlHBoGm7CC6eifHG7JRqN2 cRaCjSvbrQJdgDfqGIkrPoyMLe/jx84LlD6d2gNPU+1f9aEujQj31R4XdWPyHCCKot42 yiig== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 64si1990220edf.34.2019.09.26.09.20.50; Thu, 26 Sep 2019 09:21:14 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727431AbfIZQRd (ORCPT + 99 others); Thu, 26 Sep 2019 12:17:33 -0400 Received: from foss.arm.com ([217.140.110.172]:54080 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727239AbfIZQRc (ORCPT ); Thu, 26 Sep 2019 12:17:32 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 6E1AD28; Thu, 26 Sep 2019 09:17:32 -0700 (PDT) Received: from [10.1.197.61] (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id A02A13F534; Thu, 26 Sep 2019 09:17:31 -0700 (PDT) Subject: Re: [PATCH 03/35] irqchip/gic-v3-its: Allow LPI invalidation via the DirectLPI interface To: Zenghui Yu , kvmarm@lists.cs.columbia.edu, linux-kernel@vger.kernel.org Cc: Lorenzo Pieralisi , Jason Cooper , Thomas Gleixner References: <20190923182606.32100-1-maz@kernel.org> <20190923182606.32100-4-maz@kernel.org> <92ff82ca-ebcb-8f5f-5063-313f65bbc5e3@huawei.com> From: Marc Zyngier Organization: Approximate Message-ID: <22202880-9a99-f0d9-4737-6112d60b30a6@kernel.org> Date: Thu, 26 Sep 2019 17:17:27 +0100 User-Agent: Mozilla/5.0 (X11; Linux aarch64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0 MIME-Version: 1.0 In-Reply-To: <92ff82ca-ebcb-8f5f-5063-313f65bbc5e3@huawei.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 26/09/2019 15:57, Zenghui Yu wrote: > Hi Marc, > > I get one kernel panic with this patch on D05. Can you please try this (completely untested for now) on top of the whole series? I'll otherwise give it a go next week. Thanks, M. diff --git a/drivers/irqchip/irq-gic-v3-its.c b/drivers/irqchip/irq-gic-v3-its.c index bc55327406b7..9d24236d1257 100644 --- a/drivers/irqchip/irq-gic-v3-its.c +++ b/drivers/irqchip/irq-gic-v3-its.c @@ -3461,15 +3461,16 @@ static void its_vpe_send_cmd(struct its_vpe *vpe, static void its_vpe_send_inv(struct irq_data *d) { + struct its_vpe *vpe = irq_data_get_irq_chip_data(d); + if (gic_rdists->has_direct_lpi) { - /* - * Don't mess about. Generating the invalidation is easily - * done by using the parent irq_data, just like below. - */ - direct_lpi_inv(d->parent_data); - } else { - struct its_vpe *vpe = irq_data_get_irq_chip_data(d); + void __iomem *rdbase; + /* Target the redistributor this VPE is currently known on */ + rdbase = per_cpu_ptr(gic_rdists->rdist, vpe->col_idx)->rd_base; + gic_write_lpir(d->parent_data->hwirq, rdbase + GICR_INVLPIR); + wait_for_syncr(rdbase); + } else { its_vpe_send_cmd(vpe, its_send_inv); } } -- Jazz is not dead, it just smells funny...