Message ID | 20210120093040.1719407-8-lee.jones@linaro.org (mailing list archive) |
---|---|
State | Accepted, archived |
Headers | show |
Series | Rid W=1 warnings from Clock | expand |
On 1/20/21 3:30 AM, Lee Jones wrote: > Fixes the following W=1 kernel build warning(s): > > drivers/clk/socfpga/clk-pll.c: In function ‘__socfpga_pll_init’: > drivers/clk/socfpga/clk-pll.c:83:6: warning: variable ‘rc’ set but not used [-Wunused-but-set-variable] > > Cc: Dinh Nguyen <dinguyen@kernel.org> > Cc: Michael Turquette <mturquette@baylibre.com> > Cc: Stephen Boyd <sboyd@kernel.org> > Cc: linux-clk@vger.kernel.org > Signed-off-by: Lee Jones <lee.jones@linaro.org> > --- > drivers/clk/socfpga/clk-pll.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/clk/socfpga/clk-pll.c b/drivers/clk/socfpga/clk-pll.c > index e5fb786843f39..3cf99df7d0056 100644 > --- a/drivers/clk/socfpga/clk-pll.c > +++ b/drivers/clk/socfpga/clk-pll.c > @@ -80,7 +80,6 @@ static __init struct clk *__socfpga_pll_init(struct device_node *node, > const char *parent_name[SOCFPGA_MAX_PARENTS]; > struct clk_init_data init; > struct device_node *clkmgr_np; > - int rc; > > of_property_read_u32(node, "reg", ®); > > @@ -111,7 +110,7 @@ static __init struct clk *__socfpga_pll_init(struct device_node *node, > kfree(pll_clk); > return NULL; > } > - rc = of_clk_add_provider(node, of_clk_src_simple_get, clk); > + of_clk_add_provider(node, of_clk_src_simple_get, clk); > return clk; > } > > Acked-by: Dinh Nguyen <dinguyen@kernel.org>
Quoting Lee Jones (2021-01-20 01:30:27) > Fixes the following W=1 kernel build warning(s): > > drivers/clk/socfpga/clk-pll.c: In function ‘__socfpga_pll_init’: > drivers/clk/socfpga/clk-pll.c:83:6: warning: variable ‘rc’ set but not used [-Wunused-but-set-variable] > > Cc: Dinh Nguyen <dinguyen@kernel.org> > Cc: Michael Turquette <mturquette@baylibre.com> > Cc: Stephen Boyd <sboyd@kernel.org> > Cc: linux-clk@vger.kernel.org > Signed-off-by: Lee Jones <lee.jones@linaro.org> > --- Applied to clk-next
diff --git a/drivers/clk/socfpga/clk-pll.c b/drivers/clk/socfpga/clk-pll.c index e5fb786843f39..3cf99df7d0056 100644 --- a/drivers/clk/socfpga/clk-pll.c +++ b/drivers/clk/socfpga/clk-pll.c @@ -80,7 +80,6 @@ static __init struct clk *__socfpga_pll_init(struct device_node *node, const char *parent_name[SOCFPGA_MAX_PARENTS]; struct clk_init_data init; struct device_node *clkmgr_np; - int rc; of_property_read_u32(node, "reg", ®); @@ -111,7 +110,7 @@ static __init struct clk *__socfpga_pll_init(struct device_node *node, kfree(pll_clk); return NULL; } - rc = of_clk_add_provider(node, of_clk_src_simple_get, clk); + of_clk_add_provider(node, of_clk_src_simple_get, clk); return clk; }
Fixes the following W=1 kernel build warning(s): drivers/clk/socfpga/clk-pll.c: In function ‘__socfpga_pll_init’: drivers/clk/socfpga/clk-pll.c:83:6: warning: variable ‘rc’ set but not used [-Wunused-but-set-variable] Cc: Dinh Nguyen <dinguyen@kernel.org> Cc: Michael Turquette <mturquette@baylibre.com> Cc: Stephen Boyd <sboyd@kernel.org> Cc: linux-clk@vger.kernel.org Signed-off-by: Lee Jones <lee.jones@linaro.org> --- drivers/clk/socfpga/clk-pll.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)