From patchwork Tue Nov 23 11:21:06 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Z.Q. Hou" X-Patchwork-Id: 1558501 X-Patchwork-Delegate: priyanka.jain@nxp.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=nxp.com header.i=@nxp.com header.a=rsa-sha256 header.s=selector2 header.b=BO9HZaOs; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4Hz1rd31v1z9sXN for ; Tue, 23 Nov 2021 22:19:59 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 4E82282A53; Tue, 23 Nov 2021 12:19:52 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=nxp.com header.i=@nxp.com header.b="BO9HZaOs"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 19A6882C88; Tue, 23 Nov 2021 12:19:51 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FORGED_SPF_HELO, MSGID_FROM_MTA_HEADER,SPF_HELO_PASS,T_SPF_PERMERROR autolearn=no autolearn_force=no version=3.4.2 Received: from EUR02-HE1-obe.outbound.protection.outlook.com (mail-he1eur02on0604.outbound.protection.outlook.com [IPv6:2a01:111:f400:fe05::604]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 2DA05800AA for ; Tue, 23 Nov 2021 12:19:48 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=zhiqiang.hou@nxp.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=EdR0FbWgU5vm0ZKqo4rodEimytd47F9VKYkIqhfG0ZPKwlnspfm6f3NAwn4phzbaygMg+DPpG6b8cGWBesz+KTDzoFLF41tLRny+w1xvQAqkb+CgbvJZpHULRE7+xO3Z1E3iQG9TJZVX0DeI6mDAQsqxBr3R46qPK58xjojfZp8hzdIVNJQEo7rrJyl6zSHgA/8/ozDOGDXqT+5hEJWfrEzdzsB1knqRBGg8cvRggQ1oJxIC+lmgWYky+rb9MKc53ciOkovaGcDzjgPNplF/FvSxnR3G+W3MeaMQ3qwNwQqVjFWDNftBCz9oCmlpX8LUX0woQPvldYCp5XHIkpuBJQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=WuoapevP6DGu4IEewgUaqEt9EWQ+etE54pkuSMrsysQ=; b=mZ7ieQm2sZQzTHrpUwRtRTufYViqPVmG7WoD5pA8BP1sdQflmg1fahm7i9CIKXZOB4qCg+9kFesFe/X9tIKL9IKVo682vCeSuBt1EYMS5x9ZdT3xZZkINgsTnqNKbgV312+G/16T6x+TOWAildkR6RiYB/tZiYB7WYQ7SIN9yFPs4NGu+c1AhHUu8NSPypQ1a3bzyiKLCz/dc44bqrFsmT+jPuIvL0AXU/g6YDzOSnN8S1n9uh4TPG6CGhnHBll4QB1serexvpmCqOC20/TMrI9zASgVCyOTSX+2IOZThIJTk51vZFmWdUq6sTHHfYsx9265sMO88UhbhhwnZ97quA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=WuoapevP6DGu4IEewgUaqEt9EWQ+etE54pkuSMrsysQ=; b=BO9HZaOs6eU6ZNcg4cz7nGxsNWGQdpwbsBzJtbGMphvd6RnXThhS/jJL8ho/VtJtNWdNKtXQUgHwVNCKSonXD/U0mhOVnGTXhKzRaKNk+atNssV6Pv1QGNQf8DY6HnuiENUZob7Upss2IIXEv6Afd9gUBmI4eq9ab16+X5XqoUI= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AM5PR04MB2963.eurprd04.prod.outlook.com (2603:10a6:206:9::23) by AM6PR04MB4726.eurprd04.prod.outlook.com (2603:10a6:20b:2::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4713.22; Tue, 23 Nov 2021 11:19:45 +0000 Received: from AM5PR04MB2963.eurprd04.prod.outlook.com ([fe80::4013:b5c3:1a41:a7cf]) by AM5PR04MB2963.eurprd04.prod.outlook.com ([fe80::4013:b5c3:1a41:a7cf%7]) with mapi id 15.20.4713.025; Tue, 23 Nov 2021 11:19:45 +0000 From: Zhiqiang Hou To: u-boot@lists.denx.de, priyanka.jain@nxp.com Cc: Hou Zhiqiang Subject: [PATCH] pci: layerscape: update the searching compatible of LX2160A PCIe Date: Tue, 23 Nov 2021 19:21:06 +0800 Message-Id: <20211123112106.2138194-1-Zhiqiang.Hou@nxp.com> X-Mailer: git-send-email 2.25.1 X-ClientProxiedBy: SG2PR02CA0092.apcprd02.prod.outlook.com (2603:1096:4:90::32) To AM5PR04MB2963.eurprd04.prod.outlook.com (2603:10a6:206:9::23) MIME-Version: 1.0 Received: from saturn.ap.freescale.net (119.31.174.73) by SG2PR02CA0092.apcprd02.prod.outlook.com (2603:1096:4:90::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4713.22 via Frontend Transport; Tue, 23 Nov 2021 11:19:44 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: d54fd8ec-a232-44a6-a336-08d9ae73274c X-MS-TrafficTypeDiagnostic: AM6PR04MB4726: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:6108; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: gCCpmCCwX/8BZpoSDJ7upJoIUXeu6V4YbFYNd73eMgsiC7nUZOm8qdf0EqO6zA5ywtpEfu5rRQs7/26awMPoCykXFnLinellSrSeQqY+BxIZ0BwSXny7aWZMG3xsSz78BVNc6VjgnQZj9qE+AuKXnJ4P7Qnz8hmUZmTWSLMHaIFkqjDXxg2XM0ePktqDNlpQSqYpZF8UsKQoo/6QR9xk6a8N97sC/YSjgvp/GsFoOl9FRhDcSPtgj+/+yyB20wkTs8yX87DGtZek47RrT+Qrw1qq3i7A9dK4Lf5eReCba4wWsMmygJ+JXNbwRNqF+EP+ndvIR+BqxG7GLiVPNcblEbzJ4lEHYm73XWuRhOQI/O7T93Ic2mogPQbYIl6NXhxE6AaSx2GODOle2cgr7wV8lmfvSkc7dX/cNBfhBSOfYnqmfysKD7BxcFYKGF8pdPpVAjagjlR/hY/MdcMLzN3sf4W//KU91ucG7EjchoFxmh5WVKI6mHOow5uPFmSpyHGpCpCEo2mO+CzkJRcxSp9OmWyS8TQGxueEyNc29YpVeWHaJMOaaLH+88zvEp2FnwftdMkmoAfNS8kH9MucDD6ypiN1S0TJk233NIHcTthEja9z0EjZqvluGB6CKTi6zKU/Ee2yj0v1AgGXuTSqsURjfn11ofE1fK/vVTFYHjMqjujCAuNo+AL6ndIs5+7ZvqLF11/OINnc59ydFgtEaY561w== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM5PR04MB2963.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(86362001)(316002)(1076003)(8676002)(4326008)(83380400001)(956004)(6666004)(66946007)(36756003)(15650500001)(66556008)(66476007)(2616005)(6486002)(2906002)(6506007)(38350700002)(38100700002)(5660300002)(508600001)(26005)(186003)(52116002)(6512007)(6636002)(8936002); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: tim+pRwke5QDVZpS8a5/YDsRaCQikF32tuarIQJg2DXi9QRHYYS3orPoOPB5JkZf5jqmtuVclBmeBRIhb0klSSvmdq7oxcUkObo62CWeLFjGxo0ZPrQwvgmo4/vf2haA1FnXKFTTBVu4PEDvZLTTQZJ+yAegcs6BzUyMXLA5YxL1rdY7NV0QePgeT0ksCHZ8ZDpydRngewzXjK5SktwQGhmlCAKSrKAyVzXK0dVO/byhesddbvslIFmVm0j9K5SLW4mRbeGhPEJxpc4ney/u9VOiwb+/7WucRCplVPm5U3O2RmRoR6qhrcIQgi4kraQ918IQ8S8ltwGs7aDIxjh1n1makM6ug3h9B4zmMA2srLW0Fj4FSRuV/ZWmsqICLD9IeL0FfqdpX6eEVVCYXA2bA/npYSA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wxbjt3RwkXp5AIzb6C5mve7ysLS2zyJra1fkWU+xbbtzYlmVp5ukYfV7Re+f0nzu7+UUbuz9K//Bv87cD8yKX3Fpsu+vtRTdx+2vOWWpUpvMr8mGja/3S8s/0DyL/tpDWX6qEf0NmVGtSMLU= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: d54fd8ec-a232-44a6-a336-08d9ae73274c X-MS-Exchange-CrossTenant-AuthSource: AM5PR04MB2963.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Nov 2021 11:19:45.6739 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: MjZ7k0ca6B1gLbgJFMoiB5IMYT7qyLQpvL2ZEQNxY17eON6zyOIWTqBTrME8I9CjZNck4Kmbc6BC+ix++LMQTg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR04MB4726 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.37 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean From: Hou Zhiqiang The current fixup of LX2160A PCIe nodes is based on non-production rev1 silicon, and in Linux the nodes have been updated for rev2 silicon, so update the searching compatible string to match the kernel changes. And for compatibility with the rev1 nodes, move forward the board specific fixup. Signed-off-by: Hou Zhiqiang --- drivers/pci/Kconfig | 4 +--- drivers/pci/pcie_layerscape_fixup.c | 7 +++---- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/drivers/pci/Kconfig b/drivers/pci/Kconfig index ba41787f64..16647bed54 100644 --- a/drivers/pci/Kconfig +++ b/drivers/pci/Kconfig @@ -219,8 +219,7 @@ config FSL_PCIE_COMPAT default "fsl,ls1046a-pcie" if ARCH_LS1046A default "fsl,ls2080a-pcie" if ARCH_LS2080A default "fsl,ls1088a-pcie" if ARCH_LS1088A - default "fsl,lx2160a-pcie" if ARCH_LX2160A - default "fsl,ls2088a-pcie" if ARCH_LX2162A + default "fsl,ls2088a-pcie" if ARCH_LX2160A || ARCH_LX2162A default "fsl,ls1021a-pcie" if ARCH_LS1021A help This compatible is used to find pci controller node in Kernel DT @@ -229,7 +228,6 @@ config FSL_PCIE_COMPAT config FSL_PCIE_EP_COMPAT string "PCIe EP compatible of Kernel DT" depends on PCIE_LAYERSCAPE_RC || PCIE_LAYERSCAPE_GEN4 - default "fsl,lx2160a-pcie-ep" if ARCH_LX2160A default "fsl,ls-pcie-ep" help This compatible is used to find pci controller ep node in Kernel DT diff --git a/drivers/pci/pcie_layerscape_fixup.c b/drivers/pci/pcie_layerscape_fixup.c index 48aeb50e68..6fdb0ac1d6 100644 --- a/drivers/pci/pcie_layerscape_fixup.c +++ b/drivers/pci/pcie_layerscape_fixup.c @@ -527,7 +527,7 @@ static void fdt_fixup_pcie_ls(void *blob) } if (!IS_ENABLED(CONFIG_PCI_IOMMU_EXTRA_MAPPINGS)) - goto skip; + return; list_for_each_entry(pcie_rc, &ls_pcie_list, list) { nodeoffset = fdt_pcie_get_nodeoffset(blob, pcie_rc); @@ -568,9 +568,6 @@ static void fdt_fixup_pcie_ls(void *blob) } free(entries); } - -skip: - pcie_board_fix_fdt(blob); } #endif @@ -619,6 +616,8 @@ void ft_pci_setup_ls(void *blob, struct bd_info *bd) { struct ls_pcie_rc *pcie_rc; + pcie_board_fix_fdt(blob); + list_for_each_entry(pcie_rc, &ls_pcie_list, list) ft_pcie_ls_setup(blob, pcie_rc);