From: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
To: Shunqian Zheng <zhengsq@rock-chips.com>,
maxime.ripard@free-electrons.com, heiko@sntech.de,
linux-kernel@vger.kernel.org, caesar.wang@rock-chips.com
Cc: dianders@chromium.org, linux-rockchip@lists.infradead.org,
xjq@rock-chips.com
Subject: Re: [PATCH 3/3] clk: rockchip: do not gate the efuse256 clock
Date: Mon, 10 Aug 2015 09:48:03 +0100 [thread overview]
Message-ID: <55C86543.1040802@linaro.org> (raw)
In-Reply-To: <1439176963-8969-4-git-send-email-zhengsq@rock-chips.com>
On 10/08/15 04:22, Shunqian Zheng wrote:
> From: ZhengShunQian <zhengsq@rock-chips.com>
>
> Always enable the clock of efuse256. Base on the nvmem framework,
> it seems like there is not a good way to enable the clock
> when actual needed.
No, thats not true. NVMEM does not mandate anything, it give more
flexibity to providers instead.
What ever this patch is in wrong direction to solve the issue.
We have two options to use clocks for providers, one use
devm_regmap_init_mmio_clk() Or
Have your own context structure like
struct rockchip_context{
void __iomem *base
struct clk *efuse_clk;
};
Then in read/write manage the clock as required.
--srini
>
> Signed-off-by: ZhengShunQian <zhengsq@rock-chips.com>
> ---
> drivers/clk/rockchip/clk-rk3288.c | 2 +-
> include/dt-bindings/clock/rk3288-cru.h | 1 +
> 2 files changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/clk/rockchip/clk-rk3288.c b/drivers/clk/rockchip/clk-rk3288.c
> index 0df5bae..84d9218 100644
> --- a/drivers/clk/rockchip/clk-rk3288.c
> +++ b/drivers/clk/rockchip/clk-rk3288.c
> @@ -647,7 +647,7 @@ static struct rockchip_clk_branch rk3288_clk_branches[] __initdata = {
> GATE(0, "pclk_efuse_1024", "pclk_cpu", 0, RK3288_CLKGATE_CON(11), 2, GFLAGS),
> GATE(PCLK_TZPC, "pclk_tzpc", "pclk_cpu", 0, RK3288_CLKGATE_CON(11), 3, GFLAGS),
> GATE(PCLK_UART2, "pclk_uart2", "pclk_cpu", 0, RK3288_CLKGATE_CON(11), 9, GFLAGS),
> - GATE(0, "pclk_efuse_256", "pclk_cpu", 0, RK3288_CLKGATE_CON(11), 10, GFLAGS),
> + GATE(PCLK_EFUSE256, "pclk_efuse_256", "pclk_cpu", CLK_IGNORE_UNUSED, RK3288_CLKGATE_CON(11), 10, GFLAGS),
> GATE(PCLK_RKPWM, "pclk_rkpwm", "pclk_cpu", CLK_IGNORE_UNUSED, RK3288_CLKGATE_CON(11), 11, GFLAGS),
>
> /* ddrctrl [DDR Controller PHY clock] gates */
> diff --git a/include/dt-bindings/clock/rk3288-cru.h b/include/dt-bindings/clock/rk3288-cru.h
> index c719aac..ab74d5e 100644
> --- a/include/dt-bindings/clock/rk3288-cru.h
> +++ b/include/dt-bindings/clock/rk3288-cru.h
> @@ -164,6 +164,7 @@
> #define PCLK_DDRUPCTL1 366
> #define PCLK_PUBL1 367
> #define PCLK_WDT 368
> +#define PCLK_EFUSE256 369
>
> /* hclk gates */
> #define HCLK_GPS 448
>
prev parent reply other threads:[~2015-08-10 8:48 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-10 3:22 [PATCH 0/3] Add eFuse driver of Rockchip SoC Shunqian Zheng
2015-08-10 3:22 ` [PATCH 1/3] nvmem: fix the out-of-range leak in read/write() Shunqian Zheng
2015-08-10 8:49 ` Srinivas Kandagatla
2015-08-10 3:22 ` [PATCH 2/3] nvmem: rockchip-efuse: implement eFuse driver Shunqian Zheng
2015-08-10 8:58 ` Srinivas Kandagatla
2015-08-10 3:22 ` [PATCH 3/3] clk: rockchip: do not gate the efuse256 clock Shunqian Zheng
2015-08-10 8:08 ` Heiko Stübner
2015-08-10 8:37 ` Shunqian Zheng
2015-08-10 8:48 ` Srinivas Kandagatla [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=55C86543.1040802@linaro.org \
--to=srinivas.kandagatla@linaro.org \
--cc=caesar.wang@rock-chips.com \
--cc=dianders@chromium.org \
--cc=heiko@sntech.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=maxime.ripard@free-electrons.com \
--cc=xjq@rock-chips.com \
--cc=zhengsq@rock-chips.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox