From patchwork Wed Aug 1 14:00:51 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Brunet X-Patchwork-Id: 10552367 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 0FE4915E9 for ; Wed, 1 Aug 2018 14:01:23 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F34462B68D for ; Wed, 1 Aug 2018 14:01:22 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id F14872B587; Wed, 1 Aug 2018 14:01:22 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 7F4E52B68D for ; Wed, 1 Aug 2018 14:01:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=cnmDmSiP5geMpfnN/5unYsGy+ikyiD3JN1BYOKIFgZA=; b=nAfxjdVXQ5bvdB1VR8AckhZQqV vVCAaQ27UOGAtesVCmTupgoLqiF+uw8QIBNRMt6CqG3wcgQrX0KnujB5dcU1LvQ/6Dd53XulHpcA0 52mg2MckQfqzQMNWaHNnOz8cen3AxlBkKUxLIAAXeHoBY0PzioOEi9S2bege/sVAC7iwkydQ/uodD rCvw5UuoCCKffN+Rvl6B7uPrCWQuVXeD5dgVNjyTn8f+xCGQk7zpmJQql3b1xI1LpcTm2KHWEXtrD QvYr0gi34YXJI5UAf+HmNfh3PoKxvUtzkcoydfplhQRJHbmKqUCWJAPg051ter1PqQefXyE+XLpDN msZa2eVA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1fkrgn-0001hN-Gk; Wed, 01 Aug 2018 14:01:21 +0000 Received: from mail-wm0-x244.google.com ([2a00:1450:400c:c09::244]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fkrgg-0001aX-1l for linux-amlogic@lists.infradead.org; Wed, 01 Aug 2018 14:01:20 +0000 Received: by mail-wm0-x244.google.com with SMTP id o18-v6so7234692wmc.0 for ; Wed, 01 Aug 2018 07:01:03 -0700 (PDT) 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:in-reply-to:references; bh=tT891o9jn6Kn0tbJzJp/aBQBAO7V89EsA5J9nmhYG+k=; b=imZzMZxXXUxsnw5KnT5fRyEB54QBBv+fI2mDZtkqdVTCbJlCr4NwtTlNXlEN/C89q7 hiGrrbbephjhf0naPzTPnPM1R4TipY3RFNeD1zAP44iI7OZbnml5SErUd20n5PbG/ppm f7Ocalevfto2yEjXPY7eWhMTM3rZDUA0DcHab2SEmeeYUzQuAdGcULszf6QsQ/yGQw7g fLEYnmor0rQSeZGtDnCBpczihc2+fo1tH+XM+HjYS9HD9VRQvUMMRcHsyfUS/QYMhsl1 9jbSefdY5vfefoRirZSWcrd8giIw2WLMxrF39qvBrPNX+DWC39qKjK7SuJSVblYEz5W9 /96A== 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; bh=tT891o9jn6Kn0tbJzJp/aBQBAO7V89EsA5J9nmhYG+k=; b=ZrqZebqp7j0T11MJe5BuAIdj28FhDszloxKiP/BxPcCyB34ZAJCVxYWU2I2ID2Nsns risYj3nQzgM8FnY9gTL/klBEbSz7JJNhd6YRL2aFcgT7vGsmAHDrPdQPiEJY4QYfTM92 02mDWDIggJZjRIYI08sgGZM6d3a+wExRxnDQdzswJxBDSeNDheEY6nzoVEM8X5cRUaVw C58toNEHYQbQzLNsXi+ujAAx/HWBxcXsFbwGjWN61g2XOYE4d2h8WMSAok2fio3A97Qd jaKcvQgBxpxQ/BzPuxfigKWFY/oTMG29ZVolQdprS5udUtcOb656fkxiCIjpBFAoKaWQ ZPGQ== X-Gm-Message-State: AOUpUlHxyJkAYh6rUAKpkLNYkjYkbb3v/LYIE61bdq2+4iGOuzpX075f kLbt54lwzZ+uhSbrht7Nb5QkTQ== X-Google-Smtp-Source: AAOMgpcUKLIMdqfndBzd5Y6Y82UTOok7jiBcvVlPfNGYiJhT0o3RptW2IQhmQt+MhGvW/kibRjA4og== X-Received: by 2002:a1c:e595:: with SMTP id c143-v6mr2965042wmh.85.1533132062566; Wed, 01 Aug 2018 07:01:02 -0700 (PDT) Received: from boomer.baylibre.local ([90.63.244.31]) by smtp.googlemail.com with ESMTPSA id d42-v6sm2816309wma.0.2018.08.01.07.01.01 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 01 Aug 2018 07:01:01 -0700 (PDT) From: Jerome Brunet To: Neil Armstrong Subject: [PATCH v2 2/4] clk: meson: clk-pll: drop CLK_GET_RATE_NOCACHE where unnecessary Date: Wed, 1 Aug 2018 16:00:51 +0200 Message-Id: <20180801140053.25899-3-jbrunet@baylibre.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180801140053.25899-1-jbrunet@baylibre.com> References: <20180801140053.25899-1-jbrunet@baylibre.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180801_070114_092407_BA149253 X-CRM114-Status: GOOD ( 12.57 ) X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Martin Blumenstingl , Kevin Hilman , linux-kernel@vger.kernel.org, linux-amlogic@lists.infradead.org, linux-clk@vger.kernel.org, Jerome Brunet MIME-Version: 1.0 Sender: "linux-amlogic" Errors-To: linux-amlogic-bounces+patchwork-linux-amlogic=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP CLK_GET_RATE_NOCACHE should only be necessary when the registers controlling the rate of clock may change outside of CCF. On Amlogic, it should only be the case for the hdmi pll which is directly controlled by the display driver (WIP to fix this). The other plls should not require this flag. Signed-off-by: Jerome Brunet --- drivers/clk/meson/axg.c | 1 - drivers/clk/meson/gxbb.c | 12 ++++++++---- drivers/clk/meson/meson8b.c | 3 --- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/clk/meson/axg.c b/drivers/clk/meson/axg.c index 6d8976554656..991fa511c05a 100644 --- a/drivers/clk/meson/axg.c +++ b/drivers/clk/meson/axg.c @@ -106,7 +106,6 @@ static struct clk_regmap axg_sys_pll = { .ops = &meson_clk_pll_ro_ops, .parent_names = (const char *[]){ "xtal" }, .num_parents = 1, - .flags = CLK_GET_RATE_NOCACHE, }, }; diff --git a/drivers/clk/meson/gxbb.c b/drivers/clk/meson/gxbb.c index 5ed34566917c..01e3f80e88cc 100644 --- a/drivers/clk/meson/gxbb.c +++ b/drivers/clk/meson/gxbb.c @@ -218,7 +218,6 @@ static struct clk_regmap gxbb_fixed_pll = { .ops = &meson_clk_pll_ro_ops, .parent_names = (const char *[]){ "xtal" }, .num_parents = 1, - .flags = CLK_GET_RATE_NOCACHE, }, }; @@ -286,6 +285,10 @@ static struct clk_regmap gxbb_hdmi_pll = { .ops = &meson_clk_pll_ro_ops, .parent_names = (const char *[]){ "hdmi_pll_pre_mult" }, .num_parents = 1, + /* + * Display directly handle hdmi pll registers ATM, we need + * NOCACHE to keep our view of the clock as accurate as possible + */ .flags = CLK_GET_RATE_NOCACHE, }, }; @@ -349,6 +352,10 @@ static struct clk_regmap gxl_hdmi_pll = { .ops = &meson_clk_pll_ro_ops, .parent_names = (const char *[]){ "xtal" }, .num_parents = 1, + /* + * Display directly handle hdmi pll registers ATM, we need + * NOCACHE to keep our view of the clock as accurate as possible + */ .flags = CLK_GET_RATE_NOCACHE, }, }; @@ -391,7 +398,6 @@ static struct clk_regmap gxbb_sys_pll = { .ops = &meson_clk_pll_ro_ops, .parent_names = (const char *[]){ "xtal" }, .num_parents = 1, - .flags = CLK_GET_RATE_NOCACHE, }, }; @@ -442,7 +448,6 @@ static struct clk_regmap gxbb_gp0_pll = { .ops = &meson_clk_pll_ops, .parent_names = (const char *[]){ "xtal" }, .num_parents = 1, - .flags = CLK_GET_RATE_NOCACHE, }, }; @@ -500,7 +505,6 @@ static struct clk_regmap gxl_gp0_pll = { .ops = &meson_clk_pll_ops, .parent_names = (const char *[]){ "xtal" }, .num_parents = 1, - .flags = CLK_GET_RATE_NOCACHE, }, }; diff --git a/drivers/clk/meson/meson8b.c b/drivers/clk/meson/meson8b.c index fd4c414893f5..ec1f97725b9f 100644 --- a/drivers/clk/meson/meson8b.c +++ b/drivers/clk/meson/meson8b.c @@ -137,7 +137,6 @@ static struct clk_regmap meson8b_fixed_pll = { .ops = &meson_clk_pll_ro_ops, .parent_names = (const char *[]){ "xtal" }, .num_parents = 1, - .flags = CLK_GET_RATE_NOCACHE, }, }; @@ -179,7 +178,6 @@ static struct clk_regmap meson8b_vid_pll = { .ops = &meson_clk_pll_ro_ops, .parent_names = (const char *[]){ "xtal" }, .num_parents = 1, - .flags = CLK_GET_RATE_NOCACHE, }, }; @@ -222,7 +220,6 @@ static struct clk_regmap meson8b_sys_pll = { .ops = &meson_clk_pll_ro_ops, .parent_names = (const char *[]){ "xtal" }, .num_parents = 1, - .flags = CLK_GET_RATE_NOCACHE, }, };