From patchwork Fri Jul 2 22:51:41 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Blumenstingl X-Patchwork-Id: 12356763 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.9 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, UNWANTED_LANGUAGE_BODY,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 31024C07E97 for ; Fri, 2 Jul 2021 22:54:24 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id EC7FA613C0 for ; Fri, 2 Jul 2021 22:54:23 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EC7FA613C0 Authentication-Results: mail.kernel.org; dmarc=fail (p=quarantine dis=none) header.from=googlemail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org 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=hwJ7h5nFrdNZlrfroxjYhFJ/72d0W8UvsRWuwMr3OqQ=; b=2CAzKOXDGidpsC UqIyPOveiFutUv3bJmSHQtf8Y5Op8lMRyAwoPPE90LYLfHxGrIXZtvxPkgNQEDSAuoxv6pNyXPbk4 rIHa4/kY9ALyokRmXP2Egu2kuSgvLCgrlOU+/U+BaeNAu3qnsl0dd+NgoWOy/xSoYHQOt2Mru3S63 QeKbj7KjEP7WvcNKRVjKERLHBaE+mBPT2Ifx93UuBgM0O3hF3IeAmsKsGvUbITdP1c6ZlDHdpiNJV QfUrWFePPx5gESgPu9ZPnf0KQs5POZw0H3c2eMz+loYD9Vu6YGE/UCKCqZqcMARKWxEwPZJkzW4u8 QULTmoS3/U06L1rzgNIA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1lzS1H-004C3g-TK; Fri, 02 Jul 2021 22:52:24 +0000 Received: from mail-ej1-x629.google.com ([2a00:1450:4864:20::629]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1lzS0v-004BzI-RS for linux-arm-kernel@lists.infradead.org; Fri, 02 Jul 2021 22:52:03 +0000 Received: by mail-ej1-x629.google.com with SMTP id ga42so1337629ejc.6 for ; Fri, 02 Jul 2021 15:52:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=8Yd46gkoCwEb4bTGA5aRlP58DFHDPO3UuhUys68/ZC8=; b=bkClNSNE2jrZuxkwQFwvzqYVpbVaVUkuUQfC20fX85VHhdo9i4PbgIHjOP06E+SXJN OV9CdGtHQw0729surn/NPaP5dg4mXUp8lbTxTQ5hJpp7CBp+W7W6L97Fat8zsO3pA4eu u7xtNP6Shb/NKJVto8qDdeI2oa4KNYqTGDVZSolIIxIOfRQC0az+8KeNuW0ziVDdeLPN zX7A33eTJFTS9Q1ubW/6xySa1/ymvqICSENj7NWoBw+Fdc0QclPy1jtPYdTiNikglloD 0L1dyC1G07QqYrOnbHTP0YQ64gVmZP9LZJeN9W/m7akvG0FbcTmU+pJr+OyekcpH5aq0 8uOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=8Yd46gkoCwEb4bTGA5aRlP58DFHDPO3UuhUys68/ZC8=; b=iDRU+ofcIcKdnqdSWJJzDCQWQjKa4Z3AF2oZC+0IR6Y149pkxFmU2l+GAHKmJMJHrV dSjfY3MoJ29juW+Qg/ZQkmCIUTCeiv4EJ3Tl2XtI9/bL0muguCWS1O/uTBFc5svjB+qf so8dwaQRhyawEIHNFrZgSkucV2IV/+iHR1YswpzAFk0JdvB2kbe7OyiNDuAzt4hbLvbF vc2/o4K51qJz8VwMhMU3bUTp09M4/zjXqhB7sUHe0y7f+pRsUZZ4/aOIGd3kpLP/Xg6z wPUkAPA2tzwqtCfF2tcV9FvmjZWGiklSp2QHQ3xq2sq8b6AMa8mmjclB3XOOvaybaEWm VaLA== X-Gm-Message-State: AOAM533gS/BQh9AWks6lz666HC7a0hV0sgZ8rtEFuZtjn1kjGd9ER5GD bqf4d090jwI3mzklvuEw6a0= X-Google-Smtp-Source: ABdhPJyf+1YH/WcpezdktAW8H6mMs6mfjeqZzfgwQ8aed0fcIxRyHYH8d9w3oilIshsRCQSPuOaCYA== X-Received: by 2002:a17:907:72ce:: with SMTP id du14mr2006899ejc.529.1625266320484; Fri, 02 Jul 2021 15:52:00 -0700 (PDT) Received: from localhost.localdomain (dynamic-095-117-063-046.95.117.pool.telefonica.de. [95.117.63.46]) by smtp.googlemail.com with ESMTPSA id r17sm1866964edt.33.2021.07.02.15.51.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 Jul 2021 15:52:00 -0700 (PDT) From: Martin Blumenstingl To: linux-clk@vger.kernel.org, sboyd@kernel.org Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Martin Blumenstingl , Guenter Roeck , Abel Vesa , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team Subject: [PATCH v1 2/6] clk: imx: clk-divider-gate: Switch to clk_divider.determine_rate Date: Sat, 3 Jul 2021 00:51:41 +0200 Message-Id: <20210702225145.2643303-3-martin.blumenstingl@googlemail.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210702225145.2643303-1-martin.blumenstingl@googlemail.com> References: <20210702225145.2643303-1-martin.blumenstingl@googlemail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210702_155201_930160_6B3C0743 X-CRM114-Status: GOOD ( 15.57 ) 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 .determine_rate is meant to replace .round_rate in CCF in the future. Switch over to .determine_rate now that clk_divider_ops has gained support for that. Cc: Guenter Roeck Cc: Abel Vesa Cc: Shawn Guo Cc: Sascha Hauer Cc: Pengutronix Kernel Team Cc: Fabio Estevam Cc: NXP Linux Team Signed-off-by: Martin Blumenstingl Reviewed-by: Abel Vesa --- drivers/clk/imx/clk-divider-gate.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/clk/imx/clk-divider-gate.c b/drivers/clk/imx/clk-divider-gate.c index 0322a843d245..26b210cba9be 100644 --- a/drivers/clk/imx/clk-divider-gate.c +++ b/drivers/clk/imx/clk-divider-gate.c @@ -64,10 +64,10 @@ static unsigned long clk_divider_gate_recalc_rate(struct clk_hw *hw, div->flags, div->width); } -static long clk_divider_round_rate(struct clk_hw *hw, unsigned long rate, - unsigned long *prate) +static int clk_divider_determine_rate(struct clk_hw *hw, + struct clk_rate_request *req) { - return clk_divider_ops.round_rate(hw, rate, prate); + return clk_divider_ops.determine_rate(hw, req); } static int clk_divider_gate_set_rate(struct clk_hw *hw, unsigned long rate, @@ -154,12 +154,12 @@ static int clk_divider_is_enabled(struct clk_hw *hw) static const struct clk_ops clk_divider_gate_ro_ops = { .recalc_rate = clk_divider_gate_recalc_rate_ro, - .round_rate = clk_divider_round_rate, + .determine_rate = clk_divider_determine_rate, }; static const struct clk_ops clk_divider_gate_ops = { .recalc_rate = clk_divider_gate_recalc_rate, - .round_rate = clk_divider_round_rate, + .determine_rate = clk_divider_determine_rate, .set_rate = clk_divider_gate_set_rate, .enable = clk_divider_enable, .disable = clk_divider_disable,