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 A3A99C77B70 for ; Sun, 9 Apr 2023 14:10:59 +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=RnUrMlSoj1UGZAF4nsrE8DGMsLmLP1fHUeMlHKfFym8=; b=TAo51ovl0ukpGR 86bKRwpikQ2rOZ/IZ2LcxEvdoL+rkbdoOWcj7tUoT+9sbjIzZUI52Z9stY7rKk7UKO6nqGrTLijmA 9smWh8bUn9y4wZlIWPwwkbpHZswB+S1RusDgICzXSu8beXmitEWBv3L2WyxidZ65+TOvv1BchPZ4l FKJNz+j9eQnfe8h6scJk71entpgi0oSNnkX/GEE+66xY5q0j1Ry3zVUiYZm+z+ziXyXbL+Q80k4Ze Y390yOFG2l35gl0MLzrGUZf8918ll8ocxzwZO44Mv9ySTf12Qt4fZ4HtLvX6gI+85QVm2Mp+I5OwM FbGe5uqWvFqnHKJfmsqA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1plVkC-00DpMm-2P; Sun, 09 Apr 2023 14:10:12 +0000 Received: from mail-ej1-x634.google.com ([2a00:1450:4864:20::634]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1plVk9-00DpLH-0c for linux-arm-kernel@lists.infradead.org; Sun, 09 Apr 2023 14:10:11 +0000 Received: by mail-ej1-x634.google.com with SMTP id jg21so6730193ejc.2 for ; Sun, 09 Apr 2023 07:10:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1681049407; x=1683641407; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=ZWbSgDAMrUeTkTzdxf9kU0BiKTq0gFmqjxzx/mV1DIw=; b=alYRDzBJPwrBHZrEu0HcZ91ApEGoV3F2G5nwHhhCxnJ8HyVJU6BJxHxz5WIA99GAnA bYuCnz2vuRVrrYFtH79igaOE4hGZVcCi+fH2p/k5zW6PeHtDH31/miKV6+G7tVufp0je ZrkYVQy2BfTF8TbxzgJX60HNB86Y/nITNv6KlwJKeongYNIfJMgzQkxFwv/pvXrWclXo uxd69e05kYFztF/OAJ87i+AvNclSOvPgik/cDG5EKsu2PvGO5NhYDPqiZVoDxkpx6mHX sCYrfq5HUjvKmiTFVU+g7XSndF8Y/eUfqgCb9LmLBQKwXXlQs5CuPn+joMK7bn91HCxm NO2A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1681049407; x=1683641407; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=ZWbSgDAMrUeTkTzdxf9kU0BiKTq0gFmqjxzx/mV1DIw=; b=xC/QYmN7QdFZTpQ+8XjFNRyUIIWP8LXOzr+r24xoSr5ptpAOQceAkQH5psOEBURYpi D2ir6Fh6GzrlWGDQrwo5cI1avJ/MkF1YLobBu3a4cREeQgt8TTbu65UA8Nx2BigClCdO bMrKDeUgl0yRMUreb8PrR2AFpQGzeg0ApjiNOq5HCjEAPtoKw8ttod20x8TR+npeEwXv 6ZCasjHk/FgpWj7p79vgexMTpD5sKCj+7sHAyph2tgHl6B7i3g0gb6TfP7LrG+/Td/px rCkrlbiSizEpFWiVcusXGl8XoZxDNxnhkYxx7zrq6/ydsTt1er5PCTK5wnNQ3bseL7Nx iK5Q== X-Gm-Message-State: AAQBX9dEP0NnnTae0ODo3xTmqhjsspmH7x9JGKmOyXuqgn/wvQpLZigl /O5PbFL5DWwnznODD0EkgEFV3w== X-Google-Smtp-Source: AKy350Y1zIEy1rT6IrUrOwyD2k63RPhd4SZJVjljukrdlVWpu3vQcRHQ7OeLaRDxLuRMPsJlvy2YzQ== X-Received: by 2002:a17:906:1c08:b0:932:a14e:4c57 with SMTP id k8-20020a1709061c0800b00932a14e4c57mr4477602ejg.76.1681049407595; Sun, 09 Apr 2023 07:10:07 -0700 (PDT) Received: from linaro.org ([188.25.26.161]) by smtp.gmail.com with ESMTPSA id ho11-20020a1709070e8b00b0093ebc654f78sm4163881ejc.25.2023.04.09.07.10.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 09 Apr 2023 07:10:07 -0700 (PDT) Date: Sun, 9 Apr 2023 17:10:05 +0300 From: Abel Vesa To: "Peng Fan (OSS)" Cc: abelvesa@kernel.org, mturquette@baylibre.com, sboyd@kernel.org, shawnguo@kernel.org, s.hauer@pengutronix.de, kernel@pengutronix.de, festevam@gmail.com, linux-imx@nxp.com, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Jacky Bai , Peng Fan Subject: Re: [PATCH 4/5] clk: imx: imx8ulp: Add tpm5 clock as critical gate clock Message-ID: References: <20230331063814.2462059-1-peng.fan@oss.nxp.com> <20230331063814.2462059-5-peng.fan@oss.nxp.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20230331063814.2462059-5-peng.fan@oss.nxp.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230409_071009_230308_6FC39F27 X-CRM114-Status: GOOD ( 21.82 ) 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 23-03-31 14:38:13, Peng Fan (OSS) wrote: > From: Jacky Bai > > The TPM5 is used for broadcast timer purpose and registered > with TIMER_OF_DECLARE. As the clock driver is not ready at > that stage, so the TPM5 clock is configured in bootloader(TF-A). > if we just remove the TPM5 clock from linux will introduce a > risk that the TPM5's parent clock will be gated, then lead to > TPM's channel control config can NOT be written into register > successfully. > > Due to the above reason, we still need to add the TPM5 clock > into linux clock but register it as a simple critical gate > clock to make sure its parent is always on. > > Reviewed-by: Peng Fan > Signed-off-by: Jacky Bai > Signed-off-by: Peng Fan Reviewed-by: Abel Vesa > --- > drivers/clk/imx/clk-imx8ulp.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/clk/imx/clk-imx8ulp.c b/drivers/clk/imx/clk-imx8ulp.c > index 0dd48e8159ee..6a8a9e50d826 100644 > --- a/drivers/clk/imx/clk-imx8ulp.c > +++ b/drivers/clk/imx/clk-imx8ulp.c > @@ -333,7 +333,6 @@ static int imx8ulp_clk_pcc3_init(struct platform_device *pdev) > clks[IMX8ULP_CLK_WDOG4] = imx8ulp_clk_hw_composite("wdog4", pcc3_periph_bus_sels, ARRAY_SIZE(pcc3_periph_bus_sels), true, true, true, base + 0xac, 1); > clks[IMX8ULP_CLK_LPIT1] = imx8ulp_clk_hw_composite("lpit1", pcc3_periph_bus_sels, ARRAY_SIZE(pcc3_periph_bus_sels), true, true, true, base + 0xc8, 1); > clks[IMX8ULP_CLK_TPM4] = imx8ulp_clk_hw_composite("tpm4", pcc3_periph_bus_sels, ARRAY_SIZE(pcc3_periph_bus_sels), true, true, true, base + 0xcc, 1); > - clks[IMX8ULP_CLK_TPM5] = imx8ulp_clk_hw_composite("tpm5", pcc3_periph_bus_sels, ARRAY_SIZE(pcc3_periph_bus_sels), true, true, true, base + 0xd0, 1); > clks[IMX8ULP_CLK_FLEXIO1] = imx8ulp_clk_hw_composite("flexio1", pcc3_periph_bus_sels, ARRAY_SIZE(pcc3_periph_bus_sels), true, true, true, base + 0xd4, 1); > clks[IMX8ULP_CLK_I3C2] = imx8ulp_clk_hw_composite("i3c2", pcc3_periph_bus_sels, ARRAY_SIZE(pcc3_periph_bus_sels), true, true, true, base + 0xd8, 1); > clks[IMX8ULP_CLK_LPI2C4] = imx8ulp_clk_hw_composite("lpi2c4", pcc3_periph_bus_sels, ARRAY_SIZE(pcc3_periph_bus_sels), true, true, true, base + 0xdc, 1); > @@ -378,6 +377,7 @@ static int imx8ulp_clk_pcc3_init(struct platform_device *pdev) > clks[IMX8ULP_CLK_DMA1_CH31] = imx_clk_hw_gate("pcc_dma1_ch31", "xbar_ad_divplat", base + 0x84, 30); > clks[IMX8ULP_CLK_MU0_B] = imx_clk_hw_gate_flags("mu0_b", "xbar_ad_divplat", base + 0x88, 30, CLK_IS_CRITICAL); > clks[IMX8ULP_CLK_MU3_A] = imx_clk_hw_gate("mu3_a", "xbar_ad_divplat", base + 0x8c, 30); > + clks[IMX8ULP_CLK_TPM5] = imx_clk_hw_gate_flags("tpm5", "sosc_div2", base + 0xd0, 30, CLK_IS_CRITICAL); > > imx_check_clk_hws(clks, clk_data->num); > > -- > 2.37.1 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel