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 6FAA2C27C76 for ; Wed, 25 Jan 2023 20:55:36 +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:Date:To:Cc:From:Subject:References: In-Reply-To:MIME-Version:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=3Mi+I56CcdO4kd8BOldmnq6bRR3WQhwy0ZN30eDAi6Q=; b=ydo7A/UqZOypU0 XzO2Yax2ZdLzf3UxXRj21afzypJu4ziuT/+fBbdZ6PwVUa1cKfEdoGiHfGAJjBZ7HFcmfHYCWT+Ll VqmMOQ6NIjKxwm62ls8oQrkzQf/+YAEwEsaxIndHYjfk4fplaOONR2jSkrz8XzRJtIPK/pfdN4GyJ 2No9nlzQ1FdKFz9P4g5rUxglxIE8yueAdjAX7llx5MoYcm3kRG/+ZziWkBN3ZLXoSu78vfX2FL69g ey52eARg8weNd9qqwm3qbSVpGVBKEdzqITTFdm0DuW5UuXAyou9xsJ2783aUc36NCnTkmHE2BOJx4 oHMFkxvZbwbTL1ya2B+g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pKmn6-008lnY-5o; Wed, 25 Jan 2023 20:54:44 +0000 Received: from dfw.source.kernel.org ([2604:1380:4641:c500::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pKmn3-008lmg-El for linux-arm-kernel@lists.infradead.org; Wed, 25 Jan 2023 20:54:42 +0000 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 C10D261629; Wed, 25 Jan 2023 20:54:40 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1B378C433EF; Wed, 25 Jan 2023 20:54:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1674680080; bh=jLzNKjyc09opMzRxjkf1IrKwt5abM/dWPoSM+2ilEkk=; h=In-Reply-To:References:Subject:From:Cc:To:Date:From; b=X/uDu3O5qXsiTWl6cqsmS+r3tM9PmmYl/gFX19wihE3gUQssRRRgZbXD/YR3Wiuqk IDIOALPim0r8rA8sD99J+rL7RbcPKZHAqIShXKxxm20xyRARghupyDkZFnTF07p1Gg x7JmCz7CT4EIbHToFXV/QEnk9aW3XzDnctemrD8C8d8lnlSF1y1AqY+DD2bTM9EgjZ rLyHtU7lgSfEPSlueZesJyGbxtnJb3D59IZqPaa13fq5yleqo56ZMgQQGZL92OPVOb PcN24IDwrkFTwLT+82hERv8tlcCyzyaPZzORg8i4LHKihykE/jVpLlPgqmGxZ0UHeE 1KCji5hDKRu5Q== Message-ID: <9cf8a94f7ec4d8912bcf507631991999.sboyd@kernel.org> MIME-Version: 1.0 In-Reply-To: <20230125104520.89684-6-quic_kathirav@quicinc.com> References: <20230125104520.89684-1-quic_kathirav@quicinc.com> <20230125104520.89684-6-quic_kathirav@quicinc.com> Subject: Re: [PATCH 05/10] clk: qcom: add Global Clock controller (GCC) driver for IPQ5332 SoC From: Stephen Boyd Cc: Kathiravan T To: Kathiravan Thirumoorthy , agross@kernel.org, andersson@kernel.org, arnd@arndb.de, bhupesh.sharma@linaro.org, broonie@kernel.org, catalin.marinas@arm.com, devicetree@vger.kernel.org, dmitry.baryshkov@linaro.org, konrad.dybcio@linaro.org, krzysztof.kozlowski+dt@linaro.org, linus.walleij@linaro.org, linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, linux-clk@vger.kernel.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mmc@vger.kernel.org, marcel.ziswiler@toradex.com, mturquette@baylibre.com, nfraprado@collabora.com, quic_gurus@quicinc.com, robh+dt@kernel.org, robimarko@gmail.com, shawnguo@kernel.org, ulf.hansson@linaro.org, will@kernel.org Date: Wed, 25 Jan 2023 12:54:37 -0800 User-Agent: alot/0.10 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230125_125441_553423_F9787D4F X-CRM114-Status: GOOD ( 14.27 ) 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 Quoting Kathiravan Thirumoorthy (2023-01-25 02:45:15) > diff --git a/drivers/clk/qcom/gcc-ipq5332.c b/drivers/clk/qcom/gcc-ipq5332.c > new file mode 100644 > index 000000000000..8351096a4d32 > --- /dev/null > +++ b/drivers/clk/qcom/gcc-ipq5332.c > @@ -0,0 +1,3954 @@ > +// SPDX-License-Identifier: GPL-2.0-only > +/* > + * Copyright (c) 2022-2023 Qualcomm Innovation Center, Inc. All rights reserved. > + */ > + > +#include > +#include > +#include > +#include [...] > + > +static const struct freq_tbl ftbl_gcc_pcnoc_bfdcd_clk_src[] = { > + F(24000000, P_XO, 1, 0, 0), > + F(50000000, P_GPLL0_OUT_MAIN, 16, 0, 0), > + F(100000000, P_GPLL0_OUT_MAIN, 8, 0, 0), > + { } > +}; > + > +static struct clk_rcg2 gcc_pcnoc_bfdcd_clk_src = { > + .cmd_rcgr = 0x31004, > + .mnd_width = 0, > + .hid_width = 5, > + .parent_map = gcc_parent_map_0, > + .freq_tbl = ftbl_gcc_pcnoc_bfdcd_clk_src, > + .clkr.hw.init = &(const struct clk_init_data){ > + .name = "gcc_pcnoc_bfdcd_clk_src", > + .parent_data = gcc_parent_data_0, > + .num_parents = ARRAY_SIZE(gcc_parent_data_0), > + .ops = &clk_rcg2_ops, > + .flags = CLK_IS_CRITICAL, Why not just turn these clks on in probe and never register them with the framework? That saves some memory for clks that there is no desire to control from linux. This is an RCG, so in theory the frequency can change, but does it really? Usually bus clks are controlled by the interconnect driver. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel