Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp21288469rwd; Thu, 29 Jun 2023 13:51:56 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6tfI8+0AfkzSOrHTGf7aPxkhGcR6kGa2Tu64scJBv1cJ7qz4+sPajSTzAnQ9ZhNAQL/+p3 X-Received: by 2002:a05:6a20:1b1a:b0:12c:362b:88ed with SMTP id ch26-20020a056a201b1a00b0012c362b88edmr633096pzb.53.1688071916401; Thu, 29 Jun 2023 13:51:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688071916; cv=none; d=google.com; s=arc-20160816; b=Ch/JLHBR7Yuno4R9te80C6vLacTheV4jP8vTTPTwONaZ4YgPeuiItFm5pyMOpXHYTJ //CkP9MChZy3lJQD2Mhm9ISaVqcamoMJFJP5KSEWZb5qFYTcCztjF3c6NzIryr0jy9W6 kfaKtogmgmU6RGGWvUBDhYSNeOyD0UXUJE+NlPbFYJXvrXAnDDRVFkEhjOuv8AV3LK0J OXC/Voprx7eh2HIC0BMBvZXDsGn6SkhP1kmKoZogUc3Pa1/XVs7q/7Z6N1GuInnvR8eM 9RLqDbSgqlXkcJ4x9q9hZQd5FlFgenMnKOdO2BhyK+xA351sNjI4eVDXDmhmg5L2PznK rCHA== 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 :message-id:subject:cc:to:from:date:dkim-signature; bh=SFVboPEHNyKuemU5s1byn/9ZIl2bSbQSnxBeiTJ7pKg=; fh=gAVpXb5791XZbHRS8QlncTKAf4NIR76421wc846YQLo=; b=BpkInGUfs8Xn+OSgLanh7YU1hvgWOtWgLZhX6CIrSsbzjxKMF0mWaNHRxXMZvS6sCT tiuE41jhTTZG/MgFFcA51fRsT0bv8oCY6PsLaF/U93fDbWm8hckhgTzw0oO8xjUENEW1 HSWZkTW+TkI85jeQqzNT2bhZlJhu0Wq2OP98FhHPziqxVbOt8Pqk9VMdZ1zSPfJUKbpG k2hNkjpaDPWJqsbhyPvcKQCz2jW6FSpxGL00yAhuv9al1KxRZzvVp4sKPtLRQtB5QrUz MlNTz/NPrXxmBf6JU7lK7FaNrJw8fMY2zqtJHFrUultLfkcEirWF3E1/a46MFKsgLkC1 tpQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=iq8zmXdv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s10-20020a056a00194a00b0068094fd547esi3771170pfk.99.2023.06.29.13.51.43; Thu, 29 Jun 2023 13:51:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=iq8zmXdv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231269AbjF2UhK (ORCPT + 99 others); Thu, 29 Jun 2023 16:37:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42660 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229710AbjF2UhI (ORCPT ); Thu, 29 Jun 2023 16:37:08 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CA612E4B; Thu, 29 Jun 2023 13:37:07 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 5BE326162A; Thu, 29 Jun 2023 20:37:07 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 787B8C433C0; Thu, 29 Jun 2023 20:37:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1688071026; bh=F4iR1kf4VjUJOXwXJoDpEKi6qL+AsCelLmSSb+C9vzg=; h=Date:From:To:Cc:Subject:In-Reply-To:From; b=iq8zmXdv4336YTUGZ5+0I7NVnRp8iuqMub1tJEsNbDsYkpcu/gU0ve2qDl9VgL5Ab VkK7XPMKF1fD5upJfy6tbKgHcEM7u/5dNq6DvuB8j/PaI69VWA5+PHRGkgiljd0KK/ JwCG/WEY2dncXdIeufVUe08xXxoiYrA8viTm3ODt2c9f/wdVX3MxNsFkuuP4sTBySe RAT6L4zn7bhkpk8+Eu4igd4jCLy5Nv5K6rXwDPCa4/SNW1IJD55zw7ZP3VqZCw/ExV XQCXbIRuiRw7ndDNT5qjZcs7XWyhsKNGyAgrgQrwwkslVwtuyZWgsD0VVkSQI9s5me w5tWvNkuxH72A== Date: Thu, 29 Jun 2023 15:37:04 -0500 From: Bjorn Helgaas To: Lizhi Hou Cc: linux-pci@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, robh@kernel.org, max.zhen@amd.com, sonal.santan@amd.com, stefano.stabellini@xilinx.com Subject: Re: [PATCH V10 3/5] PCI: Add quirks to generate device tree node for Xilinx Alveo U50 Message-ID: <20230629203704.GA446887@bhelgaas> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1688059190-4225-4-git-send-email-lizhi.hou@amd.com> X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jun 29, 2023 at 10:19:48AM -0700, Lizhi Hou wrote: > The Xilinx Alveo U50 PCI card exposes multiple hardware peripherals on > its PCI BAR. The card firmware provides a flattened device tree to > describe the hardware peripherals on its BARs. This allows U50 driver to > load the flattened device tree and generate the device tree node for > hardware peripherals underneath. > > To generate device tree node for U50 card, add PCI quirks to call > of_pci_make_dev_node() for U50. > > Signed-off-by: Lizhi Hou Acked-by: Bjorn Helgaas I already gave my ack for v9, so ideally you would add that before posting the v10. But here it is again :) > --- > drivers/pci/quirks.c | 12 ++++++++++++ > 1 file changed, 12 insertions(+) > > diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c > index c525867760bf..7776012eb03f 100644 > --- a/drivers/pci/quirks.c > +++ b/drivers/pci/quirks.c > @@ -6041,3 +6041,15 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x9a2d, dpc_log_size); > DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x9a2f, dpc_log_size); > DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x9a31, dpc_log_size); > #endif > + > +/* > + * For a PCI device with multiple downstream devices, its driver may use > + * a flattened device tree to describe the downstream devices. > + * > + * To overlay the flattened device tree, the PCI device and all its ancestor > + * devices need to have device tree nodes on system base device tree. Thus, > + * before driver probing, it might need to add a device tree node as the final > + * fixup. > + */ > +DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_XILINX, 0x5020, of_pci_make_dev_node); > +DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_XILINX, 0x5021, of_pci_make_dev_node); > -- > 2.34.1 >