Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp3727329rdg; Wed, 18 Oct 2023 04:31:29 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHy9t/tqAkWPu4aWDhneu40aL3dyWAcXNJTyAIfREHxozmgLsTFh6kjX8ZiSHtLXY0uoNUH X-Received: by 2002:a05:6359:d30:b0:166:ee7f:dc7 with SMTP id gp48-20020a0563590d3000b00166ee7f0dc7mr1879863rwb.14.1697628688910; Wed, 18 Oct 2023 04:31:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697628688; cv=none; d=google.com; s=arc-20160816; b=oqg6ue13z5IGuuiguk4JpLzZeaAZw5lP9uvx8ZSZQaSJvwXvm4qWmYS3e4d5dOSZbK ksOLmlUWHxvT/avFrfFiy76m0rA7UWQ4o3KXeUSkYp7siXkd/KYMDw+ju2xlKLit92Ya l8BeuRED62oFfqavC1oNW/zBPBpFW4ix8mpLQXv7aBB72IZBMYJVf+vD88Cr68pCFIlp lMCGODZq8n75kH7f3RXWgONanuros/ebCTYiHaRBu0JNNImuWjI0zSqjR2cOgPDL3Bw3 v0qW8mMn2HqP/1BGlSEPwpGGefq/6r72QsjgWDGS99yLBT+o4njOLQypOtWYdr0yCNQe mDYA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=6/VTKYCyOAiPJJHjJ4x+KXkjfswML+9npJuO9/Fv71E=; fh=UwJF0cmN4EbbbJQYNeQBi16R6caNIm1BUmE7y7GO72w=; b=pG8Ri2/1OAOChMIr0DJu62mb/hjOZl3m57C2M/buwRk1Ig+mphA+r/jH/t78fHHhCc 3qWsyt1s+mFI7DABQCNiKi0yLEmIB3juBrz6ohmXKaL8iBJDYPcflfFhqRyR2lZNMf5/ jrcTVBUOoud9fm49g77+MvQBf7YgvCD7TphPywUobGB6K7l9jfWet8MbKwoB1iCrLY8c UZh4o+KNegj8AmKuK08aGQyJZjkEE6Nx1Le2/E2xWto8LMYTS3UKLatcr0NboK1awzhZ jKgBcfUCI6aFtNJKWZ4lQoTguTou+LibVqVj2eGwIs/euvMGi/vsvlSG4zzWCpQGpY26 AQxg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=hO7SQdvI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from fry.vger.email (fry.vger.email. [23.128.96.38]) by mx.google.com with ESMTPS id d24-20020a656218000000b005893c5bd119si1899276pgv.425.2023.10.18.04.31.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Oct 2023 04:31:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) client-ip=23.128.96.38; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=hO7SQdvI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 51DDE811678D; Wed, 18 Oct 2023 04:31:26 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229690AbjJRLbG (ORCPT + 99 others); Wed, 18 Oct 2023 07:31:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55278 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229986AbjJRLbE (ORCPT ); Wed, 18 Oct 2023 07:31:04 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CC691112; Wed, 18 Oct 2023 04:31:02 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B421DC433BA; Wed, 18 Oct 2023 11:30:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1697628662; bh=2a3fF360HQENIx57U7Wbr+82JHRHzTNfIBguTuTew0E=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=hO7SQdvI1JxwSmUngjOaS4yakSuhGvtWB6tzEVexM7TNSgntP6UcvUTUerAeqBBW5 H3p7HpIbJWPb54PjGdwY2HcubMDAunf+3AoJ46P9bifevmiPMe0AKpvldc2zVrU0iG xqBxGUNf4OkyBCp8bPD0ZrvglNjU60SKPblgaqrY4rHw2g2vL2re0M3MFOs+56Y76/ OUTduFs351QSnEqOFENB/S0n4tIZDa4xo81KQN/pQWW3Dq8u3r4s2Fvb8+pEe+0lvq r10U7elHuk4IB5eP9mZJ40FKuFpXmzM3UiH/0lC+CVRqHp4ScXL4WXoZrrj/zSDcla aHE4S5t7K3nvg== Date: Wed, 18 Oct 2023 12:30:56 +0100 From: Conor Dooley To: Minda Chen Cc: Krzysztof =?utf-8?Q?Wilczy=C5=84ski?= , Rob Herring , Bjorn Helgaas , Lorenzo Pieralisi , Daire McNamara , Emil Renner Berthing , Krzysztof Kozlowski , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org, linux-pci@vger.kernel.org, Paul Walmsley , Palmer Dabbelt , Albert Ou , Philipp Zabel , Mason Huo , Leyfoon Tan , Kevin Xie Subject: Re: [PATCH v8 16/22] PCI: microchip: Add event IRQ domain ops to struct plda_event Message-ID: <20231018-worrier-sizably-b13023f54b36@spud> References: <20231011110514.107528-1-minda.chen@starfivetech.com> <20231011110514.107528-17-minda.chen@starfivetech.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="58kJN2dw4v2LbZBq" Content-Disposition: inline In-Reply-To: <20231011110514.107528-17-minda.chen@starfivetech.com> X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.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 (fry.vger.email [0.0.0.0]); Wed, 18 Oct 2023 04:31:26 -0700 (PDT) --58kJN2dw4v2LbZBq Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Oct 11, 2023 at 07:05:08PM +0800, Minda Chen wrote: > PolarFire Implements none-PLDA event interrupts. So the whole event > domain ops can not be re-used. IIRC, the reason things are like this is to work around the lack of an msi controller and are not as a result of changes made to the PLDA IP by us. > PLDA event domain ops instances will be implemented > in later patch. Acked-by: Conor Dooley Thanks, Conor. >=20 > Signed-off-by: Minda Chen > --- > drivers/pci/controller/plda/pcie-microchip-host.c | 9 ++++++--- > drivers/pci/controller/plda/pcie-plda.h | 1 + > 2 files changed, 7 insertions(+), 3 deletions(-) >=20 > diff --git a/drivers/pci/controller/plda/pcie-microchip-host.c b/drivers/= pci/controller/plda/pcie-microchip-host.c > index fca1520d56c9..2825c1f5563d 100644 > --- a/drivers/pci/controller/plda/pcie-microchip-host.c > +++ b/drivers/pci/controller/plda/pcie-microchip-host.c > @@ -811,13 +811,15 @@ static const struct plda_event_ops mc_event_ops =3D= { > }; > =20 > static const struct plda_event mc_event =3D { > + .domain_ops =3D &mc_event_domain_ops, > .event_ops =3D &mc_event_ops, > .request_event_irq =3D mc_request_event_irq, > .intx_event =3D EVENT_LOCAL_PM_MSI_INT_INTX, > .msi_event =3D EVENT_LOCAL_PM_MSI_INT_MSI, > }; > =20 > -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 =3D port->dev; > struct device_node *node =3D dev->of_node; > @@ -831,7 +833,8 @@ static int plda_pcie_init_irq_domains(struct plda_pci= e_rp *port) > } > =20 > port->event_domain =3D irq_domain_add_linear(pcie_intc_node, port->num_= events, > - &mc_event_domain_ops, port); > + ops, port); > + > if (!port->event_domain) { > dev_err(dev, "failed to get event domain\n"); > of_node_put(pcie_intc_node); > @@ -930,7 +933,7 @@ static int plda_init_interrupts(struct platform_devic= e *pdev, > return -EINVAL; > } > =20 > - ret =3D plda_pcie_init_irq_domains(port); > + ret =3D 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/contro= ller/plda/pcie-plda.h > index 6571a4befac9..080932cbe8c4 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 { > }; > =20 > 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); > --=20 > 2.17.1 >=20 --58kJN2dw4v2LbZBq Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHQEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCZS/B8AAKCRB4tDGHoIJi 0po5APiWGDsBhIIXOhjo24t9Ngvjf+qyTiHcD80kNJRtBXqJAP4gSLIomdwIbCJf Fp3FqROWnjnrkrANykQjljJiBa2nDw== =5HzY -----END PGP SIGNATURE----- --58kJN2dw4v2LbZBq--