Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751829AbdHAKOS (ORCPT ); Tue, 1 Aug 2017 06:14:18 -0400 Received: from mailout1.samsung.com ([203.254.224.24]:29421 "EHLO mailout1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751571AbdHAKOQ (ORCPT ); Tue, 1 Aug 2017 06:14:16 -0400 X-AuditID: b6c32a38-f799e6d000004f48-9f-598054744a6d Subject: Re: [PATCH] clk: samsung: exynos5420: The EPLL rate table corrections To: Stephen Boyd Cc: mturquette@baylibre.com, cw00.choi@samsung.com, krzk@kernel.org, linux-samsung-soc@vger.kernel.org, linux-clk@vger.kernel.org, b.zolnierkie@samsung.com, linux-kernel@vger.kernel.org From: Sylwester Nawrocki Message-id: <819c4977-bc4d-38e1-07e0-4f1a620ab3b5@samsung.com> Date: Tue, 01 Aug 2017 12:14:07 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-version: 1.0 In-reply-to: <20170731201701.GI2146@codeaurora.org> Content-type: text/plain; charset="utf-8"; format="flowed" Content-language: en-GB Content-transfer-encoding: 7bit X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrPKsWRmVeSWpSXmKPExsWy7bCmgW5JSEOkQfMvS4uNM9azWlz/8pzV 4vz5DewWH3vusVpc3jWHzWLG+X1MFhdPuVr8ONPN4sDh8f5GK7vH5b5eJo9NqzrZPPq2rGL0 +LxJLoA1issmJTUnsyy1SN8ugStjyacpzAXPOSu6njxlbWD8yd7FyMkhIWAi0XB+BTOELSZx 4d56NhBbSGAHo8SDR3VdjFxA9mdGiY+/zjLBNBzpfcMOkQAqunt4OhuEc59R4kDnZcYuRg4O YYEAiS/bS0AaRATUJb7vOAlWwyywl1FiyWmIdWwChhK9R/sYQWxeATuJ1ZM2gp3EIqAqcfXr TrAaUYEIiW3fZ7BB1AhK/Jh8jwXE5hQwlli56w7YRcwCVhLP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bnpucVGBYZ6xYm5xaV56XrJ+bmbGIHRue2wlv8Oxh9now8xCnAwKvHwdog1RAqxJpYV V+YeYpTgYFYS4a10BwrxpiRWVqUW5ccXleakFh9iNAV6byKzlGhyPjBx5JXEG5pYGpkYmJkZ GhkYmymJ804I/BIhJJCeWJKanZpakFoE08fEwSnVwOh6LuWJcOJvPk2VAI5pUy9/zD21r9Si 6ETz7iM3o1J70tbMatH/cHf7xtwbt9fdr/1398Sd4ifJwhf7lfbP3sb55emDM+HCKadKH1W/ lDh0fIvpXf/ZU7/pJVg/tlgr/bz9u7uzk9EaNo2Ns7clv7LOurAqhbXv0gX3Y/F8wrO3iWbz TZh3pOmDEktxRqKhFnNRcSIAQE4XbuQCAAA= X-MTR: 20000000000000000@CPGS X-CMS-MailID: 20170801101412epcas1p3e673b6ffec5e79ce0af794ed4cc16758 X-Msg-Generator: CA X-Sender-IP: 182.195.42.79 X-Local-Sender: =?UTF-8?B?U3lsd2VzdGVyIE5hd3JvY2tpG1NSUE9MLUtlcm5lbCAoVFAp?= =?UTF-8?B?G+yCvOyEseyghOyekBtTZW5pb3IgU29mdHdhcmUgRW5naW5lZXI=?= X-Global-Sender: =?UTF-8?B?U3lsd2VzdGVyIE5hd3JvY2tpG1NSUE9MLUtlcm5lbCAoVFAp?= =?UTF-8?B?G1NhbXN1bmcgRWxlY3Ryb25pY3MbU2VuaW9yIFNvZnR3YXJlIEVuZ2luZWVy?= X-Sender-Code: =?UTF-8?B?QzEwG0VIURtDMTBDRDAyQ0QwMjczOTI=?= CMS-TYPE: 101P X-CMS-RootMailID: 20170721112008epcas5p1eb75e4eb00d1dbad130460d2cbc0ce0c X-RootMTR: 20170721112008epcas5p1eb75e4eb00d1dbad130460d2cbc0ce0c References: <1500635990-19474-1-git-send-email-s.nawrocki@samsung.com> <33f53903-9043-29c0-2cb8-e5d6950cc92f@samsung.com> <20170731201701.GI2146@codeaurora.org> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1221 Lines: 34 On 07/31/2017 10:17 PM, Stephen Boyd wrote: > On 07/31, Sylwester Nawrocki wrote: >> On 07/21/2017 01:19 PM, Sylwester Nawrocki wrote: >>> This patch fixes values of the EPLL K coefficient and changes >>> the EPLL output frequency values to match exactly what is >>> possible to achieve with given M, P, S, K coefficients. >>> This allows to avoid rounding errors and unexpected frequency >>> being set with clk_set_rate(), due to recalc_rate returning >>> different values than the PLL rate specified in the >>> exynos5420_epll_24mhz_tbl table. E.g. this prevents a case >>> where two consecutive clk_set_rate() calls with same argument >>> result in different PLL output frequency. >>> >>> The PLL output frequencies have been calculated with formula: >>> >>> f = fxtal * (M * 2^16 + K) / (P * 2^S) / 2^16 >>> >>> where fxtal = 24000000. >>> >>> Fixes: 9842452acd ("clk: samsung: exynos542x: Add EPLL rate table") >>> Signed-off-by: Sylwester Nawrocki >> Stephen, Mike, >> >> Could you apply this patch directly for v4.12-rcX? >> It fixes code added in v4.12. >> > You mean v4.13? Sure. Yes, apologies for confusing these numbers. Thanks for taking care of the patch. -- Regards, Sylwester