Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1561292 > unrolled thread

[PATCH v2 1/3] clk: rockchip: add rk3288 vip_out clock ids

Started byJacob Chen <jacob-chen@iotwrt.com>
First post2017-01-18 07:00 +0100
Last post2017-01-23 01:30 +0100
Articles 5 — 3 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH v2 1/3] clk: rockchip: add rk3288 vip_out clock ids Jacob Chen <jacob-chen@iotwrt.com> - 2017-01-18 07:00 +0100
    [PATCH v2 3/3] clk: rockchip: rk3288: make all niu clocks critical Jacob Chen <jacob-chen@iotwrt.com> - 2017-01-18 07:00 +0100
      Re: [PATCH v2 3/3] clk: rockchip: rk3288: make all niu clocks critical Jacob Chen <jacobchen110@gmail.com> - 2017-01-22 10:10 +0100
        Re: [PATCH v2 3/3] clk: rockchip: rk3288: make all niu clocks critical Heiko Stuebner <heiko@sntech.de> - 2017-01-22 13:10 +0100
    Re: [PATCH v2 1/3] clk: rockchip: add rk3288 vip_out clock ids Heiko Stuebner <heiko@sntech.de> - 2017-01-23 01:30 +0100

#1561292 — [PATCH v2 1/3] clk: rockchip: add rk3288 vip_out clock ids

FromJacob Chen <jacob-chen@iotwrt.com>
Date2017-01-18 07:00 +0100
Subject[PATCH v2 1/3] clk: rockchip: add rk3288 vip_out clock ids
Message-ID<t0RrP-52-15@gated-at.bofh.it>
Add clock-ids for the vip block of the rk3288

Signed-off-by: Jacob Chen <jacob-chen@iotwrt.com>
---
 include/dt-bindings/clock/rk3288-cru.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/include/dt-bindings/clock/rk3288-cru.h b/include/dt-bindings/clock/rk3288-cru.h
index 9a586e2..11183bf 100644
--- a/include/dt-bindings/clock/rk3288-cru.h
+++ b/include/dt-bindings/clock/rk3288-cru.h
@@ -88,6 +88,7 @@
 #define SCLK_PVTM_GPU		124
 #define SCLK_CRYPTO		125
 #define SCLK_MIPIDSI_24M	126
+#define SCLK_VIP_OUT	127
 
 #define SCLK_MAC		151
 #define SCLK_MACREF_OUT		152
-- 
2.7.4

[toc] | [next] | [standalone]


#1561293 — [PATCH v2 3/3] clk: rockchip: rk3288: make all niu clocks critical

FromJacob Chen <jacob-chen@iotwrt.com>
Date2017-01-18 07:00 +0100
Subject[PATCH v2 3/3] clk: rockchip: rk3288: make all niu clocks critical
Message-ID<t0RrQ-52-23@gated-at.bofh.it>
In reply to#1561292
NIU clocks are related to the interconnect and it's important to other blocks.
Since we don't have a driver to handle it, we should always enable it to avoid
casually close.

Make all of them critical,so that we don't have to each clock on its own
once things break.

Signed-off-by: Jacob Chen <jacob-chen@iotwrt.com>
---
 drivers/clk/rockchip/clk-rk3288.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/clk/rockchip/clk-rk3288.c b/drivers/clk/rockchip/clk-rk3288.c
