From mboxrd@z Thu Jan 1 00:00:00 1970 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 96BBBC25B0E for ; Mon, 15 Aug 2022 09:12:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241597AbiHOJMk (ORCPT ); Mon, 15 Aug 2022 05:12:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38124 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241885AbiHOJMi (ORCPT ); Mon, 15 Aug 2022 05:12:38 -0400 Received: from mail-wr1-x435.google.com (mail-wr1-x435.google.com [IPv6:2a00:1450:4864:20::435]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 026EA220D2 for ; Mon, 15 Aug 2022 02:12:37 -0700 (PDT) Received: by mail-wr1-x435.google.com with SMTP id h13so8362399wrf.6 for ; Mon, 15 Aug 2022 02:12:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc; bh=mZGNEIa1pqWi28sYb3bc4F38nKBbuQz26ll0NQAydIc=; b=VhLb3fH+gl+hRv8bCbnX9IKPW+Z4faV4V6Ta2OZT+8e/NlnviwsfWIcwQaPbz5lldW EcXJyhqjJHrT1YRTYnn6yar+BRSHvON/LyFf4cwvV8skNiKHl8KOq8nAkOofCnUfJtHl fCx3gr52DU8RXMCJX8iEjwDR9jpIMkjqtE+nxm46NCuluM59G1d4UeBQAvYy0c5O9abe r1+CZalq6T3OI67sUotRCxM68nhDxvNMKle/X7APXs+ERgk2NIiK926XrXaG9kL7wpAt p7aTH9lCAekFv7+rcYA0Jalnf3TvwuNXkKVKJV4zj2XpNBqUXZp6c2yyQW6Om2duSXz7 3i1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc; bh=mZGNEIa1pqWi28sYb3bc4F38nKBbuQz26ll0NQAydIc=; b=61X0C8WfYDtWHzv78kn0iohkhYoS/nJfQqYYyInjysykQpKxvZFAMR4/8yMzn4Tc3X IW5GAIFNmcv9mgFOXxf2mT+27abb3hPRg6pH0UaQurLRGfcZOIEFGBjLcyrZz6idVP86 vPMn+J1jyc32SrK2WC0L7Cy95b0yF+M5L0puZGAUiaZpLoOsEIM4x1i/7nXObxGa6YEa 2ffP7LlPLgIZjAvahsLgkY3qDIyh4o19eARiaywgozcd+JIWcNH/Wc0mf5jLLQ5at3xe vkkju6jPce1OyjWutz/nR/NQp2CsXCxJ1PgyOvkV+XRyg0XYekdvPQXNZ7qGsYjIj/4F WZGg== X-Gm-Message-State: ACgBeo3w5xi1frZfkcj4nAuqlF8DTAVIqY5MImg/eRUUzNZVe2JP9k/h PmIeJUNsFjnqh0QzalOl4XPfFw== X-Google-Smtp-Source: AA6agR5eXQemuYfviMG9u2GM6Erb8/7KMsoyHCidkfaSXGw3KPxNvEbaJ+VcyGH4MM8tz9h/JWb8VA== X-Received: by 2002:adf:fd4f:0:b0:220:60bc:3fc9 with SMTP id h15-20020adffd4f000000b0022060bc3fc9mr8217875wrs.398.1660554755381; Mon, 15 Aug 2022 02:12:35 -0700 (PDT) Received: from linaro.org ([94.52.112.99]) by smtp.gmail.com with ESMTPSA id b5-20020adff905000000b002205ffe88edsm6705381wrr.31.2022.08.15.02.12.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 15 Aug 2022 02:12:34 -0700 (PDT) Date: Mon, 15 Aug 2022 12:12:33 +0300 From: Abel Vesa To: "Peng Fan (OSS)" Cc: robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, shawnguo@kernel.org, s.hauer@pengutronix.de, abelvesa@kernel.org, mturquette@baylibre.com, sboyd@kernel.org, kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, Peng Fan Subject: Re: [PATCH V2 8/8] clk: imx93: add SAI IPG clk Message-ID: References: <20220815013039.474970-1-peng.fan@oss.nxp.com> <20220815013039.474970-9-peng.fan@oss.nxp.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220815013039.474970-9-peng.fan@oss.nxp.com> Precedence: bulk List-ID: X-Mailing-List: linux-clk@vger.kernel.org On 22-08-15 09:30:39, Peng Fan (OSS) wrote: > From: Peng Fan > > The clk topology is as below: > bus_aon_root------>\ /--->SAI IPG > -->SAI LPCG gate--> > sai[x]_clk_root--->/ \--->SAI MCLK > > So use shared count as i.MX93 MU_B gate. > > Signed-off-by: Peng Fan Reviewed-by: Abel Vesa > --- > drivers/clk/imx/clk-imx93.c | 12 +++++++++--- > 1 file changed, 9 insertions(+), 3 deletions(-) > > diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c > index 4008ab075dfe..6a76b9fdf18d 100644 > --- a/drivers/clk/imx/clk-imx93.c > +++ b/drivers/clk/imx/clk-imx93.c > @@ -28,6 +28,9 @@ enum clk_sel { > MAX_SEL > }; > > +static u32 share_count_sai1; > +static u32 share_count_sai2; > +static u32 share_count_sai3; > static u32 share_count_mub; > > static const char *parent_names[MAX_SEL][4] = { > @@ -215,9 +218,12 @@ static const struct imx93_clk_ccgr { > { IMX93_CLK_USDHC1_GATE, "usdhc1", "usdhc1_root", 0x9380, }, > { IMX93_CLK_USDHC2_GATE, "usdhc2", "usdhc2_root", 0x93c0, }, > { IMX93_CLK_USDHC3_GATE, "usdhc3", "usdhc3_root", 0x9400, }, > - { IMX93_CLK_SAI1_GATE, "sai1", "sai1_root", 0x9440, }, > - { IMX93_CLK_SAI2_GATE, "sai2", "sai2_root", 0x9480, }, > - { IMX93_CLK_SAI3_GATE, "sai3", "sai3_root", 0x94c0, }, > + { IMX93_CLK_SAI1_GATE, "sai1", "sai1_root", 0x9440, 0, &share_count_sai1}, > + { IMX93_CLK_SAI1_IPG, "sai1_ipg_clk", "bus_aon_root", 0x9440, 0, &share_count_sai1}, > + { IMX93_CLK_SAI2_GATE, "sai2", "sai2_root", 0x9480, 0, &share_count_sai2}, > + { IMX93_CLK_SAI2_IPG, "sai2_ipg_clk", "bus_wakeup_root", 0x9480, 0, &share_count_sai2}, > + { IMX93_CLK_SAI3_GATE, "sai3", "sai3_root", 0x94c0, 0, &share_count_sai3}, > + { IMX93_CLK_SAI3_IPG, "sai3_ipg_clk", "bus_wakeup_root", 0x94c0, 0, &share_count_sai3}, > { IMX93_CLK_MIPI_CSI_GATE, "mipi_csi", "media_apb_root", 0x9580, }, > { IMX93_CLK_MIPI_DSI_GATE, "mipi_dsi", "media_apb_root", 0x95c0, }, > { IMX93_CLK_LVDS_GATE, "lvds", "media_ldb_root", 0x9600, }, > -- > 2.37.1 > From mboxrd@z Thu Jan 1 00:00:00 1970 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 C22DBC00140 for ; Mon, 15 Aug 2022 09:35:53 +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:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=wy69taE7ffnh2U1uMINqSPxPEXPB65IkMPr9j+12uJo=; b=lGd9ivAO6bYYTi 0/tgUXKxzKdHCRrGc4Z//HiaGpMKz1L1t9LIHZWplOZdhkpBNdFYfIXJ6jVVgFy3yGQ/2GXzBOmWr YMt/N8fAMaEDIzD5QDVt193pqqikKnMGYuTGxyvrVSOxGwlwn8KBy536hF72OulsDNF2xXBDd2fdJ Rq/8XN4CkUYJC/k6uAp9mXHBOCNgjYxaKxgRGxYkuNRRmzTdlaBFCQkdFnoGqN9QrIWy20V8na4pv oKaYSesHTsOAri5DNponfiieDnM7wRg+0BSaK7Ijsu7OlFphPWCZQL28pk9PvIsOvnq+Dzs2ziZUq j9xdVyQJmltY2WBF92NA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oNWUe-00DvCy-G1; Mon, 15 Aug 2022 09:34:44 +0000 Received: from mail-wr1-x431.google.com ([2a00:1450:4864:20::431]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oNW9H-00Df5r-Ep for linux-arm-kernel@lists.infradead.org; Mon, 15 Aug 2022 09:13:25 +0000 Received: by mail-wr1-x431.google.com with SMTP id bs25so8378576wrb.2 for ; Mon, 15 Aug 2022 02:12:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc; bh=mZGNEIa1pqWi28sYb3bc4F38nKBbuQz26ll0NQAydIc=; b=VhLb3fH+gl+hRv8bCbnX9IKPW+Z4faV4V6Ta2OZT+8e/NlnviwsfWIcwQaPbz5lldW EcXJyhqjJHrT1YRTYnn6yar+BRSHvON/LyFf4cwvV8skNiKHl8KOq8nAkOofCnUfJtHl fCx3gr52DU8RXMCJX8iEjwDR9jpIMkjqtE+nxm46NCuluM59G1d4UeBQAvYy0c5O9abe r1+CZalq6T3OI67sUotRCxM68nhDxvNMKle/X7APXs+ERgk2NIiK926XrXaG9kL7wpAt p7aTH9lCAekFv7+rcYA0Jalnf3TvwuNXkKVKJV4zj2XpNBqUXZp6c2yyQW6Om2duSXz7 3i1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc; bh=mZGNEIa1pqWi28sYb3bc4F38nKBbuQz26ll0NQAydIc=; b=HarVrupsGG9nEKXvcE2KpDUZXMbjj0IrMQexGUKqNCEcH44HP7nGd928fU9ZBYId9e PX28ugWWVBTK48wGQ7EFLN2TRDUUr/OGK5B1gTDf4jIAwV297TIE/zcFjWnUvOHIs5cS Yd2j7XzcyyJnH5XTf/POON/StAImzwnTdK3LLvotZN5mhLVry4iuVkgfoktuBsQlAr1x igLKNchSnteOJmXUTzXF9QYbRG5gG7r0P0WMSpAT6q3kkEP0FYbgmvmQh3ZvRizVMM5w UK3H8aQg7X5sUaTkRomLLSTnX3Di7gRoWWZc8F4HBGIJy77nT0WUs/J8t8iCCek0ywDf ZNzA== X-Gm-Message-State: ACgBeo1vhuOQ/Mzm1XY5TiH0oTboHekZISRSI1v8sQqusz9CApNDXcda B99lbD5ZEEEajhgdGoUFC81GDA== X-Google-Smtp-Source: AA6agR5eXQemuYfviMG9u2GM6Erb8/7KMsoyHCidkfaSXGw3KPxNvEbaJ+VcyGH4MM8tz9h/JWb8VA== X-Received: by 2002:adf:fd4f:0:b0:220:60bc:3fc9 with SMTP id h15-20020adffd4f000000b0022060bc3fc9mr8217875wrs.398.1660554755381; Mon, 15 Aug 2022 02:12:35 -0700 (PDT) Received: from linaro.org ([94.52.112.99]) by smtp.gmail.com with ESMTPSA id b5-20020adff905000000b002205ffe88edsm6705381wrr.31.2022.08.15.02.12.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 15 Aug 2022 02:12:34 -0700 (PDT) Date: Mon, 15 Aug 2022 12:12:33 +0300 From: Abel Vesa To: "Peng Fan (OSS)" Cc: robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, shawnguo@kernel.org, s.hauer@pengutronix.de, abelvesa@kernel.org, mturquette@baylibre.com, sboyd@kernel.org, kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, Peng Fan Subject: Re: [PATCH V2 8/8] clk: imx93: add SAI IPG clk Message-ID: References: <20220815013039.474970-1-peng.fan@oss.nxp.com> <20220815013039.474970-9-peng.fan@oss.nxp.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20220815013039.474970-9-peng.fan@oss.nxp.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220815_021239_756850_DEF50159 X-CRM114-Status: GOOD ( 15.75 ) 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: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 22-08-15 09:30:39, Peng Fan (OSS) wrote: > From: Peng Fan > > The clk topology is as below: > bus_aon_root------>\ /--->SAI IPG > -->SAI LPCG gate--> > sai[x]_clk_root--->/ \--->SAI MCLK > > So use shared count as i.MX93 MU_B gate. > > Signed-off-by: Peng Fan Reviewed-by: Abel Vesa > --- > drivers/clk/imx/clk-imx93.c | 12 +++++++++--- > 1 file changed, 9 insertions(+), 3 deletions(-) > > diff --git a/drivers/clk/imx/clk-imx93.c b/drivers/clk/imx/clk-imx93.c > index 4008ab075dfe..6a76b9fdf18d 100644 > --- a/drivers/clk/imx/clk-imx93.c > +++ b/drivers/clk/imx/clk-imx93.c > @@ -28,6 +28,9 @@ enum clk_sel { > MAX_SEL > }; > > +static u32 share_count_sai1; > +static u32 share_count_sai2; > +static u32 share_count_sai3; > static u32 share_count_mub; > > static const char *parent_names[MAX_SEL][4] = { > @@ -215,9 +218,12 @@ static const struct imx93_clk_ccgr { > { IMX93_CLK_USDHC1_GATE, "usdhc1", "usdhc1_root", 0x9380, }, > { IMX93_CLK_USDHC2_GATE, "usdhc2", "usdhc2_root", 0x93c0, }, > { IMX93_CLK_USDHC3_GATE, "usdhc3", "usdhc3_root", 0x9400, }, > - { IMX93_CLK_SAI1_GATE, "sai1", "sai1_root", 0x9440, }, > - { IMX93_CLK_SAI2_GATE, "sai2", "sai2_root", 0x9480, }, > - { IMX93_CLK_SAI3_GATE, "sai3", "sai3_root", 0x94c0, }, > + { IMX93_CLK_SAI1_GATE, "sai1", "sai1_root", 0x9440, 0, &share_count_sai1}, > + { IMX93_CLK_SAI1_IPG, "sai1_ipg_clk", "bus_aon_root", 0x9440, 0, &share_count_sai1}, > + { IMX93_CLK_SAI2_GATE, "sai2", "sai2_root", 0x9480, 0, &share_count_sai2}, > + { IMX93_CLK_SAI2_IPG, "sai2_ipg_clk", "bus_wakeup_root", 0x9480, 0, &share_count_sai2}, > + { IMX93_CLK_SAI3_GATE, "sai3", "sai3_root", 0x94c0, 0, &share_count_sai3}, > + { IMX93_CLK_SAI3_IPG, "sai3_ipg_clk", "bus_wakeup_root", 0x94c0, 0, &share_count_sai3}, > { IMX93_CLK_MIPI_CSI_GATE, "mipi_csi", "media_apb_root", 0x9580, }, > { IMX93_CLK_MIPI_DSI_GATE, "mipi_dsi", "media_apb_root", 0x95c0, }, > { IMX93_CLK_LVDS_GATE, "lvds", "media_ldb_root", 0x9600, }, > -- > 2.37.1 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel