Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp5167430rdb; Wed, 13 Dec 2023 00:16:08 -0800 (PST) X-Google-Smtp-Source: AGHT+IEcYjdkul6jiHedEAVOuWbzqMRcYcM2jMIkQK7f61fwCg9cNpv0cEjVqY2dStQmf9lpDzNN X-Received: by 2002:a05:6e02:144d:b0:35d:5f75:3651 with SMTP id p13-20020a056e02144d00b0035d5f753651mr12831090ilo.51.1702455368382; Wed, 13 Dec 2023 00:16:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702455368; cv=none; d=google.com; s=arc-20160816; b=fPQcGIWu8Es43i0devq5B/4udh452mqWUj9H2+V6+ZwrhL44SQA3iBq3/IHYEZhdL2 6H9jqmUT8owQi7ty4iAJmGvpSY+S9z8lc4rPVqIgKfBzVZrylIFXYmOVL4PcwS0n0gSv l7Cx1doggZ857tQGRbAu+TroK5yx1mjL2gt5yZVNIOB2rQAyvcE6x6RoLXMzG7I8sqYQ 5dNIkEz99lLcDqx4qrb5bJOKAeViTize6qKHTKjoNZMXoYmv8oJbDn6shFRllEgIO3s1 3p77VZDCJZbUFCG6qZTrBLvHJtywiPZYKSzizyL2pZTEDESM2yVOTl9mKy+WZFyrGDhk HFEw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id; bh=qjwTocydKz39yX2qrGQzWTbyZdoYZB8IXgRXVewYyQ8=; fh=4lic6PKx/vcplmlZ6D7daY3UFonM/f99NYa21LJ8DRk=; b=UEqZjCgSpJrv/xAUmHHhFays/GgkOzr+kkhNw8iuBA9ZpsWVWLI9JEy585yyzb7V/h hb9PdEJbN/ZoQZ1S92bYOkKEvCWKWEJNk+DDRP2VmVG+b58K5vNCA7U+XIbEnMQ/RdST VrEufDWI+q5dIVg9BaeuDiPoc8CLjYami/116t1iEdA8ISTvLDYL7f4LLBezd0aUYhzJ ksDaZb+p5qwm+7RiHwk9lNIG3Lpy2UepbKjGUBQPWnN7toh1J6ireFPr3MQXEYr76SmE hUogZn5D64FWDVX+K/JiNC1Z1xjOSC9kEWxeDDjd6HWVkfptfJ7639koPcgVxJvt6nye aUzw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id u7-20020a170902e80700b001d0231f5e30si9249110plg.295.2023.12.13.00.16.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Dec 2023 00:16:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id 8E8C28076CAC; Wed, 13 Dec 2023 00:16:05 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232144AbjLMIPt (ORCPT + 99 others); Wed, 13 Dec 2023 03:15:49 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60032 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231502AbjLMIPs (ORCPT ); Wed, 13 Dec 2023 03:15:48 -0500 Received: from fd01.gateway.ufhost.com (fd01.gateway.ufhost.com [61.152.239.71]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4997CDC; Wed, 13 Dec 2023 00:15:49 -0800 (PST) Received: from EXMBX166.cuchost.com (unknown [175.102.18.54]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "EXMBX166", Issuer "EXMBX166" (not verified)) by fd01.gateway.ufhost.com (Postfix) with ESMTP id 5B74582A9; Wed, 13 Dec 2023 16:15:41 +0800 (CST) Received: from EXMBX171.cuchost.com (172.16.6.91) by EXMBX166.cuchost.com (172.16.6.76) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Wed, 13 Dec 2023 16:15:41 +0800 Received: from [192.168.125.85] (183.27.97.57) by EXMBX171.cuchost.com (172.16.6.91) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Wed, 13 Dec 2023 16:15:40 +0800 Message-ID: <9523aa6b-55a8-4e6a-a3ba-45d9b1dacc77@starfivetech.com> Date: Wed, 13 Dec 2023 16:15:39 +0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v12 15/21] PCI: microchip: Add event IRQ domain ops to struct plda_event Content-Language: en-US To: Lorenzo Pieralisi CC: Conor Dooley , =?UTF-8?Q?Krzysztof_Wilczy=C5=84ski?= , Rob Herring , Bjorn Helgaas , Daire McNamara , "Emil Renner Berthing" , Krzysztof Kozlowski , , , , , Paul Walmsley , "Palmer Dabbelt" , Albert Ou , "Philipp Zabel" , Mason Huo , Leyfoon Tan , Kevin Xie References: <20231206105839.25805-1-minda.chen@starfivetech.com> <20231206105839.25805-16-minda.chen@starfivetech.com> From: Minda Chen In-Reply-To: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [183.27.97.57] X-ClientProxiedBy: EXCAS064.cuchost.com (172.16.6.24) To EXMBX171.cuchost.com (172.16.6.91) X-YovoleRuleAgent: yovoleflag X-Spam-Status: No, score=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Wed, 13 Dec 2023 00:16:05 -0800 (PST) On 2023/12/12 19:19, Lorenzo Pieralisi wrote: > On Wed, Dec 06, 2023 at 06:58:33PM +0800, Minda Chen wrote: >> For lack of an MSI controller, The new added PCIe interrupts have to be >> added to global interrupt event field. PolarFire event domain ops can not >> be re-used. > > I don't understand what this means, please explain and I will > add it to the commit log. > Sorry. Microchip Polarfire PCIe adds 11 PCIe interrupts to PCIe global event domain.(Total 28 PCIe interrupts) The microchip event domain and event irqchip will handle these interrupts. But PLDA host contain 13 fixed PCIe interrupts. PLDA codes just process these 13 interrupts. Microchip the event irq codes are quite different and can't be used by PLDA codes. So add an event domain field support microchip and other vendor who just using the PLDA interrupts. >> PLDA event domain ops instances will be implemented in later patch. > > Future patches don't exist, each commit log is a logical change > that must make sense on its own, I will remove this sentence. > > Lorenzo OK, Thanks. >> Signed-off-by: Minda Chen >> Acked-by: Conor Dooley >> --- >> drivers/pci/controller/plda/pcie-microchip-host.c | 6 ++++-- >> drivers/pci/controller/plda/pcie-plda.h | 1 + >> 2 files changed, 5 insertions(+), 2 deletions(-) >> >> diff --git a/drivers/pci/controller/plda/pcie-microchip-host.c b/drivers/pci/controller/plda/pcie-microchip-host.c >> index f5e7da242aec..e6dcc572b65b 100644 >> --- a/drivers/pci/controller/plda/pcie-microchip-host.c >> +++ b/drivers/pci/controller/plda/pcie-microchip-host.c >> @@ -821,13 +821,15 @@ static const struct plda_event_ops mc_event_ops = { >> }; >> >> static const struct plda_event mc_event = { >> + .domain_ops = &mc_event_domain_ops, >> .event_ops = &mc_event_ops, >> .request_event_irq = mc_request_event_irq, >> .intx_event = EVENT_LOCAL_PM_MSI_INT_INTX, >> .msi_event = EVENT_LOCAL_PM_MSI_INT_MSI, >> }; >> >> -static int plda_pcie_init_irq_domains(struct plda_pcie_rp *port) >> +static int plda_pcie_init_irq_domains(struct plda_pcie_rp *port, >> + const struct irq_domain_ops *ops) >> { >> struct device *dev = port->dev; >> struct device_node *node = dev->of_node; >> @@ -941,7 +943,7 @@ static int plda_init_interrupts(struct platform_device *pdev, >> return -EINVAL; >> } >> >> - ret = plda_pcie_init_irq_domains(port); >> + ret = plda_pcie_init_irq_domains(port, event->domain_ops); >> if (ret) { >> dev_err(dev, "failed creating IRQ domains\n"); >> return ret; >> diff --git a/drivers/pci/controller/plda/pcie-plda.h b/drivers/pci/controller/plda/pcie-plda.h >> index df1729095952..820ea16855b5 100644 >> --- a/drivers/pci/controller/plda/pcie-plda.h >> +++ b/drivers/pci/controller/plda/pcie-plda.h >> @@ -129,6 +129,7 @@ struct plda_pcie_rp { >> }; >> >> struct plda_event { >> + const struct irq_domain_ops *domain_ops; >> const struct plda_event_ops *event_ops; >> int (*request_event_irq)(struct plda_pcie_rp *pcie, >> int event_irq, int event); >> -- >> 2.17.1 >>