From patchwork Thu Jan 18 18:45:23 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Brunet X-Patchwork-Id: 125010 Delivered-To: patch@linaro.org Received: by 10.46.64.27 with SMTP id n27csp247773lja; Thu, 18 Jan 2018 10:47:24 -0800 (PST) X-Google-Smtp-Source: ACJfBosrMTxvyXRsIoGznXUeuzyZGsyHcV+KacaC+n6R8NKJHO8/rX+kveUi8zq3bq3rVfL06sr8 X-Received: by 10.101.98.85 with SMTP id q21mr8168875pgv.298.1516301243960; Thu, 18 Jan 2018 10:47:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516301243; cv=none; d=google.com; s=arc-20160816; b=TCj0m86izRZxJbcT6ofc7s7ySLRl38EyLN0MrSaRKYsPnifw5qno7gfaEUEshLp6e1 mHCgG1xHNarEOK0o7dTlcmwOdog8ln1yme0ceAjtBzwwqCWWl0Z/6qaaptmWfIxKwFXM 1+XC7JPIwNFFrixVNsOMbzbvKKvwKU+oRR/rFN7yd5Co4yuH2lPcPsdXxUQj14hv2e0X hZz29MPuMXXDNwtk8aRyOkB04POWU9oj224dWUx5qFv7E6/SZiiaw5pQbbJEegCjXM8p YIUYEJlLkvmRbyDWDSCLA/2tP30gjrzrPHx/h6azJGXKhQRwi9Zhcaw0qoScAKh/+03R Zphg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=0Qik2rbTJeSTnxUAV8QCOzX4fgh8aFGRH72XwRCfrXU=; b=Ve42ZbSIF5xslkD8UktQwHCcgK3Mc180qwGbdOv3nQ1/feF4v8Ow7Yee8vA1R4pZzh ucyoghcI5IF4ZPYlRx+qXWbhOXM8bfd43bLcVugA4HyyqtyhAUrK5sho96wcwSBAnd/i 2pjc7/D/uHQVJngAalZDpPu7lEJPESrrtwyfyUFWwojMCWbmycj4eyO8G3KYcZIUEQu0 gJO4p4Nocfbm32Me2/Elxy4unHOFZwaKoKGTPueuJbLQwBq+UvzA0dh6xztYt/DqSZRd V3pG58MMgqpn7CzITAVK2TNPLr2w+/sFFYgP74nSOoYgdoz42aP3cxdQTRoBYuK/M9os 4suA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=A/7c6FSO; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x10si6665263pgc.192.2018.01.18.10.47.23; Thu, 18 Jan 2018 10:47:23 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=A/7c6FSO; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755775AbeARSpj (ORCPT + 28 others); Thu, 18 Jan 2018 13:45:39 -0500 Received: from mail-wm0-f65.google.com ([74.125.82.65]:34043 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755003AbeARSpg (ORCPT ); Thu, 18 Jan 2018 13:45:36 -0500 Received: by mail-wm0-f65.google.com with SMTP id 81so4000705wmb.1 for ; Thu, 18 Jan 2018 10:45:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=0Qik2rbTJeSTnxUAV8QCOzX4fgh8aFGRH72XwRCfrXU=; b=A/7c6FSOV0/9Ih1805r8u0vVsBDgATP7YaVArXr186Peyj0isKYxpzO1ceW+9V+bDU 9PU3dF876hD3mWdu3xH0PE2qgLzQdSiVTlOKx6btOTMLG0k1gT8T0W5eqLVs4SSvPf/F 9WWqprhY5+Mb4ug9FKBgU4t1BRk+VH2rxIivHNzGLIg+KAeCEukrK90Qhbed17hdg3r8 X4bDpO/MreC5qLBQTa3b/ppEr9Z5c/IWU/1VVfk0uzOmCilXVKAKQl9JPdGDfBV+csxy mlWVoPoMT7PW7LlFq8669HDg1XMwV053glhTWjhthg61U2OBV+tPsEqu5iOP8tJkdv2a KMOg== 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; bh=0Qik2rbTJeSTnxUAV8QCOzX4fgh8aFGRH72XwRCfrXU=; b=gXIk3RxOhnimDat3/WajoJCbd+Lf4KqE2iewPzmDWUOWkjts9gk8Ei9OmZMSy3x8Fd mro3sJ4G39frw2quX7DSMZ2XDIoQ0MxHxfCGYeUTnRHvLI8mAzmclUxHKOzPdi37I+5C JCQm2lE0vTrxzYoDw1xdBvuzMWtDst/sEet0k9F2QQIun/B8mPITs9YL2tiW28yoGP13 0iYizxtgKhCxXazVfre1OzX6T17K2KoeCrKJJGJI/nSqrYXiBGbrG1xbX+w4aXcDPxIe 75UcKL54cEe5eJ7q5ABjnADdLT+w2GUUGWnfhDcTSHY+nmfNgT5NDPZ6IUzWt8/DSAkW RraQ== X-Gm-Message-State: AKwxytdGHTD8hwNJCNlOHPrPDmiMvV2KoUfMiE5+Po+A8OkuV/npBHpc mvcG7RJAhtDzUDo7xoMb2Fv+Lw== X-Received: by 10.28.199.201 with SMTP id x192mr5635191wmf.45.1516301135321; Thu, 18 Jan 2018 10:45:35 -0800 (PST) Received: from boomer.baylibre.local ([90.63.244.31]) by smtp.googlemail.com with ESMTPSA id y62sm6240236wrb.48.2018.01.18.10.45.34 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 18 Jan 2018 10:45:34 -0800 (PST) From: Jerome Brunet To: Neil Armstrong Cc: Jerome Brunet , Kevin Hilman , Carlo Caione , Michael Turquette , Stephen Boyd , linux-amlogic@lists.infradead.org, linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 0/9] clk: meson: pll fixes Date: Thu, 18 Jan 2018 19:45:23 +0100 Message-Id: <20180118184532.6856-1-jbrunet@baylibre.com> X-Mailer: git-send-email 2.14.3 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This changeset is collection of fixes and clean-up around the pll clock provider. This has been triggered by the discussion around the ethernet clock on the axg [0]. On the axg the rate reported by the fixed_pll was off by 8Mhz, which led the internal mux of the ethernet driver to pick an mpll2 instead of the fdiv4. With this series applied, the fixed_pll of the axg now reports 1999998046 Hz, which is coherent with measurements (~2GHz) While debugging this, we uncovered quite a mess around the hdmi_pll of the gxbb and gxl family. This is also fixed by this series. Last, the parameters table provided to the read-only sys_plls have been removed, saving a bit of memory There is still work to be done on this clock provider. Someday, I hope to see the parameter tables go away completely. This pll is just a (quite complex) fractional divider, we sould be able to figure something out at runtime. Jerome Brunet (9): clk: meson: check pll rate param table before using it clk: meson: remove useless pll rate param tables clk: meson: remove unnecessary rounding in the pll clock clk: meson: use frac parameter width instead of a constant clk: meson: add od3 to the pll driver clk: meson: add gxl hdmi pll clk: meson: fix pll with fractional part calculation clk: meson: gxbb: add the fractional part of the fixed_pll clk: meson: axg: add the fractional part of the fixed_pll drivers/clk/meson/axg.c | 99 ++------------------------ drivers/clk/meson/clk-pll.c | 40 ++++++++--- drivers/clk/meson/clkc.h | 2 + drivers/clk/meson/gxbb.c | 166 +++++++++++++++++++------------------------- drivers/clk/meson/gxbb.h | 3 +- 5 files changed, 110 insertions(+), 200 deletions(-) -- 2.14.3