From patchwork Sat Dec 24 21:14:18 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Pali_Roh=C3=A1r?= X-Patchwork-Id: 36443 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp297304wrt; Sat, 24 Dec 2022 13:17:18 -0800 (PST) X-Google-Smtp-Source: AMrXdXsbtXrLDQZWvH5H51TLypAmytM5dWNsS8P/bVwDMp4F1qf2AoqE34PpU7p2ZtVlVU8vwAfM X-Received: by 2002:a17:906:a1c5:b0:7c1:2529:b25e with SMTP id bx5-20020a170906a1c500b007c12529b25emr11728789ejb.43.1671916638382; Sat, 24 Dec 2022 13:17:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671916638; cv=none; d=google.com; s=arc-20160816; b=D3ot4RhLRpQ3Mgb91fr4Nt9ofQ1b+WDLnP4xf4U9uvCOwBf7/AeAm+d8b5VY6b9RC9 hVNP8nqQOzIRoDv0Q3mAYTYCwFgndS40/qdpfjaPAGdN6gY9xkRI/yT2RernTeImLYc4 Pq1EyK2Mu780cFu+l51CqpKJVkwcOBh41d4gPAvNoLRILsnmK+128W5tdUXQuWkEwlfs KUc23195P8EIG52a637oAZLhuv1ZlC6R6bnECBbLVc67xZlgBEIlhNaEYfZRX6z9KISC uiqOqpReF1LtEwGXS2FtVodIf5WSKIhb7NAZ7kOGqXqoRsy2tv5JDY0v/DdHVtjVgRpv Ux6g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=ZE052bWYs4rHapiAYD8qvxEM3PQw6N28yOlBmie8Kfg=; b=iz3JoTzCY7FRsl9VnJ57nAHmKy2JQILStiZvb+M+kHivnNZv8w+aaxZrDiW/YvFhUq wWVE+llFXYN1W9wARaPM0FgXDuwel5Vf6ZiUAZjb2XwZUG37dqlKFyh/u7gcEC51QIvS wM40JjBVdnBAGZ/A4kvnida6CqhUItM/KsTnkFAxM76czv+EezJwnVHfiVpz1MNgLmIU tWv+io2sJoqbxCYfMY9+jT6LiqedOvTrJscLSlqyhsrP1wl+yKfsZlB6ZL21W+fnv81a DhAU8VfBIJQEhwxOQhziaBfKfjbj2kxN6R30YngeVCiz9uoYnPafdfqWOZTQArQCyq5w VjIg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=oc6cSSGg; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id qw1-20020a1709066a0100b007dbea9fb8dasi5406088ejc.641.2022.12.24.13.16.53; Sat, 24 Dec 2022 13:17:18 -0800 (PST) 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=oc6cSSGg; 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 S230147AbiLXVQh (ORCPT + 99 others); Sat, 24 Dec 2022 16:16:37 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50314 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229445AbiLXVQg (ORCPT ); Sat, 24 Dec 2022 16:16:36 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 74319A445 for ; Sat, 24 Dec 2022 13:16:35 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 0A5C060B0C for ; Sat, 24 Dec 2022 21:16:35 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 429B5C433EF; Sat, 24 Dec 2022 21:16:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671916594; bh=UD5jorQCVmKiXH0v3VkIP3iO7pPTI+aaxJhMgfUmopA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=oc6cSSGgtRTQmJ86c8kAsul6M3Ygniaj0MO56wwfXbVITrjxApARWDw2K7umElNgo ATWv7q/bPgLcHXJLE6hNFIKdZaz1cI60NU6/8CFqqwYsOi3ruyJbSvPtRJPBlnMAdM Gw6jPpnWCgVVnXOm3NvCMpAN49KWZOYzZ9NOBHtUEwk2+jzSKWa6skt+5UsJeK6BLx n3+XPsXrDqdlui1E7FzFvDXr3IBGH50+dkFqV092+FLhQKL7I2pB5fSC9vcQtgyUW2 1XHn5s5PgkSFWjF1na6LGTvnGeDlEx/FkP+UlgcQDBwBeVDWkBIgIUzq//sbcOsoSy qIwle/yYr65VA== Received: by pali.im (Postfix) id C5B48720; Sat, 24 Dec 2022 22:16:31 +0100 (CET) From: =?utf-8?q?Pali_Roh=C3=A1r?= To: Michael Ellerman , Nicholas Piggin , Christophe Leroy , Scott Wood , Sinan Akman , Martin Kennedy Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 1/8] powerpc/85xx: Mark mpc85xx_rdb_pic_init() as static Date: Sat, 24 Dec 2022 22:14:18 +0100 Message-Id: <20221224211425.14983-2-pali@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20221224211425.14983-1-pali@kernel.org> References: <20221224211425.14983-1-pali@kernel.org> MIME-Version: 1.0 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 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1753131660938177305?= X-GMAIL-MSGID: =?utf-8?q?1753131660938177305?= Function mpc85xx_rdb_pic_init() is not used out of the mpc85xx_rdb.c file. Signed-off-by: Pali Rohár --- arch/powerpc/platforms/85xx/mpc85xx_rdb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/platforms/85xx/mpc85xx_rdb.c b/arch/powerpc/platforms/85xx/mpc85xx_rdb.c index d99aba158235..b6129c148fea 100644 --- a/arch/powerpc/platforms/85xx/mpc85xx_rdb.c +++ b/arch/powerpc/platforms/85xx/mpc85xx_rdb.c @@ -38,7 +38,7 @@ #endif -void __init mpc85xx_rdb_pic_init(void) +static void __init mpc85xx_rdb_pic_init(void) { struct mpic *mpic; From patchwork Sat Dec 24 21:14:19 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Pali_Roh=C3=A1r?= X-Patchwork-Id: 36444 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp297377wrt; Sat, 24 Dec 2022 13:17:36 -0800 (PST) X-Google-Smtp-Source: AMrXdXs3RpwTMDWAY8XCYCOAqy41jgBPXNkvbeD7mfw5mcb+jhPPK6L6n/VywcaSjkk3hggrc96t X-Received: by 2002:a17:906:bcd5:b0:7c0:a49a:1 with SMTP id lw21-20020a170906bcd500b007c0a49a0001mr11743343ejb.71.1671916656699; Sat, 24 Dec 2022 13:17:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671916656; cv=none; d=google.com; s=arc-20160816; b=ohFJAlqi9IXqvwXUo479SMRHtFPhFjf2VhM1HQUCqiYfoNFiVFin+7Y7bCDEPPPF9A B5wqWgR615feD6M+BUDLI2+cJxUT4IJziKHdTBk6U/GFFUQmGMzDLIF0O3UMtUnlYzmr 5Ao7jpXOT+QoEFcydEQUsHOmR5C0psZv/2lUSFIx7Pl8MdyWr4mL9j3vohVn8O1WnyIW SiLIdR3tb8uU1zDAVx/IiVlYuT/k6qngyTsi1araPgUjq/CiVTmIXzgDhj3nkGbU+g0s Z6gEDMvYXRrWV3SCoky+V213Kno/XFGsI2CJbroQ6IboSSdKfL3KbhCw//gSLgjnNqW6 rnaA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=uQXb997hmVvejM49RHLdHK1IB7pbANFVf1FMUVyNDDU=; b=nWHl2LK96oMLnUrOnDSqraHRPFGGCPrWqLmXivVKKa5AhlqfqluTXKrQ6ZAbMunDxc iIxqQL7RoC8EC6S4Vv6PGJCR3B0ZRFp2jeF3zEaX6Y3a41zbkTP2142O758BTl3vRz0S R6K+qtXkBgHX6OrZ8Y4uAlM9/lJH8wBLjYVbmhOppVH8K3uGKx9PW2F22CMIFhaSQTl0 lfA4QGmQ5ZPzo+kq03HSDSpKWV/z7i6Aw9qrUsxnkZrc7vUZVsrgMGQEMFWkfPODWPw4 FdEtnMPkoNDiLa2/KQGCB7+nG9/wNSGp6MmO5LfwyGaz9BEPFCdB/qvxfRq8/ZitqXkJ PIiQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=cR6u70y9; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id go11-20020a1709070d8b00b0081a9c3ca4bcsi6036196ejc.379.2022.12.24.13.17.12; Sat, 24 Dec 2022 13:17:36 -0800 (PST) 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=cR6u70y9; 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 S230216AbiLXVQl (ORCPT + 99 others); Sat, 24 Dec 2022 16:16:41 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50330 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229445AbiLXVQj (ORCPT ); Sat, 24 Dec 2022 16:16:39 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5D7D8A446 for ; Sat, 24 Dec 2022 13:16:38 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id E7998B80139 for ; Sat, 24 Dec 2022 21:16:36 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4A20EC433D2; Sat, 24 Dec 2022 21:16:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671916595; bh=RoXrwfU/s5vurCwlxvo8Vd+Lw1JXCW4diLyk4VZ6JDI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=cR6u70y95h2R+t1gaD2QDSB2DCABAVBiIAvdmhHnHOXLA5fddVSelnAd4kZykVEg8 h7TMpEtoktLZzwbmGMs2zY1albKs0iPtHZXmVSodhety7X0wFKGs6rYvEPrdiDJhdD lKR4zeg1DGvqF4Z0lW6o03pBsmCOh3Y4BUcD5egPGfpQVUAD68yM7bdTzKdmX1L0an lIs8V7x41KBM0lxjpe3+P/Mq+OUW0+5Zx47HsQyFC7H+oHt7oI0vCft9qyAWfTXldL WklfcVxPRxfcVsHjtyppKlGSOt+khxqXLSkU6fqQJw15cSrXVGZv/ncesqqkj4od/B juRWKj41jIDRQ== Received: by pali.im (Postfix) id D4C5E9D7; Sat, 24 Dec 2022 22:16:32 +0100 (CET) From: =?utf-8?q?Pali_Roh=C3=A1r?= To: Michael Ellerman , Nicholas Piggin , Christophe Leroy , Scott Wood , Sinan Akman , Martin Kennedy Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 2/8] powerpc/85xx: Mark mpc85xx_ds_pic_init() as static Date: Sat, 24 Dec 2022 22:14:19 +0100 Message-Id: <20221224211425.14983-3-pali@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20221224211425.14983-1-pali@kernel.org> References: <20221224211425.14983-1-pali@kernel.org> MIME-Version: 1.0 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 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1753131680438856642?= X-GMAIL-MSGID: =?utf-8?q?1753131680438856642?= Function mpc85xx_ds_pic_init() is not used out of the mpc85xx_ds.c file. Signed-off-by: Pali Rohár --- arch/powerpc/platforms/85xx/mpc85xx_ds.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/platforms/85xx/mpc85xx_ds.c b/arch/powerpc/platforms/85xx/mpc85xx_ds.c index f8d2c97f39bd..9a6d637ef54a 100644 --- a/arch/powerpc/platforms/85xx/mpc85xx_ds.c +++ b/arch/powerpc/platforms/85xx/mpc85xx_ds.c @@ -54,7 +54,7 @@ static void mpc85xx_8259_cascade(struct irq_desc *desc) } #endif /* CONFIG_PPC_I8259 */ -void __init mpc85xx_ds_pic_init(void) +static void __init mpc85xx_ds_pic_init(void) { struct mpic *mpic; #ifdef CONFIG_PPC_I8259 From patchwork Sat Dec 24 21:14:20 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Pali_Roh=C3=A1r?= X-Patchwork-Id: 36446 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp297562wrt; Sat, 24 Dec 2022 13:18:24 -0800 (PST) X-Google-Smtp-Source: AMrXdXs7ZQnLGBrEFZPXJ/Cw8eilD4c1LnWp1iUnLw8inYDFJ4KEoHjavZa0VsH0//5MpXolROaQ X-Received: by 2002:a17:907:a0d0:b0:7c1:637:585d with SMTP id hw16-20020a170907a0d000b007c10637585dmr12001113ejc.0.1671916704192; Sat, 24 Dec 2022 13:18:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671916704; cv=none; d=google.com; s=arc-20160816; b=H0Mc4WG0mtmUCivoOIikMzWhRanoj3w+2O4AjQFXYrLSpaZVjWg22Bu0l6weVuD46T sR/v0EWv+jE9++xJssbd83EqjtKGq+La+vWIVLV8+qUpOIRp6dfwq52gkzEals9E8AIZ wMzDbxhEZQaMSP4bUgiotKdaW8Wb3lNYSkRhEIwx+BQpW6cj5PQ/3CWwtt2tUXSTtvyI X/tBSJlP2eehtBMYvISZ7jLe3NHFJAxcxcKsiu6Q9gmPrLZSonNZokHltXBIbUho+HwZ XJ+DpwJZ67+oUcRn9ntwHRiCzNtCKr/BoA31+MXfNCCbryD1QMeOXwHRmSCI4PRTvEZv lu4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=aC3w99kuyQlH1i0OpKpABJYFHYM9Cmdj1k+G0YtODNc=; b=QNozY/sHWpdV/aCRY8FziMGGCs/0dWPyW4ptSODN4e8mrWzjasPQBgHN1bee3VR3ji WRLUjajlDlVjf3Z9g6qj4FrSsDKA9SePBvH8ZEqiFmKfg6uuyOmDQ3aGE83FdgVCmYMZ R0jWHeIHLwwd0hMHNPQo2HUS4l24fl2t8bACvSUTeahdNs2hujm/fHiW5Nj8tt+5GWZz TYbaQwXSFFp+aMrSfC3SCW0SsEAP2f+eWd0q+XovT/K1Kn+TbjN6So0yuJAcEfu8mAkm Cg2sV7pFf4D3gip5ixjB/JQ4gVcWtqiB6kJYs4rWg2Jw49dX9D4Gb5PhSZ/v02eVMimX aLpw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=J+JXBqKJ; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ga28-20020a1709070c1c00b007a92b00c094si5640745ejc.421.2022.12.24.13.18.00; Sat, 24 Dec 2022 13:18:24 -0800 (PST) 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=J+JXBqKJ; 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 S230283AbiLXVQr (ORCPT + 99 others); Sat, 24 Dec 2022 16:16:47 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50328 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230186AbiLXVQj (ORCPT ); Sat, 24 Dec 2022 16:16:39 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9F5DCA445 for ; Sat, 24 Dec 2022 13:16:37 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 3B9C960B0C for ; Sat, 24 Dec 2022 21:16:37 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4B931C433F1; Sat, 24 Dec 2022 21:16:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671916596; bh=UU48dkbPMWSfqv33kA8+TfkcfoCpjLsskO/H+O/CHJg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=J+JXBqKJ/DgB9Gjt43K/ArKCpmBGKk/BpjpNZNExk7VWSMTxM2RtkMX46XrQqpOFd mjP+FkvbgSxSUflrxpBL+MN3Hk0STZbF1ykBaS4JJWiTTwYhT37Neeo6QKafvjAi9V RBRW6Q6CWOusTVJ9y/i3Fq6pM64CCzNpmGyzQESiJPU9MsS5N4XZIfudIQoMFnojhX DK0T2Rs5KB1Jpii27beRc4U3AtLuAEb8IF8CNBxuxTrKgoR//M8m+E79Vc4J//7hRP 90gFTVNrPWHUtrOKXi4Gdyg/m5i58sQxH//IJ70ZrLvMtH3Z9LJKVQRT7AVml1VyNe fxS0qdIqpzX0w== Received: by pali.im (Postfix) id 01E679E4; Sat, 24 Dec 2022 22:16:33 +0100 (CET) From: =?utf-8?q?Pali_Roh=C3=A1r?= To: Michael Ellerman , Nicholas Piggin , Christophe Leroy , Scott Wood , Sinan Akman , Martin Kennedy Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 3/8] powerpc/85xx: p2020: Move all P2020 machine descriptions to p2020.c Date: Sat, 24 Dec 2022 22:14:20 +0100 Message-Id: <20221224211425.14983-4-pali@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20221224211425.14983-1-pali@kernel.org> References: <20221224211425.14983-1-pali@kernel.org> MIME-Version: 1.0 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 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1753131730077388015?= X-GMAIL-MSGID: =?utf-8?q?1753131730077388015?= This moves machine descriptions and all related code for all P2020 boards into new p2020.c source file. This change also copies helper static functions from other mpc85xx*.c files into p2020.c, which are required for machine descriptions. This is preparation for code de-duplication and providing one unified machine description for all P2020 boards. In follow-up patches would be copied functions refactored and simplified to be specific just for P2020 boards. Signed-off-by: Pali Rohár --- arch/powerpc/platforms/85xx/Makefile | 2 + arch/powerpc/platforms/85xx/mpc85xx_ds.c | 23 -- arch/powerpc/platforms/85xx/mpc85xx_rdb.c | 44 ---- arch/powerpc/platforms/85xx/p2020.c | 273 ++++++++++++++++++++++ 4 files changed, 275 insertions(+), 67 deletions(-) create mode 100644 arch/powerpc/platforms/85xx/p2020.c diff --git a/arch/powerpc/platforms/85xx/Makefile b/arch/powerpc/platforms/85xx/Makefile index 260fbad7967b..1ad261b4eeb6 100644 --- a/arch/powerpc/platforms/85xx/Makefile +++ b/arch/powerpc/platforms/85xx/Makefile @@ -23,6 +23,8 @@ obj-$(CONFIG_P1010_RDB) += p1010rdb.o obj-$(CONFIG_P1022_DS) += p1022_ds.o obj-$(CONFIG_P1022_RDK) += p1022_rdk.o obj-$(CONFIG_P1023_RDB) += p1023_rdb.o +obj-$(CONFIG_MPC85xx_DS) += p2020.o +obj-$(CONFIG_MPC85xx_RDB) += p2020.o obj-$(CONFIG_TWR_P102x) += twr_p102x.o obj-$(CONFIG_CORENET_GENERIC) += corenet_generic.o obj-$(CONFIG_FB_FSL_DIU) += t1042rdb_diu.o diff --git a/arch/powerpc/platforms/85xx/mpc85xx_ds.c b/arch/powerpc/platforms/85xx/mpc85xx_ds.c index 9a6d637ef54a..05aac997b5ed 100644 --- a/arch/powerpc/platforms/85xx/mpc85xx_ds.c +++ b/arch/powerpc/platforms/85xx/mpc85xx_ds.c @@ -168,7 +168,6 @@ static int __init mpc8544_ds_probe(void) machine_arch_initcall(mpc8544_ds, mpc85xx_common_publish_devices); machine_arch_initcall(mpc8572_ds, mpc85xx_common_publish_devices); -machine_arch_initcall(p2020_ds, mpc85xx_common_publish_devices); /* * Called very early, device-tree isn't unflattened @@ -178,14 +177,6 @@ static int __init mpc8572_ds_probe(void) return !!of_machine_is_compatible("fsl,MPC8572DS"); } -/* - * Called very early, device-tree isn't unflattened - */ -static int __init p2020_ds_probe(void) -{ - return !!of_machine_is_compatible("fsl,P2020DS"); -} - define_machine(mpc8544_ds) { .name = "MPC8544 DS", .probe = mpc8544_ds_probe, @@ -213,17 +204,3 @@ define_machine(mpc8572_ds) { .calibrate_decr = generic_calibrate_decr, .progress = udbg_progress, }; - -define_machine(p2020_ds) { - .name = "P2020 DS", - .probe = p2020_ds_probe, - .setup_arch = mpc85xx_ds_setup_arch, - .init_IRQ = mpc85xx_ds_pic_init, -#ifdef CONFIG_PCI - .pcibios_fixup_bus = fsl_pcibios_fixup_bus, - .pcibios_fixup_phb = fsl_pcibios_fixup_phb, -#endif - .get_irq = mpic_get_irq, - .calibrate_decr = generic_calibrate_decr, - .progress = udbg_progress, -}; diff --git a/arch/powerpc/platforms/85xx/mpc85xx_rdb.c b/arch/powerpc/platforms/85xx/mpc85xx_rdb.c index b6129c148fea..05f1ed635735 100644 --- a/arch/powerpc/platforms/85xx/mpc85xx_rdb.c +++ b/arch/powerpc/platforms/85xx/mpc85xx_rdb.c @@ -108,8 +108,6 @@ static void __init mpc85xx_rdb_setup_arch(void) printk(KERN_INFO "MPC85xx RDB board from Freescale Semiconductor\n"); } -machine_arch_initcall(p2020_rdb, mpc85xx_common_publish_devices); -machine_arch_initcall(p2020_rdb_pc, mpc85xx_common_publish_devices); machine_arch_initcall(p1020_mbg_pc, mpc85xx_common_publish_devices); machine_arch_initcall(p1020_rdb, mpc85xx_common_publish_devices); machine_arch_initcall(p1020_rdb_pc, mpc85xx_common_publish_devices); @@ -122,13 +120,6 @@ machine_arch_initcall(p1024_rdb, mpc85xx_common_publish_devices); /* * Called very early, device-tree isn't unflattened */ -static int __init p2020_rdb_probe(void) -{ - if (of_machine_is_compatible("fsl,P2020RDB")) - return 1; - return 0; -} - static int __init p1020_rdb_probe(void) { if (of_machine_is_compatible("fsl,P1020RDB")) @@ -153,13 +144,6 @@ static int __init p1021_rdb_pc_probe(void) return 0; } -static int __init p2020_rdb_pc_probe(void) -{ - if (of_machine_is_compatible("fsl,P2020RDB-PC")) - return 1; - return 0; -} - static int __init p1025_rdb_probe(void) { return of_machine_is_compatible("fsl,P1025RDB"); @@ -180,20 +164,6 @@ static int __init p1024_rdb_probe(void) return of_machine_is_compatible("fsl,P1024RDB"); } -define_machine(p2020_rdb) { - .name = "P2020 RDB", - .probe = p2020_rdb_probe, - .setup_arch = mpc85xx_rdb_setup_arch, - .init_IRQ = mpc85xx_rdb_pic_init, -#ifdef CONFIG_PCI - .pcibios_fixup_bus = fsl_pcibios_fixup_bus, - .pcibios_fixup_phb = fsl_pcibios_fixup_phb, -#endif - .get_irq = mpic_get_irq, - .calibrate_decr = generic_calibrate_decr, - .progress = udbg_progress, -}; - define_machine(p1020_rdb) { .name = "P1020 RDB", .probe = p1020_rdb_probe, @@ -222,20 +192,6 @@ define_machine(p1021_rdb_pc) { .progress = udbg_progress, }; -define_machine(p2020_rdb_pc) { - .name = "P2020RDB-PC", - .probe = p2020_rdb_pc_probe, - .setup_arch = mpc85xx_rdb_setup_arch, - .init_IRQ = mpc85xx_rdb_pic_init, -#ifdef CONFIG_PCI - .pcibios_fixup_bus = fsl_pcibios_fixup_bus, - .pcibios_fixup_phb = fsl_pcibios_fixup_phb, -#endif - .get_irq = mpic_get_irq, - .calibrate_decr = generic_calibrate_decr, - .progress = udbg_progress, -}; - define_machine(p1025_rdb) { .name = "P1025 RDB", .probe = p1025_rdb_probe, diff --git a/arch/powerpc/platforms/85xx/p2020.c b/arch/powerpc/platforms/85xx/p2020.c new file mode 100644 index 000000000000..d65d4c88ac47 --- /dev/null +++ b/arch/powerpc/platforms/85xx/p2020.c @@ -0,0 +1,273 @@ +// SPDX-License-Identifier: GPL-2.0-or-later +/* + * Freescale P2020 board Setup + * + * Copyright 2007,2009,2012-2013 Freescale Semiconductor Inc. + * Copyright 2022 Pali Rohár + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +#include +#include +#include "smp.h" + +#include "mpc85xx.h" + +#undef DEBUG + +#ifdef DEBUG +#define DBG(fmt, args...) printk(KERN_ERR "%s: " fmt, __func__, ## args) +#else +#define DBG(fmt, args...) +#endif + +#ifdef CONFIG_MPC85xx_DS + +#ifdef CONFIG_PPC_I8259 +static void mpc85xx_8259_cascade(struct irq_desc *desc) +{ + struct irq_chip *chip = irq_desc_get_chip(desc); + unsigned int cascade_irq = i8259_irq(); + + if (cascade_irq) { + generic_handle_irq(cascade_irq); + } + chip->irq_eoi(&desc->irq_data); +} +#endif /* CONFIG_PPC_I8259 */ + +static void __init mpc85xx_ds_pic_init(void) +{ + struct mpic *mpic; +#ifdef CONFIG_PPC_I8259 + struct device_node *np; + struct device_node *cascade_node = NULL; + int cascade_irq; +#endif + + mpic = mpic_alloc(NULL, 0, + MPIC_BIG_ENDIAN | + MPIC_SINGLE_DEST_CPU, + 0, 256, " OpenPIC "); + + BUG_ON(mpic == NULL); + mpic_init(mpic); + +#ifdef CONFIG_PPC_I8259 + /* Initialize the i8259 controller */ + for_each_node_by_type(np, "interrupt-controller") + if (of_device_is_compatible(np, "chrp,iic")) { + cascade_node = np; + break; + } + + if (cascade_node == NULL) { + printk(KERN_DEBUG "Could not find i8259 PIC\n"); + return; + } + + cascade_irq = irq_of_parse_and_map(cascade_node, 0); + if (!cascade_irq) { + printk(KERN_ERR "Failed to map cascade interrupt\n"); + return; + } + + DBG("mpc85xxds: cascade mapped to irq %d\n", cascade_irq); + + i8259_init(cascade_node, 0); + of_node_put(cascade_node); + + irq_set_chained_handler(cascade_irq, mpc85xx_8259_cascade); +#endif /* CONFIG_PPC_I8259 */ +} + +#ifdef CONFIG_PCI +extern int uli_exclude_device(struct pci_controller *hose, + u_char bus, u_char devfn); + +static struct device_node *pci_with_uli; + +static int mpc85xx_exclude_device(struct pci_controller *hose, + u_char bus, u_char devfn) +{ + if (hose->dn == pci_with_uli) + return uli_exclude_device(hose, bus, devfn); + + return PCIBIOS_SUCCESSFUL; +} +#endif /* CONFIG_PCI */ + +static void __init mpc85xx_ds_uli_init(void) +{ +#ifdef CONFIG_PCI + struct device_node *node; + + /* See if we have a ULI under the primary */ + + node = of_find_node_by_name(NULL, "uli1575"); + while ((pci_with_uli = of_get_parent(node))) { + of_node_put(node); + node = pci_with_uli; + + if (pci_with_uli == fsl_pci_primary) { + ppc_md.pci_exclude_device = mpc85xx_exclude_device; + break; + } + } +#endif +} + +#endif /* CONFIG_MPC85xx_DS */ + +#ifdef CONFIG_MPC85xx_RDB +static void __init mpc85xx_rdb_pic_init(void) +{ + struct mpic *mpic; + + mpic = mpic_alloc(NULL, 0, + MPIC_BIG_ENDIAN | + MPIC_SINGLE_DEST_CPU, + 0, 256, " OpenPIC "); + + BUG_ON(mpic == NULL); + mpic_init(mpic); +} +#endif /* CONFIG_MPC85xx_RDB */ + +/* + * Setup the architecture + */ +#ifdef CONFIG_MPC85xx_DS +static void __init mpc85xx_ds_setup_arch(void) +{ + if (ppc_md.progress) + ppc_md.progress("mpc85xx_ds_setup_arch()", 0); + + swiotlb_detect_4g(); + fsl_pci_assign_primary(); + mpc85xx_ds_uli_init(); + mpc85xx_smp_init(); + + printk("MPC85xx DS board from Freescale Semiconductor\n"); +} +#endif /* CONFIG_MPC85xx_DS */ + +#ifdef CONFIG_MPC85xx_RDB +static void __init mpc85xx_rdb_setup_arch(void) +{ + if (ppc_md.progress) + ppc_md.progress("mpc85xx_rdb_setup_arch()", 0); + + mpc85xx_smp_init(); + + fsl_pci_assign_primary(); + +#ifdef CONFIG_QUICC_ENGINE + mpc85xx_qe_par_io_init(); +#endif /* CONFIG_QUICC_ENGINE */ + + printk(KERN_INFO "MPC85xx RDB board from Freescale Semiconductor\n"); +} +#endif /* CONFIG_MPC85xx_RDB */ + +#ifdef CONFIG_MPC85xx_DS +machine_arch_initcall(p2020_ds, mpc85xx_common_publish_devices); +#endif /* CONFIG_MPC85xx_DS */ + +#ifdef CONFIG_MPC85xx_RDB +machine_arch_initcall(p2020_rdb, mpc85xx_common_publish_devices); +machine_arch_initcall(p2020_rdb_pc, mpc85xx_common_publish_devices); +#endif /* CONFIG_MPC85xx_RDB */ + +/* + * Called very early, device-tree isn't unflattened + */ +#ifdef CONFIG_MPC85xx_DS +static int __init p2020_ds_probe(void) +{ + return !!of_machine_is_compatible("fsl,P2020DS"); +} +#endif /* CONFIG_MPC85xx_DS */ + +#ifdef CONFIG_MPC85xx_RDB +static int __init p2020_rdb_probe(void) +{ + if (of_machine_is_compatible("fsl,P2020RDB")) + return 1; + return 0; +} + +static int __init p2020_rdb_pc_probe(void) +{ + if (of_machine_is_compatible("fsl,P2020RDB-PC")) + return 1; + return 0; +} +#endif /* CONFIG_MPC85xx_RDB */ + +#ifdef CONFIG_MPC85xx_DS +define_machine(p2020_ds) { + .name = "P2020 DS", + .probe = p2020_ds_probe, + .setup_arch = mpc85xx_ds_setup_arch, + .init_IRQ = mpc85xx_ds_pic_init, +#ifdef CONFIG_PCI + .pcibios_fixup_bus = fsl_pcibios_fixup_bus, + .pcibios_fixup_phb = fsl_pcibios_fixup_phb, +#endif + .get_irq = mpic_get_irq, + .calibrate_decr = generic_calibrate_decr, + .progress = udbg_progress, +}; +#endif /* CONFIG_MPC85xx_DS */ + +#ifdef CONFIG_MPC85xx_RDB +define_machine(p2020_rdb) { + .name = "P2020 RDB", + .probe = p2020_rdb_probe, + .setup_arch = mpc85xx_rdb_setup_arch, + .init_IRQ = mpc85xx_rdb_pic_init, +#ifdef CONFIG_PCI + .pcibios_fixup_bus = fsl_pcibios_fixup_bus, + .pcibios_fixup_phb = fsl_pcibios_fixup_phb, +#endif + .get_irq = mpic_get_irq, + .calibrate_decr = generic_calibrate_decr, + .progress = udbg_progress, +}; + +define_machine(p2020_rdb_pc) { + .name = "P2020RDB-PC", + .probe = p2020_rdb_pc_probe, + .setup_arch = mpc85xx_rdb_setup_arch, + .init_IRQ = mpc85xx_rdb_pic_init, +#ifdef CONFIG_PCI + .pcibios_fixup_bus = fsl_pcibios_fixup_bus, + .pcibios_fixup_phb = fsl_pcibios_fixup_phb, +#endif + .get_irq = mpic_get_irq, + .calibrate_decr = generic_calibrate_decr, + .progress = udbg_progress, +}; +#endif /* CONFIG_MPC85xx_RDB */ From patchwork Sat Dec 24 21:14:21 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Pali_Roh=C3=A1r?= X-Patchwork-Id: 36445 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp297541wrt; Sat, 24 Dec 2022 13:18:19 -0800 (PST) X-Google-Smtp-Source: AMrXdXs2UXAJp4ZMN38YuB6MCCSKWlb1NKMcOrOMCPwAuLyavyYPLaqwGzj0N0bgnSvHbN0L8Bmm X-Received: by 2002:a05:6402:33a:b0:469:ae36:b954 with SMTP id q26-20020a056402033a00b00469ae36b954mr14730656edw.30.1671916699311; Sat, 24 Dec 2022 13:18:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671916699; cv=none; d=google.com; s=arc-20160816; b=kS6IludOs/YdaqnEcWLUCGfavAYhK09bKT29RQYzh9bcVxA5QcGhD+8MbIRx7xjF4M kPv8QFVRgQVscbysOLJLeZZOSW17iJECbmyzwxMEjfeYJE+jvLECTtvrTddgSRHuo1Wv ixRK9MsQCCUdYHb7mQmQ94ld1L0Mf1zKqExVC4aFXIw5w64rQPpxcp3OSe/vo7Ot1/Wv oT6vqnrhoTuLCAH00gruJ4DtopyoywyONpDQpecbWdxGKeJrF6AYDcbvzeizmEzoM0+p 1Oi/BaTEE5diWwVSImqa+qmslRTbldHWTM8moMqkUa/+bS4jlYY3Ir4bXAm6Mm0yGaH6 74iA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=yaKsoogCPDHVWnPV6HmWC2IZz0Ru9SDYe/A6jF9v+x8=; b=Vh4+cO+oYJFHSyaZxw3Aq5YI3zesW1Vu0FgklL9pFituMGU/hWajkAmIwqFeks06ki hgkrhVIjcHjBDeFtsSYpap+bSk30b4df+wHdij8aeCHaLZEGShdBErqzYMYRMlqpnaad l2IVpAQvTOlB1GY0uiHKE3AkrIM+jDjeQBqwBxj22uY+IJEKUJvFl/VRy9rghjNF88/N 0U4xqt0+byRPu4rUwiDyRbEbcl8hDsodWyZr9oWFECmQ794XvAlg7eUMdcvEZGmL3CpA 5AITZa240J1KBKRXQV+vbeNPkDbO8mTXYguzZtMFa7ab/t8aQ+uiAbuFulMtf/AItMQr RLng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="IHEA5/at"; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e12-20020a17090658cc00b007ae814af6aasi6037632ejs.87.2022.12.24.13.17.55; Sat, 24 Dec 2022 13:18:19 -0800 (PST) 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="IHEA5/at"; 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 S230233AbiLXVQn (ORCPT + 99 others); Sat, 24 Dec 2022 16:16:43 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50332 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230185AbiLXVQj (ORCPT ); Sat, 24 Dec 2022 16:16:39 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 683DCA447 for ; Sat, 24 Dec 2022 13:16:38 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 18A77B8016A for ; Sat, 24 Dec 2022 21:16:37 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6E5E7C433F0; Sat, 24 Dec 2022 21:16:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671916595; bh=ySpGEUFcvdEqE4LGPb4c2lY8Vn2te6xLgnS8OF0nmEM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=IHEA5/atfot9gZy3MSrVLjUZNV1u4eLIfyMJ4VTqUwwR6L0CCX58gPQKK01m7lMKG McfzfAATsX64wt37mCLGjeJrFzNnPC74XU+cTM1VYvLdcvbYy5huyzgo+KHYfwMyE+ 1w8/DYuDLYZLeGWulVkzqV/hAey/Ru0ICKka7uQ5dsqeo+eN1VNpgSWHo7LHO63x+6 aT5HwidY+o6KZ/75N+q+uf2ZgVJaeOKx5lbLev9JODTwK1VKmP6W4S87ob9r4urd0a vT86eYmdykyDQIz2v/K2QC3MrZxsbFnDED0+JMLd+n4aTBfKW30P4MPgBO5hK0ZjLP WoTunWbWsXDmQ== Received: by pali.im (Postfix) id 26112720; Sat, 24 Dec 2022 22:16:35 +0100 (CET) From: =?utf-8?q?Pali_Roh=C3=A1r?= To: Michael Ellerman , Nicholas Piggin , Christophe Leroy , Scott Wood , Sinan Akman , Martin Kennedy Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 4/8] powerpc/85xx: p2020: Move i8259 code into own function Date: Sat, 24 Dec 2022 22:14:21 +0100 Message-Id: <20221224211425.14983-5-pali@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20221224211425.14983-1-pali@kernel.org> References: <20221224211425.14983-1-pali@kernel.org> MIME-Version: 1.0 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 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1753131724917185347?= X-GMAIL-MSGID: =?utf-8?q?1753131724917185347?= Splits mpic and i8259 initialization codes into separate functions. Signed-off-by: Pali Rohár --- arch/powerpc/platforms/85xx/p2020.c | 37 ++++++++++++++++------------- 1 file changed, 21 insertions(+), 16 deletions(-) diff --git a/arch/powerpc/platforms/85xx/p2020.c b/arch/powerpc/platforms/85xx/p2020.c index d65d4c88ac47..b8584bf307b0 100644 --- a/arch/powerpc/platforms/85xx/p2020.c +++ b/arch/powerpc/platforms/85xx/p2020.c @@ -45,6 +45,7 @@ #ifdef CONFIG_MPC85xx_DS #ifdef CONFIG_PPC_I8259 + static void mpc85xx_8259_cascade(struct irq_desc *desc) { struct irq_chip *chip = irq_desc_get_chip(desc); @@ -55,27 +56,13 @@ static void mpc85xx_8259_cascade(struct irq_desc *desc) } chip->irq_eoi(&desc->irq_data); } -#endif /* CONFIG_PPC_I8259 */ -static void __init mpc85xx_ds_pic_init(void) +static void __init mpc85xx_8259_init(void) { - struct mpic *mpic; -#ifdef CONFIG_PPC_I8259 struct device_node *np; struct device_node *cascade_node = NULL; int cascade_irq; -#endif - - mpic = mpic_alloc(NULL, 0, - MPIC_BIG_ENDIAN | - MPIC_SINGLE_DEST_CPU, - 0, 256, " OpenPIC "); - - BUG_ON(mpic == NULL); - mpic_init(mpic); -#ifdef CONFIG_PPC_I8259 - /* Initialize the i8259 controller */ for_each_node_by_type(np, "interrupt-controller") if (of_device_is_compatible(np, "chrp,iic")) { cascade_node = np; @@ -93,13 +80,31 @@ static void __init mpc85xx_ds_pic_init(void) return; } - DBG("mpc85xxds: cascade mapped to irq %d\n", cascade_irq); + DBG("i8259: cascade mapped to irq %d\n", cascade_irq); i8259_init(cascade_node, 0); of_node_put(cascade_node); irq_set_chained_handler(cascade_irq, mpc85xx_8259_cascade); +} + #endif /* CONFIG_PPC_I8259 */ + +static void __init mpc85xx_ds_pic_init(void) +{ + struct mpic *mpic; + + mpic = mpic_alloc(NULL, 0, + MPIC_BIG_ENDIAN | + MPIC_SINGLE_DEST_CPU, + 0, 256, " OpenPIC "); + + BUG_ON(mpic == NULL); + mpic_init(mpic); + +#ifdef CONFIG_PPC_I8259 + mpc85xx_8259_init(); +#endif } #ifdef CONFIG_PCI From patchwork Sat Dec 24 21:14:22 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Pali_Roh=C3=A1r?= X-Patchwork-Id: 36447 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp297688wrt; Sat, 24 Dec 2022 13:18:49 -0800 (PST) X-Google-Smtp-Source: AMrXdXuxgcNI56TgYPNdfNB6zXVao4vbsWWYuZS/+osO3wgtWatilVZ5iQFZ0gjM2+FOzIkG5jwK X-Received: by 2002:a17:906:6a05:b0:7c1:28a7:f7a0 with SMTP id qw5-20020a1709066a0500b007c128a7f7a0mr15815165ejc.31.1671916729626; Sat, 24 Dec 2022 13:18:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671916729; cv=none; d=google.com; s=arc-20160816; b=Gnc4MhhbEC6xuMFk1A5tzQUqPMRBv1MeGT61sH6DY6jTP4GA62Ona89Ae4Nz0BQ5KP q1M7lmT8asp5b+dnXD05/4BKZ5qVXimjAJuWgUfh3mLA5ni9qq7vioUtMhj2ptDt8EES CzfEEt5HiwoNglUIx8GDGKdx7a4HnUYnjBcU+CfcBvCktuV4rqZiqIfL9qyJD+j77137 9jHZnVdvtD6CsyX3d6qPkJnGfuBfjVdkHDxw1zhTPr3DCrV5crXUfeU7U6OJybjmEK5+ 1PThLcTs+E69GMCmDdqxeR4Ph7A/ywpYHYhuwwpcHcSbw8b1e2Hak1rAqxDidzJqoBIL DAug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=y1iakPxgrZvOlztvcOdew468TzjyHg4eVYKb5KzTi9w=; b=j1WTp92Susu5oiKSGHIF7iXKD9koXjQOrzJgWw2es8xBVahPOzA6zMLQdZVZnToM3D S77LR6njgFbQOhmwfMKRSu/Cm1tUne63veeeqBnJWJJnJNPK3QRTuqteTGYsMVQa2iLv 8kMfs9J3kp8DSbRRn03eH60SyHnk7E86Xwr7UalsFt/EbxCAw4wZcnp4wTxEMa+di/0l 5kXc2G+mvRrWXwqlPpVeri82UFq4eXrC//5jd69vtVtAbTDWLdll4AN0dGvXNJFxuBUa Z4shkfyGMyoJ6AcXKTgATX6G5OiAKWUnVwVY85MA/Rhi5EAG6495+Pi4URjHEQfLZPpl 3HtQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=DsDHwiA1; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hz5-20020a1709072ce500b007c143a8a656si5502856ejc.997.2022.12.24.13.18.26; Sat, 24 Dec 2022 13:18:49 -0800 (PST) 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=DsDHwiA1; 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 S230355AbiLXVQv (ORCPT + 99 others); Sat, 24 Dec 2022 16:16:51 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50364 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230203AbiLXVQk (ORCPT ); Sat, 24 Dec 2022 16:16:40 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 83207A457 for ; Sat, 24 Dec 2022 13:16:39 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 1B4FCB802C6 for ; Sat, 24 Dec 2022 21:16:38 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 833C9C433EF; Sat, 24 Dec 2022 21:16:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671916596; bh=xNSdUI6pz4D6dE9/Og/zOzJThSiw3fw4+p8TGNZp1R0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=DsDHwiA1Ml1/V9aFtJjyvnguPlFykX7SqWAxLPn1/2OmrJiOtMFJu4fiHxeS/51MK Py+b9wD4O1fIaKofMSAk5BsCmejZSGQvCpumBQW8uCG+/+lfjy+Grcirb4Ylj28tg+ rAvSS0SGB0nYtqB+OWSEVZZIx+kVYF/j2qUfhNI7wZcPCQDrhalzqL3i9rKrMLs4dK 7EctiQ30THPYXQhdWffKwWrkKqvfSjA+DKBdqguvkJNhmriQNHcGmUjccIU5c+Xfn/ st4O39arY0XTQSTA4BbwaAtrRsavYjyMyZHmES05IGpln7mgG2bIClTgqfszYSLO81 yFaOQARpg4mBQ== Received: by pali.im (Postfix) id 3E87D720; Sat, 24 Dec 2022 22:16:36 +0100 (CET) From: =?utf-8?q?Pali_Roh=C3=A1r?= To: Michael Ellerman , Nicholas Piggin , Christophe Leroy , Scott Wood , Sinan Akman , Martin Kennedy Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 5/8] powerpc/85xx: p2020: Unify .setup_arch and .init_IRQ callbacks Date: Sat, 24 Dec 2022 22:14:22 +0100 Message-Id: <20221224211425.14983-6-pali@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20221224211425.14983-1-pali@kernel.org> References: <20221224211425.14983-1-pali@kernel.org> MIME-Version: 1.0 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 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1753131756699638718?= X-GMAIL-MSGID: =?utf-8?q?1753131756699638718?= Make just one .setup_arch and one .init_IRQ callback implementation for all P2020 board code. This deduplicate repeated and same code. Signed-off-by: Pali Rohár --- arch/powerpc/platforms/85xx/p2020.c | 58 +++++------------------------ 1 file changed, 9 insertions(+), 49 deletions(-) diff --git a/arch/powerpc/platforms/85xx/p2020.c b/arch/powerpc/platforms/85xx/p2020.c index b8584bf307b0..adf3750abef9 100644 --- a/arch/powerpc/platforms/85xx/p2020.c +++ b/arch/powerpc/platforms/85xx/p2020.c @@ -42,8 +42,6 @@ #define DBG(fmt, args...) #endif -#ifdef CONFIG_MPC85xx_DS - #ifdef CONFIG_PPC_I8259 static void mpc85xx_8259_cascade(struct irq_desc *desc) @@ -90,7 +88,7 @@ static void __init mpc85xx_8259_init(void) #endif /* CONFIG_PPC_I8259 */ -static void __init mpc85xx_ds_pic_init(void) +static void __init p2020_pic_init(void) { struct mpic *mpic; @@ -143,58 +141,20 @@ static void __init mpc85xx_ds_uli_init(void) #endif } -#endif /* CONFIG_MPC85xx_DS */ - -#ifdef CONFIG_MPC85xx_RDB -static void __init mpc85xx_rdb_pic_init(void) -{ - struct mpic *mpic; - - mpic = mpic_alloc(NULL, 0, - MPIC_BIG_ENDIAN | - MPIC_SINGLE_DEST_CPU, - 0, 256, " OpenPIC "); - - BUG_ON(mpic == NULL); - mpic_init(mpic); -} -#endif /* CONFIG_MPC85xx_RDB */ - /* * Setup the architecture */ -#ifdef CONFIG_MPC85xx_DS -static void __init mpc85xx_ds_setup_arch(void) +static void __init p2020_setup_arch(void) { - if (ppc_md.progress) - ppc_md.progress("mpc85xx_ds_setup_arch()", 0); - swiotlb_detect_4g(); fsl_pci_assign_primary(); mpc85xx_ds_uli_init(); mpc85xx_smp_init(); - printk("MPC85xx DS board from Freescale Semiconductor\n"); -} -#endif /* CONFIG_MPC85xx_DS */ - -#ifdef CONFIG_MPC85xx_RDB -static void __init mpc85xx_rdb_setup_arch(void) -{ - if (ppc_md.progress) - ppc_md.progress("mpc85xx_rdb_setup_arch()", 0); - - mpc85xx_smp_init(); - - fsl_pci_assign_primary(); - #ifdef CONFIG_QUICC_ENGINE mpc85xx_qe_par_io_init(); -#endif /* CONFIG_QUICC_ENGINE */ - - printk(KERN_INFO "MPC85xx RDB board from Freescale Semiconductor\n"); +#endif } -#endif /* CONFIG_MPC85xx_RDB */ #ifdef CONFIG_MPC85xx_DS machine_arch_initcall(p2020_ds, mpc85xx_common_publish_devices); @@ -235,8 +195,8 @@ static int __init p2020_rdb_pc_probe(void) define_machine(p2020_ds) { .name = "P2020 DS", .probe = p2020_ds_probe, - .setup_arch = mpc85xx_ds_setup_arch, - .init_IRQ = mpc85xx_ds_pic_init, + .setup_arch = p2020_setup_arch, + .init_IRQ = p2020_pic_init, #ifdef CONFIG_PCI .pcibios_fixup_bus = fsl_pcibios_fixup_bus, .pcibios_fixup_phb = fsl_pcibios_fixup_phb, @@ -251,8 +211,8 @@ define_machine(p2020_ds) { define_machine(p2020_rdb) { .name = "P2020 RDB", .probe = p2020_rdb_probe, - .setup_arch = mpc85xx_rdb_setup_arch, - .init_IRQ = mpc85xx_rdb_pic_init, + .setup_arch = p2020_setup_arch, + .init_IRQ = p2020_pic_init, #ifdef CONFIG_PCI .pcibios_fixup_bus = fsl_pcibios_fixup_bus, .pcibios_fixup_phb = fsl_pcibios_fixup_phb, @@ -265,8 +225,8 @@ define_machine(p2020_rdb) { define_machine(p2020_rdb_pc) { .name = "P2020RDB-PC", .probe = p2020_rdb_pc_probe, - .setup_arch = mpc85xx_rdb_setup_arch, - .init_IRQ = mpc85xx_rdb_pic_init, + .setup_arch = p2020_setup_arch, + .init_IRQ = p2020_pic_init, #ifdef CONFIG_PCI .pcibios_fixup_bus = fsl_pcibios_fixup_bus, .pcibios_fixup_phb = fsl_pcibios_fixup_phb, From patchwork Sat Dec 24 21:14:23 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Pali_Roh=C3=A1r?= X-Patchwork-Id: 36449 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp298982wrt; Sat, 24 Dec 2022 13:24:06 -0800 (PST) X-Google-Smtp-Source: AMrXdXuYMgBHiuumzPHXd96lqM7w0o1jZA67xjUj1pCq8vaz/1rSZ3/kSadTdkYUu8xeiHaKw+kY X-Received: by 2002:a17:906:144a:b0:78d:f455:b4d5 with SMTP id q10-20020a170906144a00b0078df455b4d5mr11937124ejc.60.1671917046027; Sat, 24 Dec 2022 13:24:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671917046; cv=none; d=google.com; s=arc-20160816; b=Zol99loBrhwm0BhD6oHEzZcaxVCkiPky8VEZ14UKteKfpK1NH/DWsfS+L9NjMHypME NQd7Ol7uEjdAKe0ZLLqsFY9ILx/e0D+JWQpQtTJ/6s2AXRZtiZ5DMR7565Z6Tb1UMw0d gho06hBFMp4SOME4H+pgpWOTat9WuIAJ1ovXRJ/K6DHbIePN9lBqp7fVhEEa1WhrDa0l ++vXrquSEv36h1N6uD7TS9lVQIsZpoB+liwfmqjpmXguTnPFA0JncaNqklgrjGY4C9y6 ZqsCdEkIs+vp8H0W+9thMSiXvkldV4JB87ozruW0xglPA2k41DosMg6Y2VmQfR96QiLQ iHgg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=+r48FS7s2eQer8HrSKeyymB18gsQJWW/VGzlE/IwTn4=; b=aOp/jVTsZZQD8aFU6tT/i4ETNNrlLHIIM9ECtY0gZTSOH+1kcMFgi+isjS+hR/WxGe yKkj4RTQkp1JyhlDWep/RzinjEjKlJA/0jNEddsHdRHmwXEqXjdv0Y4qBPHeUjs40bt/ ZPrR/7pYX7aQJ3NBKy7L6OOaLLAs/DFiQkOtq9zNyiOMjfF3eCkeJM7yETiVpiFejT1Y nPotytcMW53INQGCOOpfJld6FGDoTRNMGVIxB+bOXoCsgfHTUT0LOAXtA3DXUvMMo7KS p2+DLY0511yqaf1iT/faTu1sazuC74Dl4OC0NvVW3Ju2ro9MOTbC7im+jwbak76cSlyb fF+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=drl8Y8PL; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id xi1-20020a170906dac100b007a953d421bbsi5276243ejb.322.2022.12.24.13.23.42; Sat, 24 Dec 2022 13:24:06 -0800 (PST) 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=drl8Y8PL; 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 S230376AbiLXVR6 (ORCPT + 99 others); Sat, 24 Dec 2022 16:17:58 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51500 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230250AbiLXVRu (ORCPT ); Sat, 24 Dec 2022 16:17:50 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AD841A445 for ; Sat, 24 Dec 2022 13:17:49 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 37248B802C6 for ; Sat, 24 Dec 2022 21:17:48 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8DF47C433D2; Sat, 24 Dec 2022 21:17:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671916666; bh=GmtMxhGoXO8mzjcBa/1xqcbgZxWhZejdfxvLHGTF0Vo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=drl8Y8PLpCkemip4M3K5tuRiOA8LlyJDgh1VykS/oxwNX42iAY+ljwHIunIvcrvlL gvFf+OKBa6GagtAf+21dsQUMgIiUYne73KTouQe4XrDwiK25zCzvXIFVK5+Xf12uFr Vyf6YgTBugtUWKgG2RVT1ZocrT4h3xztj4sgeouE+Pf3fWZM/gLpvqy0dQUA1iXRa4 Fv32OA9mKRU+HD1kG4zg52JJrVoaLA5R3/bQVdSYmPCkZg/dcoGXhx/gMztmRioXD8 q4phiHHP7pg0h43b9qBz1kj5z0C7tAzgAxgMkJDmD+XdrsLoBh6lKm3ubJvnyZ29tL l9CAECGu7XhcA== Received: by pali.im (Postfix) id F31E4720; Sat, 24 Dec 2022 22:17:43 +0100 (CET) From: =?utf-8?q?Pali_Roh=C3=A1r?= To: Michael Ellerman , Nicholas Piggin , Christophe Leroy , Scott Wood , Sinan Akman , Martin Kennedy Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 6/8] powerpc/85xx: p2020: Define just one machine description Date: Sat, 24 Dec 2022 22:14:23 +0100 Message-Id: <20221224211425.14983-7-pali@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20221224211425.14983-1-pali@kernel.org> References: <20221224211425.14983-1-pali@kernel.org> MIME-Version: 1.0 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 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1753132088390948824?= X-GMAIL-MSGID: =?utf-8?q?1753132088390948824?= Combine machine descriptions and code of all P2020 boards into just one generic unified P2020 machine description. This allows kernel to boot on any P2020-based board with P2020 DTS file without need to patch kernel and define a new machine description in 85xx powerpc platform directory. Signed-off-by: Pali Rohár --- arch/powerpc/platforms/85xx/p2020.c | 83 +++++++---------------------- 1 file changed, 19 insertions(+), 64 deletions(-) diff --git a/arch/powerpc/platforms/85xx/p2020.c b/arch/powerpc/platforms/85xx/p2020.c index adf3750abef9..b3fb600e1d83 100644 --- a/arch/powerpc/platforms/85xx/p2020.c +++ b/arch/powerpc/platforms/85xx/p2020.c @@ -156,83 +156,38 @@ static void __init p2020_setup_arch(void) #endif } -#ifdef CONFIG_MPC85xx_DS -machine_arch_initcall(p2020_ds, mpc85xx_common_publish_devices); -#endif /* CONFIG_MPC85xx_DS */ - -#ifdef CONFIG_MPC85xx_RDB -machine_arch_initcall(p2020_rdb, mpc85xx_common_publish_devices); -machine_arch_initcall(p2020_rdb_pc, mpc85xx_common_publish_devices); -#endif /* CONFIG_MPC85xx_RDB */ +machine_arch_initcall(p2020, mpc85xx_common_publish_devices); /* * Called very early, device-tree isn't unflattened */ -#ifdef CONFIG_MPC85xx_DS -static int __init p2020_ds_probe(void) -{ - return !!of_machine_is_compatible("fsl,P2020DS"); -} -#endif /* CONFIG_MPC85xx_DS */ - -#ifdef CONFIG_MPC85xx_RDB -static int __init p2020_rdb_probe(void) -{ - if (of_machine_is_compatible("fsl,P2020RDB")) - return 1; - return 0; -} - -static int __init p2020_rdb_pc_probe(void) +static int __init p2020_probe(void) { - if (of_machine_is_compatible("fsl,P2020RDB-PC")) - return 1; - return 0; + struct device_node *p2020_cpu; + + /* + * There is no common compatible string for all P2020 boards. + * The only common thing is "PowerPC,P2020@0" cpu node. + * So check for P2020 board via this cpu node. + */ + p2020_cpu = of_find_node_by_path("/cpus/PowerPC,P2020@0"); + if (!p2020_cpu) + return 0; + + of_node_put(p2020_cpu); + return 1; } -#endif /* CONFIG_MPC85xx_RDB */ - -#ifdef CONFIG_MPC85xx_DS -define_machine(p2020_ds) { - .name = "P2020 DS", - .probe = p2020_ds_probe, - .setup_arch = p2020_setup_arch, - .init_IRQ = p2020_pic_init, -#ifdef CONFIG_PCI - .pcibios_fixup_bus = fsl_pcibios_fixup_bus, - .pcibios_fixup_phb = fsl_pcibios_fixup_phb, -#endif - .get_irq = mpic_get_irq, - .calibrate_decr = generic_calibrate_decr, - .progress = udbg_progress, -}; -#endif /* CONFIG_MPC85xx_DS */ - -#ifdef CONFIG_MPC85xx_RDB -define_machine(p2020_rdb) { - .name = "P2020 RDB", - .probe = p2020_rdb_probe, - .setup_arch = p2020_setup_arch, - .init_IRQ = p2020_pic_init, -#ifdef CONFIG_PCI - .pcibios_fixup_bus = fsl_pcibios_fixup_bus, - .pcibios_fixup_phb = fsl_pcibios_fixup_phb, -#endif - .get_irq = mpic_get_irq, - .calibrate_decr = generic_calibrate_decr, - .progress = udbg_progress, -}; -define_machine(p2020_rdb_pc) { - .name = "P2020RDB-PC", - .probe = p2020_rdb_pc_probe, +define_machine(p2020) { + .name = "Freescale P2020", + .probe = p2020_probe, .setup_arch = p2020_setup_arch, .init_IRQ = p2020_pic_init, #ifdef CONFIG_PCI .pcibios_fixup_bus = fsl_pcibios_fixup_bus, - .pcibios_fixup_phb = fsl_pcibios_fixup_phb, + .pcibios_fixup_phb = fsl_pcibios_fixup_phb, #endif .get_irq = mpic_get_irq, .calibrate_decr = generic_calibrate_decr, .progress = udbg_progress, }; -#endif /* CONFIG_MPC85xx_RDB */ From patchwork Sat Dec 24 21:14:24 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Pali_Roh=C3=A1r?= X-Patchwork-Id: 36448 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp298111wrt; Sat, 24 Dec 2022 13:20:23 -0800 (PST) X-Google-Smtp-Source: AMrXdXu2Oezb+rSfPRxNl8YndhkxGgvF5UAc6/IO7dnj9Ii+Ax8poQwNlkXb8D+xZEzh/mfMIW4b X-Received: by 2002:a17:907:c388:b0:849:e96f:51f4 with SMTP id tm8-20020a170907c38800b00849e96f51f4mr4697027ejc.23.1671916823405; Sat, 24 Dec 2022 13:20:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671916823; cv=none; d=google.com; s=arc-20160816; b=ris9j9Z1uCajA0kMClNT1aaEdFA3FDWZ+m+u2tGwz4VJ7TXIaQBLJqtC3kWCwQo5FV nTmg66zeKfRr/4Ts2uhoMuQIt46VuZlyt+sB3L9iHhCHnEW2tJKximTNCHx7cjkGkTZ4 2/H6SWjgZ0TlOCLSGAKJp+WGr7n7Fq51HcZ1+M0stjuZw0jlNKKY6SEDvx1+9stv+VaX 0vPouPwyoU0ZpWVD+k34ljp4NfLCCDBfLE8XkY3qTyFVlEfS6E2d+NJuFOY6u6TL6fV+ sw4jeQvQU8DrBwcyM8DErb4nJKduFYuAcPJNGj93/ncyOw/26V7+GydLq4ELq5zzx+gW I00A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=dZcgJ41/B6cbYEHDgEcLn4Liv9SSoIKtO/jUlNeSxYk=; b=M61jdHlNFs4KoAlsMKN3ger/L0bGxpiOtAX4dIyhZDH/DRRV7P3PAZOHfC0iNLliY0 gds6tOoW8M2y/9/vEfojl2tGkgYNFhQv1PbJCHMtpnQB68Df1qN9YHSsHHMsXAVi3lcK bGlS49zV8AIXIphAt7dqOEblV5NDhjmk3Ij+WY6BVRNWstAaXkAsTb2WhB7jPZMwb2Bd v+5r9PoxXD2CheyooAbu3KzWaPaZSMOXIz7hxmXOGhepnyxpuVTvS8Gk6vQHbLHVR4E9 gNALYe9HV5QeaKdsZ1Wop49gjXsHBbj8cbG7GKyVQHPGs8Jzx5PcqgiJ+x1pQY3juQ9n EmMw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=nlH0n42j; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hq39-20020a1709073f2700b00832db6f55f3si6181824ejc.532.2022.12.24.13.20.00; Sat, 24 Dec 2022 13:20:23 -0800 (PST) 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=nlH0n42j; 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 S230294AbiLXVRz (ORCPT + 99 others); Sat, 24 Dec 2022 16:17:55 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51510 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230297AbiLXVRv (ORCPT ); Sat, 24 Dec 2022 16:17:51 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7D9D2A447 for ; Sat, 24 Dec 2022 13:17:50 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 0436DB803F3 for ; Sat, 24 Dec 2022 21:17:49 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 95FC5C433EF; Sat, 24 Dec 2022 21:17:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671916667; bh=13zOblXSPCKmmAdfWqVJT/RFm4vtSa7vCpTc5iq/PY0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=nlH0n42jrmpjHRFZuqdIaqsBKhZ7ZBekaTz2U9h7oHKh0wg7KcoYy9bcnXynZRkeJ Wu9Zr4t7dgqkNQ/3S6jdfRIb7I21fU2ibuKq/FvyyvAzdK5KHi9nE9FpgLrhnT5ihc g5BJN26YS22x+3gXkZySk4v/zAMI/pkU1vDFnT9FncxT4+LdvkgOtRVJXb+J1Ra649 rK92Getqe3un2LZ4SPxR9Iby30rFv0zE3iWC1ssq3/CTBJWuMEkOKnFcig3cZxhP/M u+e6guo4QeMHtpApOcZXsjXlvk0L4hTa18biKXwzYJrWJyJzV0t+UTYDZMikhcD9/3 OKGhxN3qFBrSA== Received: by pali.im (Postfix) id 33D569D7; Sat, 24 Dec 2022 22:17:45 +0100 (CET) From: =?utf-8?q?Pali_Roh=C3=A1r?= To: Michael Ellerman , Nicholas Piggin , Christophe Leroy , Scott Wood , Sinan Akman , Martin Kennedy Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 7/8] powerpc/85xx: p2020: Enable boards by new config option CONFIG_PPC_P2020 Date: Sat, 24 Dec 2022 22:14:24 +0100 Message-Id: <20221224211425.14983-8-pali@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20221224211425.14983-1-pali@kernel.org> References: <20221224211425.14983-1-pali@kernel.org> MIME-Version: 1.0 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 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1753131855095240033?= X-GMAIL-MSGID: =?utf-8?q?1753131855095240033?= Generic unified P2020 machine description which supports all P2020-based boards is now in separate file p2020.c. So create a separate config option CONFIG_PPC_P2020 for it. Previously machine descriptions for P2020 boards were enabled by CONFIG_MPC85xx_DS or CONFIG_MPC85xx_RDB option. So set CONFIG_PPC_P2020 to be enabled by default when one of those option is enabled. This allows to compile support for P2020 boards without need to have enabled support for older mpc85xx boards. And to compile kernel for old mpc85xx boards without having enabled support for new P2020 boards. Signed-off-by: Pali Rohár --- arch/powerpc/platforms/85xx/Kconfig | 22 ++++++++++++++++++---- arch/powerpc/platforms/85xx/Makefile | 3 +-- 2 files changed, 19 insertions(+), 6 deletions(-) diff --git a/arch/powerpc/platforms/85xx/Kconfig b/arch/powerpc/platforms/85xx/Kconfig index b92cb2b4d54d..90665882143b 100644 --- a/arch/powerpc/platforms/85xx/Kconfig +++ b/arch/powerpc/platforms/85xx/Kconfig @@ -78,16 +78,16 @@ config MPC8536_DS This option enables support for the MPC8536 DS board config MPC85xx_DS - bool "Freescale MPC8544 DS / MPC8572 DS / P2020 DS" + bool "Freescale MPC8544 DS / MPC8572 DS" select PPC_I8259 select DEFAULT_UIMAGE select FSL_ULI1575 if PCI select SWIOTLB help - This option enables support for the MPC8544 DS, MPC8572 DS and P2020 DS boards + This option enables support for the MPC8544 DS and MPC8572 DS boards config MPC85xx_RDB - bool "Freescale P102x MBG/UTM/RDB and P2020 RDB" + bool "Freescale P102x MBG/UTM/RDB" select PPC_I8259 select DEFAULT_UIMAGE select FSL_ULI1575 if PCI @@ -95,7 +95,21 @@ config MPC85xx_RDB help This option enables support for the P1020 MBG PC, P1020 UTM PC, P1020 RDB PC, P1020 RDB PD, P1020 RDB, P1021 RDB PC, P1024 RDB, - P1025 RDB, P2020 RDB and P2020 RDB PC boards + and P1025 RDB boards + +config PPC_P2020 + bool "Freescale P2020" + default y if MPC85xx_DS || MPC85xx_RDB + select DEFAULT_UIMAGE + select SWIOTLB + imply PPC_I8259 + imply FSL_ULI1575 if PCI + help + This option enables generic unified support for any board with the + Freescale P2020 processor. + + For example: P2020 DS board, P2020 RDB board, P2020 RDB PC board or + CZ.NIC Turris 1.x boards. config P1010_RDB bool "Freescale P1010 RDB" diff --git a/arch/powerpc/platforms/85xx/Makefile b/arch/powerpc/platforms/85xx/Makefile index 1ad261b4eeb6..76ee691d29b5 100644 --- a/arch/powerpc/platforms/85xx/Makefile +++ b/arch/powerpc/platforms/85xx/Makefile @@ -23,8 +23,7 @@ obj-$(CONFIG_P1010_RDB) += p1010rdb.o obj-$(CONFIG_P1022_DS) += p1022_ds.o obj-$(CONFIG_P1022_RDK) += p1022_rdk.o obj-$(CONFIG_P1023_RDB) += p1023_rdb.o -obj-$(CONFIG_MPC85xx_DS) += p2020.o -obj-$(CONFIG_MPC85xx_RDB) += p2020.o +obj-$(CONFIG_PPC_P2020) += p2020.o obj-$(CONFIG_TWR_P102x) += twr_p102x.o obj-$(CONFIG_CORENET_GENERIC) += corenet_generic.o obj-$(CONFIG_FB_FSL_DIU) += t1042rdb_diu.o From patchwork Sat Dec 24 21:14:25 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Pali_Roh=C3=A1r?= X-Patchwork-Id: 36450 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp299136wrt; Sat, 24 Dec 2022 13:24:47 -0800 (PST) X-Google-Smtp-Source: AMrXdXuswJwwOT3X2e0K9yVNlvDMLKzhsjZ+bwdO8RNOeHlW997O3jsEvnfa4uHI5fIwGlF+kq3M X-Received: by 2002:aa7:d04d:0:b0:46d:543:b4c7 with SMTP id n13-20020aa7d04d000000b0046d0543b4c7mr11723043edo.17.1671917087510; Sat, 24 Dec 2022 13:24:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671917087; cv=none; d=google.com; s=arc-20160816; b=Blj0ce11jH21SOjCzIgpX2lJDmI6vgseTRNV7UPUF0dMO1g3MU1w6FiBmYT3BOK8us ZNUFIK964S8KB0TI+BryNH8jQsEO5axey7BXG8p294RbKY8JybLeNw37YLb26n1FxNdU +cKphS078Z4ZqUxQBG0bOulZOtgG+YzaSa+rHu0WJ/hpiVvkhXJLMc3kIXm1V+dbf4Ov J6f/fXoiUvuEB8Q1Jhtl72tRmXdKtBPn2DhnxFDtV6I5H4V0AEC0FXE3eBua5suuYxuz qZ9vXM136aCqeNliTRUlqYrZZ319D9r0SZGcbtA/Rl/AxLZJc+BRrmxSVqfL1gLXNyHu 5YeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=hDUbyfLeLlxpum6b6lhlm+tDPHSdRKm1GVbXAEvQcz0=; b=Bz6Y96sM+qQ1f0Vb4gq9Sm3og0kWbmpOGS4dUmd9TkUML2JNxSBPWCJS/W76M4e/5g k6jLDXn2CrDt03BLM6YmWLO0itZVs3aHgHPRgLt52mO609R70gTZbCY7XJB9rOPHElVm qrcx8trcKhTx0MEanAZmfh/n7s01IQ9cFkGgSJ6hbT/zBTk5001rowbfXbAWIHU/Lqm1 4VmfZgQSV9t1+cKcFTrPyRCm2dmfQ4Fr9VUuHvxtqrBIWHAc/LnDtUqQ7772brYTorvc erKmjM1+/Kii59EthuXY7kK/7V4H9SgYobsf6U1CIXvO8x3xPGSwERtCKZHpmr7WpI5i rOzQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=BDOZE3l5; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x13-20020a05640226cd00b0046ac13261a1si6171948edd.459.2022.12.24.13.24.23; Sat, 24 Dec 2022 13:24:47 -0800 (PST) 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=BDOZE3l5; 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 S230394AbiLXVSD (ORCPT + 99 others); Sat, 24 Dec 2022 16:18:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51294 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230364AbiLXVRv (ORCPT ); Sat, 24 Dec 2022 16:17:51 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1A0A1A459 for ; Sat, 24 Dec 2022 13:17:51 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id C6B19B80189 for ; Sat, 24 Dec 2022 21:17:49 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6908BC433F0; Sat, 24 Dec 2022 21:17:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1671916668; bh=5jg2jqGPIyL6vN19Ng9QZ/xR8UUjQOy1EGr++zpbTmM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BDOZE3l54x8eupSo5X3S7yWgViyX+eDy0DbSLU2Js6c4GbJHOh9rfHZBiciZUf13/ jRQu5yuEvzN7aMWx/RDVkQiAjTmhbv97dY4e5dIgVovnxSfAgGpzDpSoZJ7FeqdvQi tKQGKRnPFBELka1oWhrfjkWFTy287o7F1+GCW3p01G/Vyg66MDcwZOfJcnD8rMSXWB ++CSDpguhNJQkdv+veJVZOXdK0/i4SR4jPYTITxAfl6tYrBkDkmm9zzCDRFU8tmFbE DuyTbuemxIGbKEZ7Kvc5Bd2JNgo0XPdy3VXTKFxOEF239+3PfzF1KvouW8dVBfczFQ 02IxbqgP73mWg== Received: by pali.im (Postfix) id 48F0D9E4; Sat, 24 Dec 2022 22:17:46 +0100 (CET) From: =?utf-8?q?Pali_Roh=C3=A1r?= To: Michael Ellerman , Nicholas Piggin , Christophe Leroy , Scott Wood , Sinan Akman , Martin Kennedy Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 8/8] powerpc: dts: turris1x.dts: Remove "fsl,P2020RDB-PC" compatible string Date: Sat, 24 Dec 2022 22:14:25 +0100 Message-Id: <20221224211425.14983-9-pali@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20221224211425.14983-1-pali@kernel.org> References: <20221224211425.14983-1-pali@kernel.org> MIME-Version: 1.0 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 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1753132131762457562?= X-GMAIL-MSGID: =?utf-8?q?1753132131762457562?= "fsl,P2020RDB-PC" compatible string was present in Turris 1.x DTS file just because Linux kernel required it for proper detection of P2020 processor during boot. This was quite a hack as CZ.NIC Turris 1.x is not compatible with Freescale P2020-RDB-PC board. Now when kernel has generic unified support for boards with P2020 processors, there is no need to have this "hack" in turris1x.dts file. So remove incorrect "fsl,P2020RDB-PC" compatible string from turris1x.dts. Signed-off-by: Pali Rohár --- arch/powerpc/boot/dts/turris1x.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/boot/dts/turris1x.dts b/arch/powerpc/boot/dts/turris1x.dts index e9cda34a140e..a95857de6858 100644 --- a/arch/powerpc/boot/dts/turris1x.dts +++ b/arch/powerpc/boot/dts/turris1x.dts @@ -15,7 +15,7 @@ / { model = "Turris 1.x"; - compatible = "cznic,turris1x", "fsl,P2020RDB-PC"; /* fsl,P2020RDB-PC is required for booting Linux */ + compatible = "cznic,turris1x"; aliases { ethernet0 = &enet0;