From patchwork Wed May 17 15:39:31 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Kaiser X-Patchwork-Id: 13245227 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9DAC5C77B7F for ; Wed, 17 May 2023 15:41:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=AE+vgH9lBlKnPlU2vq3wOyy+Tdo4j2GGg+Hq8uuG9wo=; b=4lLW0LyzSPJl2S k0Hufrf0JkcBMHpFA3DwKY102acFH1jyI0hsqhz3nXCWQjcZJfmAV0zYRp3yIMNmb+PjnN5TBVAxg MxwnEcmxlSVSqfy3W2HqeaW2zwkZ3tPev7xo6oaxSvBu1QmbQkRUbFen/Y7kbpsN/uqCC1iqWHMUp rmhZrSn5ZqdAVPQkLAlt7zxWVz+W8STzQMI+gCiA6+yQhcRKSpiylZAL03ODgIeb57yZiUvEE6F8M ULo8kw05X0hdkBdF4h/Z7XLFJqpi8X4ChpzL6M7NysDkyXFK6loVfWdBEErfRX1er0o7iZ5rr6akP lOJ/rrjMK/VS1EXxZVQA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pzJH6-00AKsP-2C; Wed, 17 May 2023 15:41:12 +0000 Received: from viti.kaiser.cx ([2a01:238:43fe:e600:cd0c:bd4a:7a3:8e9f]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pzJGu-00AKi5-1y for linux-arm-kernel@lists.infradead.org; Wed, 17 May 2023 15:41:02 +0000 Received: from ipservice-092-217-095-237.092.217.pools.vodafone-ip.de ([92.217.95.237] helo=martin-debian-2.paytec.ch) by viti.kaiser.cx with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1pzJGh-0004yN-0U; Wed, 17 May 2023 17:40:47 +0200 From: Martin Kaiser To: Abel Vesa , Stephen Boyd Cc: Shawn Guo , Pengutronix Kernel Team , Fabio Estevam , Arnd Bergmann , linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org, Martin Kaiser Subject: [PATCH v5 1/2] clk: imx25: print silicon revision during init Date: Wed, 17 May 2023 17:39:31 +0200 Message-Id: <20230517153932.172081-2-martin@kaiser.cx> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20230517153932.172081-1-martin@kaiser.cx> References: <20220815190748.102664-1-martin@kaiser.cx> <20230517153932.172081-1-martin@kaiser.cx> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230517_084100_809938_D1C585FB X-CRM114-Status: GOOD ( 12.62 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Print the imx25 silicon revision when the clocks are initialised. Use the same mechanism as for imx27, i.e. call mx25_revision. This function is unused at the moment. Signed-off-by: Martin Kaiser Reviewed-by: Fabio Estevam --- changes in v5: - rebase against today's linux-next changes in v4: - rebase against today's linux-next - add Fabio's Reviewed-by tag changes in v3: - rebase against today's linux-next changes in v2: - send the patch to the clk maintainers drivers/clk/imx/clk-imx25.c | 3 +++ include/soc/imx/revision.h | 1 + 2 files changed, 4 insertions(+) diff --git a/drivers/clk/imx/clk-imx25.c b/drivers/clk/imx/clk-imx25.c index cc013b343e62..bee3da2e21e1 100644 --- a/drivers/clk/imx/clk-imx25.c +++ b/drivers/clk/imx/clk-imx25.c @@ -13,6 +13,7 @@ #include #include #include +#include #include "clk.h" @@ -220,6 +221,8 @@ static int __init __mx25_clocks_init(void __iomem *ccm_base) imx_register_uart_clocks(); + imx_print_silicon_rev("i.MX25", mx25_revision()); + return 0; } diff --git a/include/soc/imx/revision.h b/include/soc/imx/revision.h index b2a55dafaf0a..b122d2fc8881 100644 --- a/include/soc/imx/revision.h +++ b/include/soc/imx/revision.h @@ -22,6 +22,7 @@ #define IMX_CHIP_REVISION_3_3 0x33 #define IMX_CHIP_REVISION_UNKNOWN 0xff +int mx25_revision(void); int mx27_revision(void); int mx31_revision(void); int mx35_revision(void); From patchwork Wed May 17 15:39:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Kaiser X-Patchwork-Id: 13245226 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id F16A5C77B75 for ; Wed, 17 May 2023 15:41:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=1L+8Ai2Xo5bXYQmGAJN2kPdzCTRFO+ImlD5hfNP4EYY=; b=B+G6mFGrL8Fytc eVp0GF32XevxUXyu4VhOzBUUsZS4P5EpQAuTEGUyZZP9xhXIdU578TRAjJp3sdcDy/Glup2XUXM5v eBM/4PX/Z9JPxxG8y6gQJ46QtvVV37sc8yL5hknh5r8KRKmKlbQVOmd30jRFNFsIwadr9Lx+2Xu1n xnBEgXLn4EmGWtckl9XPR3ZCmpHR/AedUGrzrhSpV4nHvxYKe/+YIRJxyVyOnxbsRGtbxrMO7ItNQ h0TZs6kO8+MmKUxYazoYDdPNNJuZUYXcnLUGoqHxQvk4Ol/Si72lHjy3fl04dhoe7jKt9NpLtfche IQwwqV6tjdsTlRuv6Abw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pzJH7-00AKtF-2B; Wed, 17 May 2023 15:41:13 +0000 Received: from viti.kaiser.cx ([2a01:238:43fe:e600:cd0c:bd4a:7a3:8e9f]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pzJGu-00AKie-20 for linux-arm-kernel@lists.infradead.org; Wed, 17 May 2023 15:41:03 +0000 Received: from ipservice-092-217-095-237.092.217.pools.vodafone-ip.de ([92.217.95.237] helo=martin-debian-2.paytec.ch) by viti.kaiser.cx with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1pzJGj-0004yN-6f; Wed, 17 May 2023 17:40:49 +0200 From: Martin Kaiser To: Abel Vesa , Stephen Boyd Cc: Shawn Guo , Pengutronix Kernel Team , Fabio Estevam , Arnd Bergmann , linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org, Martin Kaiser Subject: [PATCH v5 2/2] clk: imx25: make __mx25_clocks_init return void Date: Wed, 17 May 2023 17:39:32 +0200 Message-Id: <20230517153932.172081-3-martin@kaiser.cx> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20230517153932.172081-1-martin@kaiser.cx> References: <20220815190748.102664-1-martin@kaiser.cx> <20230517153932.172081-1-martin@kaiser.cx> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230517_084100_820635_958290A6 X-CRM114-Status: GOOD ( 11.11 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The __mx25_clocks_init function always returns 0 and its only caller does not check the return value. Let's remove it. Signed-off-by: Martin Kaiser Reviewed-by: Fabio Estevam --- changes in v5: - rebase against today's linux-next changes in v4: - rebase against today's linux-next - add Fabio's Reviewed-by tag changes in v3: - rebase against today's linux-next changes in v2: - send the patch to the clk maintainers drivers/clk/imx/clk-imx25.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/clk/imx/clk-imx25.c b/drivers/clk/imx/clk-imx25.c index bee3da2e21e1..c566be848c2d 100644 --- a/drivers/clk/imx/clk-imx25.c +++ b/drivers/clk/imx/clk-imx25.c @@ -74,7 +74,7 @@ enum mx25_clks { static struct clk *clk[clk_max]; -static int __init __mx25_clocks_init(void __iomem *ccm_base) +static void __init __mx25_clocks_init(void __iomem *ccm_base) { BUG_ON(!ccm_base); @@ -222,8 +222,6 @@ static int __init __mx25_clocks_init(void __iomem *ccm_base) imx_register_uart_clocks(); imx_print_silicon_rev("i.MX25", mx25_revision()); - - return 0; } static void __init mx25_clocks_init_dt(struct device_node *np)