All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h
@ 2013-10-08 11:17 Sachin Kamat
  2013-10-08 11:17 ` [PATCH 02/10] clk: SPEAr: Staticize clk_frac_ops Sachin Kamat
                   ` (9 more replies)
  0 siblings, 10 replies; 23+ messages in thread
From: Sachin Kamat @ 2013-10-08 11:17 UTC (permalink / raw)
  To: linux-arm-kernel

clk-provider.h was included twice.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
---
Added all the acquired acks to respective patches.
---
 drivers/clk/clk-bcm2835.c |    1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/clk/clk-bcm2835.c b/drivers/clk/clk-bcm2835.c
index 5fb4ff5..676077d 100644
--- a/drivers/clk/clk-bcm2835.c
+++ b/drivers/clk/clk-bcm2835.c
@@ -20,7 +20,6 @@
 #include <linux/clk-provider.h>
 #include <linux/clkdev.h>
 #include <linux/clk/bcm2835.h>
-#include <linux/clk-provider.h>
 #include <linux/of.h>
 
 static const struct of_device_id clk_match[] __initconst = {
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 02/10] clk: SPEAr: Staticize clk_frac_ops
  2013-10-08 11:17 [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
@ 2013-10-08 11:17 ` Sachin Kamat
  2013-10-08 11:17 ` [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c Sachin Kamat
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 23+ messages in thread
From: Sachin Kamat @ 2013-10-08 11:17 UTC (permalink / raw)
  To: linux-arm-kernel

clk_frac_ops is local to this file. Make it static.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
---
 drivers/clk/spear/clk-frac-synth.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clk/spear/clk-frac-synth.c b/drivers/clk/spear/clk-frac-synth.c
index 958aa3a..dffd4ce 100644
--- a/drivers/clk/spear/clk-frac-synth.c
+++ b/drivers/clk/spear/clk-frac-synth.c
@@ -116,7 +116,7 @@ static int clk_frac_set_rate(struct clk_hw *hw, unsigned long drate,
 	return 0;
 }
 
-struct clk_ops clk_frac_ops = {
+static struct clk_ops clk_frac_ops = {
 	.recalc_rate = clk_frac_recalc_rate,
 	.round_rate = clk_frac_round_rate,
 	.set_rate = clk_frac_set_rate,
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c
  2013-10-08 11:17 [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
  2013-10-08 11:17 ` [PATCH 02/10] clk: SPEAr: Staticize clk_frac_ops Sachin Kamat
@ 2013-10-08 11:17 ` Sachin Kamat
  2013-10-08 16:09   ` Stephen Warren
  2013-12-20  1:53   ` Mike Turquette
  2013-10-08 11:17 ` [PATCH 04/10] clk: tegra: Staticize tegra_clk_periph_nodiv_ops Sachin Kamat
                   ` (7 subsequent siblings)
  9 siblings, 2 replies; 23+ messages in thread
From: Sachin Kamat @ 2013-10-08 11:17 UTC (permalink / raw)
  To: linux-arm-kernel

Local variables used only in this file are made static.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Stephen Warren <swarren@nvidia.com>
---
 drivers/clk/tegra/clk-pll.c |   10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/clk/tegra/clk-pll.c b/drivers/clk/tegra/clk-pll.c
index 197074a..76ed452 100644
--- a/drivers/clk/tegra/clk-pll.c
+++ b/drivers/clk/tegra/clk-pll.c
@@ -1340,7 +1340,7 @@ struct clk *tegra_clk_register_plle(const char *name, const char *parent_name,
 }
 
 #ifdef CONFIG_ARCH_TEGRA_114_SOC
-const struct clk_ops tegra_clk_pllxc_ops = {
+static const struct clk_ops tegra_clk_pllxc_ops = {
 	.is_enabled = clk_pll_is_enabled,
 	.enable = clk_pll_iddq_enable,
 	.disable = clk_pll_iddq_disable,
@@ -1349,7 +1349,7 @@ const struct clk_ops tegra_clk_pllxc_ops = {
 	.set_rate = clk_pllxc_set_rate,
 };
 
-const struct clk_ops tegra_clk_pllm_ops = {
+static const struct clk_ops tegra_clk_pllm_ops = {
 	.is_enabled = clk_pll_is_enabled,
 	.enable = clk_pll_iddq_enable,
 	.disable = clk_pll_iddq_disable,
@@ -1358,7 +1358,7 @@ const struct clk_ops tegra_clk_pllm_ops = {
 	.set_rate = clk_pllm_set_rate,
 };
 
-const struct clk_ops tegra_clk_pllc_ops = {
+static const struct clk_ops tegra_clk_pllc_ops = {
 	.is_enabled = clk_pll_is_enabled,
 	.enable = clk_pllc_enable,
 	.disable = clk_pllc_disable,
@@ -1367,7 +1367,7 @@ const struct clk_ops tegra_clk_pllc_ops = {
 	.set_rate = clk_pllc_set_rate,
 };
 
-const struct clk_ops tegra_clk_pllre_ops = {
+static const struct clk_ops tegra_clk_pllre_ops = {
 	.is_enabled = clk_pll_is_enabled,
 	.enable = clk_pll_iddq_enable,
 	.disable = clk_pll_iddq_disable,
@@ -1376,7 +1376,7 @@ const struct clk_ops tegra_clk_pllre_ops = {
 	.set_rate = clk_pllre_set_rate,
 };
 
-const struct clk_ops tegra_clk_plle_tegra114_ops = {
+static const struct clk_ops tegra_clk_plle_tegra114_ops = {
 	.is_enabled =  clk_pll_is_enabled,
 	.enable = clk_plle_tegra114_enable,
 	.disable = clk_plle_tegra114_disable,
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 04/10] clk: tegra: Staticize tegra_clk_periph_nodiv_ops
  2013-10-08 11:17 [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
  2013-10-08 11:17 ` [PATCH 02/10] clk: SPEAr: Staticize clk_frac_ops Sachin Kamat
  2013-10-08 11:17 ` [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c Sachin Kamat
@ 2013-10-08 11:17 ` Sachin Kamat
  2013-10-08 11:17 ` [PATCH 05/10] clk: socfpga: Use NULL instead of 0 Sachin Kamat
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 23+ messages in thread
From: Sachin Kamat @ 2013-10-08 11:17 UTC (permalink / raw)
  To: linux-arm-kernel

tegra_clk_periph_nodiv_ops is used only in this file. Make it static.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
---
 drivers/clk/tegra/clk-periph.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clk/tegra/clk-periph.c b/drivers/clk/tegra/clk-periph.c
index b2309d3..2c0bfa2 100644
--- a/drivers/clk/tegra/clk-periph.c
+++ b/drivers/clk/tegra/clk-periph.c
@@ -162,7 +162,7 @@ const struct clk_ops tegra_clk_periph_ops = {
 	.disable = clk_periph_disable,
 };
 
-const struct clk_ops tegra_clk_periph_nodiv_ops = {
+static const struct clk_ops tegra_clk_periph_nodiv_ops = {
 	.get_parent = clk_periph_get_parent,
 	.set_parent = clk_periph_set_parent,
 	.is_enabled = clk_periph_is_enabled,
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 05/10] clk: socfpga: Use NULL instead of 0
  2013-10-08 11:17 [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
                   ` (2 preceding siblings ...)
  2013-10-08 11:17 ` [PATCH 04/10] clk: tegra: Staticize tegra_clk_periph_nodiv_ops Sachin Kamat
@ 2013-10-08 11:17 ` Sachin Kamat
  2013-10-08 11:17 ` [PATCH 06/10] clk: versatile: Staticize clk_sp810_timerclken_of_get Sachin Kamat
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 23+ messages in thread
From: Sachin Kamat @ 2013-10-08 11:17 UTC (permalink / raw)
  To: linux-arm-kernel

'div_reg' is a pointer. Assign NULL instead of 0.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Acked-by: Dinh Nguyen <dinguyen@altera.com>
---
 drivers/clk/socfpga/clk.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clk/socfpga/clk.c b/drivers/clk/socfpga/clk.c
index 5bb848c..454ddc1 100644
--- a/drivers/clk/socfpga/clk.c
+++ b/drivers/clk/socfpga/clk.c
@@ -292,7 +292,7 @@ static void __init socfpga_gate_clk_init(struct device_node *node,
 		socfpga_clk->shift = div_reg[1];
 		socfpga_clk->width = div_reg[2];
 	} else {
-		socfpga_clk->div_reg = 0;
+		socfpga_clk->div_reg = NULL;
 	}
 
 	of_property_read_string(node, "clock-output-names", &clk_name);
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 06/10] clk: versatile: Staticize clk_sp810_timerclken_of_get
  2013-10-08 11:17 [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
                   ` (3 preceding siblings ...)
  2013-10-08 11:17 ` [PATCH 05/10] clk: socfpga: Use NULL instead of 0 Sachin Kamat
@ 2013-10-08 11:17 ` Sachin Kamat
  2013-10-08 11:17 ` [PATCH 07/10] clk: mvebu: Staticize of_cpu_clk_setup Sachin Kamat
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 23+ messages in thread
From: Sachin Kamat @ 2013-10-08 11:17 UTC (permalink / raw)
  To: linux-arm-kernel

clk_sp810_timerclken_of_get is used only in this file. Make it static.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
---
 drivers/clk/versatile/clk-sp810.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clk/versatile/clk-sp810.c b/drivers/clk/versatile/clk-sp810.c
index bf9b15a..c6e86a9 100644
--- a/drivers/clk/versatile/clk-sp810.c
+++ b/drivers/clk/versatile/clk-sp810.c
@@ -123,7 +123,7 @@ static const struct clk_ops clk_sp810_timerclken_ops = {
 	.set_parent = clk_sp810_timerclken_set_parent,
 };
 
-struct clk *clk_sp810_timerclken_of_get(struct of_phandle_args *clkspec,
+static struct clk *clk_sp810_timerclken_of_get(struct of_phandle_args *clkspec,
 		void *data)
 {
 	struct clk_sp810 *sp810 = data;
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 07/10] clk: mvebu: Staticize of_cpu_clk_setup
  2013-10-08 11:17 [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
                   ` (4 preceding siblings ...)
  2013-10-08 11:17 ` [PATCH 06/10] clk: versatile: Staticize clk_sp810_timerclken_of_get Sachin Kamat
@ 2013-10-08 11:17 ` Sachin Kamat
  2013-10-08 11:17 ` [PATCH 08/10] clk: vt8500: Staticize vtwm_pll_ops Sachin Kamat
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 23+ messages in thread
From: Sachin Kamat @ 2013-10-08 11:17 UTC (permalink / raw)
  To: linux-arm-kernel

'of_cpu_clk_setup' is used only in this file. Make it static.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Acked-by: Gregory CLEMENT <gregory.clement@free-electrons.com>
---
 drivers/clk/mvebu/clk-cpu.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clk/mvebu/clk-cpu.c b/drivers/clk/mvebu/clk-cpu.c
index 1466865..8ebf757 100644
--- a/drivers/clk/mvebu/clk-cpu.c
+++ b/drivers/clk/mvebu/clk-cpu.c
@@ -101,7 +101,7 @@ static const struct clk_ops cpu_ops = {
 	.set_rate = clk_cpu_set_rate,
 };
 
-void __init of_cpu_clk_setup(struct device_node *node)
+static void __init of_cpu_clk_setup(struct device_node *node)
 {
 	struct cpu_clk *cpuclk;
 	void __iomem *clock_complex_base = of_iomap(node, 0);
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 08/10] clk: vt8500: Staticize vtwm_pll_ops
  2013-10-08 11:17 [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
                   ` (5 preceding siblings ...)
  2013-10-08 11:17 ` [PATCH 07/10] clk: mvebu: Staticize of_cpu_clk_setup Sachin Kamat
@ 2013-10-08 11:17 ` Sachin Kamat
  2013-10-08 11:17 ` [PATCH 09/10] clk: ux500: Remove extra semicolon Sachin Kamat
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 23+ messages in thread
From: Sachin Kamat @ 2013-10-08 11:17 UTC (permalink / raw)
  To: linux-arm-kernel

'vtwm_pll_ops' is local to this file. Make it static.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Tony Prisk <linux@prisktech.co.nz>
---
 drivers/clk/clk-vt8500.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clk/clk-vt8500.c b/drivers/clk/clk-vt8500.c
index 82306f5..a45e7a6 100644
--- a/drivers/clk/clk-vt8500.c
+++ b/drivers/clk/clk-vt8500.c
@@ -620,7 +620,7 @@ static unsigned long vtwm_pll_recalc_rate(struct clk_hw *hw,
 	return pll_freq;
 }
 
-const struct clk_ops vtwm_pll_ops = {
+static const struct clk_ops vtwm_pll_ops = {
 	.round_rate = vtwm_pll_round_rate,
 	.set_rate = vtwm_pll_set_rate,
 	.recalc_rate = vtwm_pll_recalc_rate,
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 09/10] clk: ux500: Remove extra semicolon
  2013-10-08 11:17 [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
                   ` (6 preceding siblings ...)
  2013-10-08 11:17 ` [PATCH 08/10] clk: vt8500: Staticize vtwm_pll_ops Sachin Kamat
@ 2013-10-08 11:17 ` Sachin Kamat
  2013-10-08 11:17 ` [PATCH 10/10] clk: max77686: Remove redundant break Sachin Kamat
  2013-12-05 11:27 ` [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
  9 siblings, 0 replies; 23+ messages in thread
From: Sachin Kamat @ 2013-10-08 11:17 UTC (permalink / raw)
  To: linux-arm-kernel

Extra semicolon is redundant. Remove it.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Acked-by: Ulf Hansson <ulf.hansson@linaro.org>
---
 drivers/clk/ux500/clk-prcmu.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clk/ux500/clk-prcmu.c b/drivers/clk/ux500/clk-prcmu.c
index 293a288..e2d63bc 100644
--- a/drivers/clk/ux500/clk-prcmu.c
+++ b/drivers/clk/ux500/clk-prcmu.c
@@ -36,7 +36,7 @@ static int clk_prcmu_prepare(struct clk_hw *hw)
 	if (!ret)
 		clk->is_prepared = 1;
 
-	return ret;;
+	return ret;
 }
 
 static void clk_prcmu_unprepare(struct clk_hw *hw)
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 10/10] clk: max77686: Remove redundant break
  2013-10-08 11:17 [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
                   ` (7 preceding siblings ...)
  2013-10-08 11:17 ` [PATCH 09/10] clk: ux500: Remove extra semicolon Sachin Kamat
@ 2013-10-08 11:17 ` Sachin Kamat
  2013-12-05 11:27 ` [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
  9 siblings, 0 replies; 23+ messages in thread
From: Sachin Kamat @ 2013-10-08 11:17 UTC (permalink / raw)
  To: linux-arm-kernel

'break' after 'goto' is redundant. Remove it.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Jonghwa Lee <jonghwa3.lee@samsung.com>
---
 drivers/clk/clk-max77686.c |    2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/clk/clk-max77686.c b/drivers/clk/clk-max77686.c
index 9f57bc3..b4a1a97 100644
--- a/drivers/clk/clk-max77686.c
+++ b/drivers/clk/clk-max77686.c
@@ -157,11 +157,9 @@ static int max77686_clk_probe(struct platform_device *pdev)
 			case MAX77686_CLK_AP:
 				dev_err(&pdev->dev, "Fail to register CLK_AP\n");
 				goto err_clk_ap;
-				break;
 			case MAX77686_CLK_CP:
 				dev_err(&pdev->dev, "Fail to register CLK_CP\n");
 				goto err_clk_cp;
-				break;
 			case MAX77686_CLK_PMIC:
 				dev_err(&pdev->dev, "Fail to register CLK_PMIC\n");
 				goto err_clk_pmic;
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c
  2013-10-08 11:17 ` [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c Sachin Kamat
@ 2013-10-08 16:09   ` Stephen Warren
  2013-10-10 11:13     ` Peter De Schrijver
  2013-12-20  1:53   ` Mike Turquette
  1 sibling, 1 reply; 23+ messages in thread
From: Stephen Warren @ 2013-10-08 16:09 UTC (permalink / raw)
  To: linux-arm-kernel

On 10/08/2013 05:17 AM, Sachin Kamat wrote:
> Local variables used only in this file are made static.

This might conflict with some of the cod re-org patches that Peter has
sent. Peter, can you please check. If it does, Peter may as well roll
this into his repost of all the Tegra clock patches...

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c
  2013-10-08 16:09   ` Stephen Warren
@ 2013-10-10 11:13     ` Peter De Schrijver
  2013-10-10 16:07       ` Stephen Warren
  0 siblings, 1 reply; 23+ messages in thread
From: Peter De Schrijver @ 2013-10-10 11:13 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Oct 08, 2013 at 06:09:24PM +0200, Stephen Warren wrote:
> On 10/08/2013 05:17 AM, Sachin Kamat wrote:
> > Local variables used only in this file are made static.
> 

Conceptually they are still exported. So I think it's counterintuitive to
declare them static. Unless you expect namespace problems, I would rather
leave it as is.

Cheers,

Peter.

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c
  2013-10-10 11:13     ` Peter De Schrijver
@ 2013-10-10 16:07       ` Stephen Warren
  2013-10-14  8:15         ` Peter De Schrijver
  0 siblings, 1 reply; 23+ messages in thread
From: Stephen Warren @ 2013-10-10 16:07 UTC (permalink / raw)
  To: linux-arm-kernel

On 10/10/2013 05:13 AM, Peter De Schrijver wrote:
> On Tue, Oct 08, 2013 at 06:09:24PM +0200, Stephen Warren wrote:
>> On 10/08/2013 05:17 AM, Sachin Kamat wrote:
>>> Local variables used only in this file are made static.
>>
> 
> Conceptually they are still exported. So I think it's counterintuitive to
> declare them static. Unless you expect namespace problems, I would rather
> leave it as is.

I forget exactly which symbols this patch changed, but presumably
they're only exported via pointers rather than by symbol name, and isn't
that exactly what static is for?

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c
  2013-10-10 16:07       ` Stephen Warren
@ 2013-10-14  8:15         ` Peter De Schrijver
  2013-10-14 16:35           ` Stephen Warren
  0 siblings, 1 reply; 23+ messages in thread
From: Peter De Schrijver @ 2013-10-14  8:15 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Oct 10, 2013 at 06:07:38PM +0200, Stephen Warren wrote:
> On 10/10/2013 05:13 AM, Peter De Schrijver wrote:
> > On Tue, Oct 08, 2013 at 06:09:24PM +0200, Stephen Warren wrote:
> >> On 10/08/2013 05:17 AM, Sachin Kamat wrote:
> >>> Local variables used only in this file are made static.
> >>
> > 
> > Conceptually they are still exported. So I think it's counterintuitive to
> > declare them static. Unless you expect namespace problems, I would rather
> > leave it as is.
> 
> I forget exactly which symbols this patch changed, but presumably
> they're only exported via pointers rather than by symbol name, and isn't
> that exactly what static is for?

They are indeed exported using a pointer. depends on how you look at it I
guess, but I see static as 'local to this file only' which isn't really
true if you hand out pointers to others.

Cheers,

Peter.

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c
  2013-10-14  8:15         ` Peter De Schrijver
@ 2013-10-14 16:35           ` Stephen Warren
  2013-10-15  8:29             ` Peter De Schrijver
  0 siblings, 1 reply; 23+ messages in thread
From: Stephen Warren @ 2013-10-14 16:35 UTC (permalink / raw)
  To: linux-arm-kernel

On 10/14/2013 02:15 AM, Peter De Schrijver wrote:
> On Thu, Oct 10, 2013 at 06:07:38PM +0200, Stephen Warren wrote:
>> On 10/10/2013 05:13 AM, Peter De Schrijver wrote:
>>> On Tue, Oct 08, 2013 at 06:09:24PM +0200, Stephen Warren wrote:
>>>> On 10/08/2013 05:17 AM, Sachin Kamat wrote:
>>>>> Local variables used only in this file are made static.
>>>>
>>>
>>> Conceptually they are still exported. So I think it's counterintuitive to
>>> declare them static. Unless you expect namespace problems, I would rather
>>> leave it as is.
>>
>> I forget exactly which symbols this patch changed, but presumably
>> they're only exported via pointers rather than by symbol name, and isn't
>> that exactly what static is for?
> 
> They are indeed exported using a pointer. depends on how you look at it I
> guess, but I see static as 'local to this file only' which isn't really
> true if you hand out pointers to others.

Yes, static specifically means "the symbol name is local to this file".
It says nothing about the data behind the symbol name.

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c
  2013-10-14 16:35           ` Stephen Warren
@ 2013-10-15  8:29             ` Peter De Schrijver
  2013-10-15 15:10               ` Stephen Warren
  0 siblings, 1 reply; 23+ messages in thread
From: Peter De Schrijver @ 2013-10-15  8:29 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Oct 14, 2013 at 06:35:58PM +0200, Stephen Warren wrote:
> On 10/14/2013 02:15 AM, Peter De Schrijver wrote:
> > On Thu, Oct 10, 2013 at 06:07:38PM +0200, Stephen Warren wrote:
> >> On 10/10/2013 05:13 AM, Peter De Schrijver wrote:
> >>> On Tue, Oct 08, 2013 at 06:09:24PM +0200, Stephen Warren wrote:
> >>>> On 10/08/2013 05:17 AM, Sachin Kamat wrote:
> >>>>> Local variables used only in this file are made static.
> >>>>
> >>>
> >>> Conceptually they are still exported. So I think it's counterintuitive to
> >>> declare them static. Unless you expect namespace problems, I would rather
> >>> leave it as is.
> >>
> >> I forget exactly which symbols this patch changed, but presumably
> >> they're only exported via pointers rather than by symbol name, and isn't
> >> that exactly what static is for?
> > 
> > They are indeed exported using a pointer. depends on how you look at it I
> > guess, but I see static as 'local to this file only' which isn't really
> > true if you hand out pointers to others.
> 
> Yes, static specifically means "the symbol name is local to this file".
> It says nothing about the data behind the symbol name.

I would still prefer the symbol visibility to have some relation with how
the data is used.

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c
  2013-10-15  8:29             ` Peter De Schrijver
@ 2013-10-15 15:10               ` Stephen Warren
  0 siblings, 0 replies; 23+ messages in thread
From: Stephen Warren @ 2013-10-15 15:10 UTC (permalink / raw)
  To: linux-arm-kernel

On 10/15/2013 02:29 AM, Peter De Schrijver wrote:
> On Mon, Oct 14, 2013 at 06:35:58PM +0200, Stephen Warren wrote:
>> On 10/14/2013 02:15 AM, Peter De Schrijver wrote:
>>> On Thu, Oct 10, 2013 at 06:07:38PM +0200, Stephen Warren wrote:
>>>> On 10/10/2013 05:13 AM, Peter De Schrijver wrote:
>>>>> On Tue, Oct 08, 2013 at 06:09:24PM +0200, Stephen Warren wrote:
>>>>>> On 10/08/2013 05:17 AM, Sachin Kamat wrote:
>>>>>>> Local variables used only in this file are made static.
>>>>>>
>>>>>
>>>>> Conceptually they are still exported. So I think it's counterintuitive to
>>>>> declare them static. Unless you expect namespace problems, I would rather
>>>>> leave it as is.
>>>>
>>>> I forget exactly which symbols this patch changed, but presumably
>>>> they're only exported via pointers rather than by symbol name, and isn't
>>>> that exactly what static is for?
>>>
>>> They are indeed exported using a pointer. depends on how you look at it I
>>> guess, but I see static as 'local to this file only' which isn't really
>>> true if you hand out pointers to others.
>>
>> Yes, static specifically means "the symbol name is local to this file".
>> It says nothing about the data behind the symbol name.
> 
> I would still prefer the symbol visibility to have some relation with how
> the data is used.

No, if the *symbol* is not used, it should be static. There's absolutely
zero benefit from having a visible symbol if it isn't used.

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h
  2013-10-08 11:17 [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
                   ` (8 preceding siblings ...)
  2013-10-08 11:17 ` [PATCH 10/10] clk: max77686: Remove redundant break Sachin Kamat
@ 2013-12-05 11:27 ` Sachin Kamat
  2013-12-20  1:59   ` Mike Turquette
  9 siblings, 1 reply; 23+ messages in thread
From: Sachin Kamat @ 2013-12-05 11:27 UTC (permalink / raw)
  To: linux-arm-kernel

On 8 October 2013 16:47, Sachin Kamat <sachin.kamat@linaro.org> wrote:
> clk-provider.h was included twice.
>
> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
> ---
> Added all the acquired acks to respective patches.
> ---
>  drivers/clk/clk-bcm2835.c |    1 -
>  1 file changed, 1 deletion(-)
>
> diff --git a/drivers/clk/clk-bcm2835.c b/drivers/clk/clk-bcm2835.c
> index 5fb4ff5..676077d 100644
> --- a/drivers/clk/clk-bcm2835.c
> +++ b/drivers/clk/clk-bcm2835.c
> @@ -20,7 +20,6 @@
>  #include <linux/clk-provider.h>
>  #include <linux/clkdev.h>
>  #include <linux/clk/bcm2835.h>
> -#include <linux/clk-provider.h>
>  #include <linux/of.h>
>
>  static const struct of_device_id clk_match[] __initconst = {
> --
> 1.7.9.5
>

Mike,

Any chance getting this series picked up?

-- 
With warm regards,
Sachin

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c
  2013-10-08 11:17 ` [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c Sachin Kamat
  2013-10-08 16:09   ` Stephen Warren
@ 2013-12-20  1:53   ` Mike Turquette
  1 sibling, 0 replies; 23+ messages in thread
From: Mike Turquette @ 2013-12-20  1:53 UTC (permalink / raw)
  To: linux-arm-kernel

Quoting Sachin Kamat (2013-10-08 04:17:41)
> Local variables used only in this file are made static.
> 
> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
> Cc: Stephen Warren <swarren@nvidia.com>

I updated this patch to staticize tegra_clk_pllxc_ops after taking
Peter's Tegra pull request. Refreshed patch has been applied to clk-next
and a copy is found below. Let me know if you have any comments.

Regards,
Mike



From: Sachin Kamat <sachin.kamat@linaro.org>
Date: Tue, 8 Oct 2013 16:47:41 +0530
Subject: [PATCH] clk: tegra: Staticize local variables in clk-pll.c

Local variables used only in this file are made static.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Mike Turquette <mturquette@linaro.org>
[mturquette at linaro.org: staticize struct clk_ops tegra_clk_pllxc_ops]
---
 drivers/clk/tegra/clk-pll.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/clk/tegra/clk-pll.c b/drivers/clk/tegra/clk-pll.c
index 2dd4322..0d20241 100644
--- a/drivers/clk/tegra/clk-pll.c
+++ b/drivers/clk/tegra/clk-pll.c
@@ -1433,7 +1433,7 @@ struct clk *tegra_clk_register_plle(const char *name, const char *parent_name,
 }
 
 #if defined(CONFIG_ARCH_TEGRA_114_SOC) || defined(CONFIG_ARCH_TEGRA_124_SOC)
-const struct clk_ops tegra_clk_pllxc_ops = {
+static const struct clk_ops tegra_clk_pllxc_ops = {
 	.is_enabled = clk_pll_is_enabled,
 	.enable = clk_pll_iddq_enable,
 	.disable = clk_pll_iddq_disable,
@@ -1442,7 +1442,7 @@ const struct clk_ops tegra_clk_pllxc_ops = {
 	.set_rate = clk_pllxc_set_rate,
 };
 
-const struct clk_ops tegra_clk_pllm_ops = {
+static const struct clk_ops tegra_clk_pllm_ops = {
 	.is_enabled = clk_pll_is_enabled,
 	.enable = clk_pll_iddq_enable,
 	.disable = clk_pll_iddq_disable,
@@ -1451,7 +1451,7 @@ const struct clk_ops tegra_clk_pllm_ops = {
 	.set_rate = clk_pllm_set_rate,
 };
 
-const struct clk_ops tegra_clk_pllc_ops = {
+static const struct clk_ops tegra_clk_pllc_ops = {
 	.is_enabled = clk_pll_is_enabled,
 	.enable = clk_pllc_enable,
 	.disable = clk_pllc_disable,
@@ -1460,7 +1460,7 @@ const struct clk_ops tegra_clk_pllc_ops = {
 	.set_rate = clk_pllc_set_rate,
 };
 
-const struct clk_ops tegra_clk_pllre_ops = {
+static const struct clk_ops tegra_clk_pllre_ops = {
 	.is_enabled = clk_pll_is_enabled,
 	.enable = clk_pll_iddq_enable,
 	.disable = clk_pll_iddq_disable,
@@ -1469,7 +1469,7 @@ const struct clk_ops tegra_clk_pllre_ops = {
 	.set_rate = clk_pllre_set_rate,
 };
 
-const struct clk_ops tegra_clk_plle_tegra114_ops = {
+static const struct clk_ops tegra_clk_plle_tegra114_ops = {
 	.is_enabled =  clk_pll_is_enabled,
 	.enable = clk_plle_tegra114_enable,
 	.disable = clk_plle_tegra114_disable,
@@ -1731,7 +1731,7 @@ struct clk *tegra_clk_register_plle_tegra114(const char *name,
 #endif
 
 #ifdef CONFIG_ARCH_TEGRA_124_SOC
-const struct clk_ops tegra_clk_pllss_ops = {
+static const struct clk_ops tegra_clk_pllss_ops = {
 	.is_enabled = clk_pll_is_enabled,
 	.enable = clk_pll_iddq_enable,
 	.disable = clk_pll_iddq_disable,
-- 
1.8.3.2

^ permalink raw reply related	[flat|nested] 23+ messages in thread

* [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h
  2013-12-05 11:27 ` [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
@ 2013-12-20  1:59   ` Mike Turquette
  2013-12-20  3:58     ` Sachin Kamat
  0 siblings, 1 reply; 23+ messages in thread
From: Mike Turquette @ 2013-12-20  1:59 UTC (permalink / raw)
  To: linux-arm-kernel

Quoting Sachin Kamat (2013-12-05 03:27:15)
> On 8 October 2013 16:47, Sachin Kamat <sachin.kamat@linaro.org> wrote:
> > clk-provider.h was included twice.
> >
> > Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
> > ---
> > Added all the acquired acks to respective patches.
> > ---
> >  drivers/clk/clk-bcm2835.c |    1 -
> >  1 file changed, 1 deletion(-)
> >
> > diff --git a/drivers/clk/clk-bcm2835.c b/drivers/clk/clk-bcm2835.c
> > index 5fb4ff5..676077d 100644
> > --- a/drivers/clk/clk-bcm2835.c
> > +++ b/drivers/clk/clk-bcm2835.c
> > @@ -20,7 +20,6 @@
> >  #include <linux/clk-provider.h>
> >  #include <linux/clkdev.h>
> >  #include <linux/clk/bcm2835.h>
> > -#include <linux/clk-provider.h>
> >  #include <linux/of.h>
> >
> >  static const struct of_device_id clk_match[] __initconst = {
> > --
> > 1.7.9.5
> >
> 
> Mike,
> 
> Any chance getting this series picked up?

Thanks for re-ping me on this! Taken into clk-next.

Regards,
Mike

> 
> -- 
> With warm regards,
> Sachin

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h
  2013-12-20  1:59   ` Mike Turquette
@ 2013-12-20  3:58     ` Sachin Kamat
  2013-12-23  7:59       ` Mike Turquette
  0 siblings, 1 reply; 23+ messages in thread
From: Sachin Kamat @ 2013-12-20  3:58 UTC (permalink / raw)
  To: linux-arm-kernel

On 20 December 2013 07:29, Mike Turquette <mturquette@linaro.org> wrote:
>>
>> Mike,
>>
>> Any chance getting this series picked up?
>
> Thanks for re-ping me on this! Taken into clk-next.

Thanks Mike. But the below patch seems missing in your tree.
http://permalink.gmane.org/gmane.linux.ports.arm.kernel/271627

-- 
With warm regards,
Sachin

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h
  2013-12-20  3:58     ` Sachin Kamat
@ 2013-12-23  7:59       ` Mike Turquette
  0 siblings, 0 replies; 23+ messages in thread
From: Mike Turquette @ 2013-12-23  7:59 UTC (permalink / raw)
  To: linux-arm-kernel

Quoting Sachin Kamat (2013-12-19 19:58:24)
> On 20 December 2013 07:29, Mike Turquette <mturquette@linaro.org> wrote:
> >>
> >> Mike,
> >>
> >> Any chance getting this series picked up?
> >
> > Thanks for re-ping me on this! Taken into clk-next.
> 
> Thanks Mike. But the below patch seems missing in your tree.
> http://permalink.gmane.org/gmane.linux.ports.arm.kernel/271627

Oops. Strange. Thanks for the catch. Applied.

Regards,
Mike

> 
> -- 
> With warm regards,
> Sachin

^ permalink raw reply	[flat|nested] 23+ messages in thread

* [PATCH 10/10] clk: max77686: Remove redundant break
  2013-09-13  9:23 [PATCH " Sachin Kamat
@ 2013-09-13  9:23 ` Sachin Kamat
  0 siblings, 0 replies; 23+ messages in thread
From: Sachin Kamat @ 2013-09-13  9:23 UTC (permalink / raw)
  To: linux-arm-kernel

'break' after 'goto' is redundant. Remove it.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Jonghwa Lee <jonghwa3.lee@samsung.com>
---
 drivers/clk/clk-max77686.c |    2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/clk/clk-max77686.c b/drivers/clk/clk-max77686.c
index 9f57bc3..b4a1a97 100644
--- a/drivers/clk/clk-max77686.c
+++ b/drivers/clk/clk-max77686.c
@@ -157,11 +157,9 @@ static int max77686_clk_probe(struct platform_device *pdev)
 			case MAX77686_CLK_AP:
 				dev_err(&pdev->dev, "Fail to register CLK_AP\n");
 				goto err_clk_ap;
-				break;
 			case MAX77686_CLK_CP:
 				dev_err(&pdev->dev, "Fail to register CLK_CP\n");
 				goto err_clk_cp;
-				break;
 			case MAX77686_CLK_PMIC:
 				dev_err(&pdev->dev, "Fail to register CLK_PMIC\n");
 				goto err_clk_pmic;
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2013-12-23  7:59 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-08 11:17 [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
2013-10-08 11:17 ` [PATCH 02/10] clk: SPEAr: Staticize clk_frac_ops Sachin Kamat
2013-10-08 11:17 ` [PATCH 03/10] clk: tegra: Staticize local variables in clk-pll.c Sachin Kamat
2013-10-08 16:09   ` Stephen Warren
2013-10-10 11:13     ` Peter De Schrijver
2013-10-10 16:07       ` Stephen Warren
2013-10-14  8:15         ` Peter De Schrijver
2013-10-14 16:35           ` Stephen Warren
2013-10-15  8:29             ` Peter De Schrijver
2013-10-15 15:10               ` Stephen Warren
2013-12-20  1:53   ` Mike Turquette
2013-10-08 11:17 ` [PATCH 04/10] clk: tegra: Staticize tegra_clk_periph_nodiv_ops Sachin Kamat
2013-10-08 11:17 ` [PATCH 05/10] clk: socfpga: Use NULL instead of 0 Sachin Kamat
2013-10-08 11:17 ` [PATCH 06/10] clk: versatile: Staticize clk_sp810_timerclken_of_get Sachin Kamat
2013-10-08 11:17 ` [PATCH 07/10] clk: mvebu: Staticize of_cpu_clk_setup Sachin Kamat
2013-10-08 11:17 ` [PATCH 08/10] clk: vt8500: Staticize vtwm_pll_ops Sachin Kamat
2013-10-08 11:17 ` [PATCH 09/10] clk: ux500: Remove extra semicolon Sachin Kamat
2013-10-08 11:17 ` [PATCH 10/10] clk: max77686: Remove redundant break Sachin Kamat
2013-12-05 11:27 ` [PATCH Resend 01/10] clk: bcm2835: Remove duplicate inclusion of clk-provider.h Sachin Kamat
2013-12-20  1:59   ` Mike Turquette
2013-12-20  3:58     ` Sachin Kamat
2013-12-23  7:59       ` Mike Turquette
  -- strict thread matches above, loose matches on Subject: below --
2013-09-13  9:23 [PATCH " Sachin Kamat
2013-09-13  9:23 ` [PATCH 10/10] clk: max77686: Remove redundant break Sachin Kamat

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.