index 3d02aa2..c50386c 100644
--- a/drivers/clk/rockchip/clk-rk3288.c
+++ b/drivers/clk/rockchip/clk-rk3288.c
@@ -808,8 +808,15 @@ static struct rockchip_clk_branch rk3288_clk_branches[] __initdata = {
 static const char *const rk3288_critical_clocks[] __initconst = {
 	"aclk_cpu",
 	"aclk_peri",
+	"aclk_peri_niu",
+	"aclk_vio0_niu",
+	"aclk_vio1_niu",
+	"aclk_rga_niu",
 	"hclk_peri",
+	"hclk_vio_niu",
+	"pclk_alive_niu",
 	"pclk_pd_pmu",
+	"pclk_pmu_niu",
 };
 
 static void __iomem *rk3288_cru_base;
-- 
2.7.4

[toc] | [prev] | [next] | [standalone]


#1564344 — Re: [PATCH v2 3/3] clk: rockchip: rk3288: make all niu clocks critical

FromJacob Chen <jacobchen110@gmail.com>
Date2017-01-22 10:10 +0100
SubjectRe: [PATCH v2 3/3] clk: rockchip: rk3288: make all niu clocks critical
Message-ID<t2mjT-7mt-3@gated-at.bofh.it>
In reply to#1561293
2017-01-18 13:42 GMT+08:00 Jacob Chen <jacob-chen@iotwrt.com>:
> NIU clocks are related to the interconnect and it's important to other blocks.
> Since we don't have a driver to handle it, we should always enable it to avoid
> casually close.
>
> Make all of them critical,so that we don't have to each clock on its own
> once things break.
>
> Signed-off-by: Jacob Chen <jacob-chen@iotwrt.com>
> ---
>  drivers/clk/rockchip/clk-rk3288.c | 7 +++++++
>  1 file changed, 7 insertions(+)
>
> diff --git a/drivers/clk/rockchip/clk-rk3288.c b/drivers/clk/rockchip/clk-rk3288.c
> index 3d02aa2..c50386c 100644
> --- a/drivers/clk/rockchip/clk-rk3288.c
> +++ b/drivers/clk/rockchip/clk-rk3288.c
> @@ -808,8 +808,15 @@ static struct rockchip_clk_branch rk3288_clk_branches[] __initdata = {
>  static const char *const rk3288_critical_clocks[] __initconst = {
>         "aclk_cpu",
>         "aclk_peri",
> +       "aclk_peri_niu",
> +       "aclk_vio0_niu",
> +       "aclk_vio1_niu",
> +       "aclk_rga_niu",
>         "hclk_peri",
> +       "hclk_vio_niu",
> +       "pclk_alive_niu",
>         "pclk_pd_pmu",
> +       "pclk_pmu_niu",
>  };
>
>  static void __iomem *rk3288_cru_base;
> --
> 2.7.4
>

I just got an another bug that caused by closed niu clock.
Making niu clock always enabled is really useful, it could save me a
lot of time.....

I just wonder why we don't do that before.  Would it have great impact
on power consumption?

[toc] | [prev] | [next] | [standalone]


#1564366 — Re: [PATCH v2 3/3] clk: rockchip: rk3288: make all niu clocks critical

FromHeiko Stuebner <heiko@sntech.de>
Date2017-01-22 13:10 +0100
SubjectRe: [PATCH v2 3/3] clk: rockchip: rk3288: make all niu clocks critical
Message-ID<t2p85-BZ-7@gated-at.bofh.it>
In reply to#1564344
Am Sonntag, 22. Januar 2017, 17:02:17 CET schrieb Jacob Chen:
> 2017-01-18 13:42 GMT+08:00 Jacob Chen <jacob-chen@iotwrt.com>:
> > NIU clocks are related to the interconnect and it's important to other
> > blocks. Since we don't have a driver to handle it, we should always
> > enable it to avoid casually close.
> > 
> > Make all of them critical,so that we don't have to each clock on its own
> > once things break.
> > 
> > Signed-off-by: Jacob Chen <jacob-chen@iotwrt.com>
> > ---
> > 
> >  drivers/clk/rockchip/clk-rk3288.c | 7 +++++++
> >  1 file changed, 7 insertions(+)
> > 
> > diff --git a/drivers/clk/rockchip/clk-rk3288.c
> > b/drivers/clk/rockchip/clk-rk3288.c index 3d02aa2..c50386c 100644
> > --- a/drivers/clk/rockchip/clk-rk3288.c
> > +++ b/drivers/clk/rockchip/clk-rk3288.c
> > @@ -808,8 +808,15 @@ static struct rockchip_clk_branch
> > rk3288_clk_branches[] __initdata = {> 
> >  static const char *const rk3288_critical_clocks[] __initconst = {
> >  
> >         "aclk_cpu",
> >         "aclk_peri",
> > 
> > +       "aclk_peri_niu",
> > +       "aclk_vio0_niu",
> > +       "aclk_vio1_niu",
> > +       "aclk_rga_niu",
> > 
> >         "hclk_peri",
> > 
> > +       "hclk_vio_niu",
> > +       "pclk_alive_niu",
> > 
> >         "pclk_pd_pmu",
> > 
> > +       "pclk_pmu_niu",
> > 
> >  };
> >  
> >  static void __iomem *rk3288_cru_base;
> > 
> > --
> > 2.7.4
> 
> I just got an another bug that caused by closed niu clock.
> Making niu clock always enabled is really useful, it could save me a
> lot of time.....
> 
> I just wonder why we don't do that before.  Would it have great impact
> on power consumption?

The niu clocks so far seemed to rely on the CLK_IGNORE_UNUSED flag. So all was 
well as long as nothing changed in the clock tree above those and I guess with 
more supported peripherals, some now make changes to the more common clocks 
and thus disable the nui clocks by accident.

[toc] | [prev] | [next] | [standalone]


#1564605

FromHeiko Stuebner <heiko@sntech.de>
Date2017-01-23 01:30 +0100
Message-ID<t2AGd-7MJ-5@gated-at.bofh.it>
In reply to#1561292
Am Mittwoch, 18. Januar 2017, 13:42:38 CET schrieb Jacob Chen:
> Add clock-ids for the vip block of the rk3288
> 
> Signed-off-by: Jacob Chen <jacob-chen@iotwrt.com>

applied all 3 for 4.11 .

I've fixed the indentation below (missing one additional tab)
and adapted patch3 to also remove the CLK_IGNORE_UNUSED flags for the clocks we 
now moved to the critical clocks.


Heiko

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web