linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH -next] regulator: bd718x7: Make some variable static
@ 2020-09-10  3:42 YueHaibing
  2020-09-10  5:01 ` Vaittinen, Matti
  2020-09-10 12:51 ` Mark Brown
  0 siblings, 2 replies; 3+ messages in thread
From: YueHaibing @ 2020-09-10  3:42 UTC (permalink / raw)
  To: matti.vaittinen, lgirdwood, broonie; +Cc: linux-power, linux-kernel, YueHaibing

Fix sparse warnings:

drivers/regulator/bd718x7-regulator.c:576:28: warning: symbol 'bd71847_swcontrol_ops' was not declared. Should it be static?
drivers/regulator/bd718x7-regulator.c:585:28: warning: symbol 'bd71847_hwcontrol_ops' was not declared. Should it be static?
drivers/regulator/bd718x7-regulator.c:902:28: warning: symbol 'bd71837_swcontrol_ops' was not declared. Should it be static?
drivers/regulator/bd718x7-regulator.c:913:28: warning: symbol 'bd71837_hwcontrol_ops' was not declared. Should it be static?

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/regulator/bd718x7-regulator.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/regulator/bd718x7-regulator.c b/drivers/regulator/bd718x7-regulator.c
index 159c917b9c4c..0774467994fb 100644
--- a/drivers/regulator/bd718x7-regulator.c
+++ b/drivers/regulator/bd718x7-regulator.c
@@ -573,7 +573,7 @@ static int buck_set_hw_dvs_levels(struct device_node *np,
 	return rohm_regulator_set_dvs_levels(&data->dvs, np, desc, cfg->regmap);
 }
 
-const struct regulator_ops *bd71847_swcontrol_ops[] = {
+static const struct regulator_ops *bd71847_swcontrol_ops[] = {
 	&bd718xx_dvs_buck_regulator_ops, &bd718xx_dvs_buck_regulator_ops,
 	&bd718xx_pickable_range_buck_ops, &bd718xx_pickable_range_buck_ops,
 	&bd718xx_buck_regulator_nolinear_ops, &bd718xx_buck_regulator_ops,
@@ -582,7 +582,7 @@ const struct regulator_ops *bd71847_swcontrol_ops[] = {
 	&bd718xx_pickable_range_ldo_ops, &bd718xx_ldo_regulator_ops,
 };
 
-const struct regulator_ops *bd71847_hwcontrol_ops[] = {
+static const struct regulator_ops *bd71847_hwcontrol_ops[] = {
 	&BD718XX_HWOPNAME(bd718xx_dvs_buck_regulator_ops),
 	&BD718XX_HWOPNAME(bd718xx_dvs_buck_regulator_ops),
 	&BD718XX_HWOPNAME(bd718xx_pickable_range_buck_ops),
@@ -899,7 +899,7 @@ static struct bd718xx_regulator_data bd71847_regulators[] = {
 	},
 };
 
-const struct regulator_ops *bd71837_swcontrol_ops[] = {
+static const struct regulator_ops *bd71837_swcontrol_ops[] = {
 	&bd718xx_dvs_buck_regulator_ops, &bd718xx_dvs_buck_regulator_ops,
 	&bd718xx_dvs_buck_regulator_ops, &bd718xx_dvs_buck_regulator_ops,
 	&bd71837_pickable_range_buck_ops, &bd71837_buck_regulator_ops,
@@ -910,7 +910,7 @@ const struct regulator_ops *bd71837_swcontrol_ops[] = {
 	&bd71837_ldo_regulator_ops,
 };
 
-const struct regulator_ops *bd71837_hwcontrol_ops[] = {
+static const struct regulator_ops *bd71837_hwcontrol_ops[] = {
 	&BD718XX_HWOPNAME(bd718xx_dvs_buck_regulator_ops),
 	&BD718XX_HWOPNAME(bd718xx_dvs_buck_regulator_ops),
 	&bd71837_buck34_ops_hwctrl, &bd71837_buck34_ops_hwctrl,
-- 
2.17.1



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

* Re: [PATCH -next] regulator: bd718x7: Make some variable static
  2020-09-10  3:42 [PATCH -next] regulator: bd718x7: Make some variable static YueHaibing
@ 2020-09-10  5:01 ` Vaittinen, Matti
  2020-09-10 12:51 ` Mark Brown
  1 sibling, 0 replies; 3+ messages in thread
From: Vaittinen, Matti @ 2020-09-10  5:01 UTC (permalink / raw)
  To: yuehaibing, lgirdwood, broonie; +Cc: linux-power, linux-kernel


On Thu, 2020-09-10 at 11:42 +0800, YueHaibing wrote:
> Fix sparse warnings:
> 
> drivers/regulator/bd718x7-regulator.c:576:28: warning: symbol
> 'bd71847_swcontrol_ops' was not declared. Should it be static?
> drivers/regulator/bd718x7-regulator.c:585:28: warning: symbol
> 'bd71847_hwcontrol_ops' was not declared. Should it be static?
> drivers/regulator/bd718x7-regulator.c:902:28: warning: symbol
> 'bd71837_swcontrol_ops' was not declared. Should it be static?
> drivers/regulator/bd718x7-regulator.c:913:28: warning: symbol
> 'bd71837_hwcontrol_ops' was not declared. Should it be static?
> 
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>

Acked-By: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>

Thanks for taking care of this!

> ---
>  drivers/regulator/bd718x7-regulator.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/regulator/bd718x7-regulator.c
> b/drivers/regulator/bd718x7-regulator.c
> index 159c917b9c4c..0774467994fb 100644
> --- a/drivers/regulator/bd718x7-regulator.c
> +++ b/drivers/regulator/bd718x7-regulator.c
> @@ -573,7 +573,7 @@ static int buck_set_hw_dvs_levels(struct
> device_node *np,
>  	return rohm_regulator_set_dvs_levels(&data->dvs, np, desc, cfg-
> >regmap);
>  }
>  
> -const struct regulator_ops *bd71847_swcontrol_ops[] = {
> +static const struct regulator_ops *bd71847_swcontrol_ops[] = {
>  	&bd718xx_dvs_buck_regulator_ops,
> &bd718xx_dvs_buck_regulator_ops,
>  	&bd718xx_pickable_range_buck_ops,
> &bd718xx_pickable_range_buck_ops,
>  	&bd718xx_buck_regulator_nolinear_ops,
> &bd718xx_buck_regulator_ops,
> @@ -582,7 +582,7 @@ const struct regulator_ops
> *bd71847_swcontrol_ops[] = {
>  	&bd718xx_pickable_range_ldo_ops, &bd718xx_ldo_regulator_ops,
>  };
>  
> -const struct regulator_ops *bd71847_hwcontrol_ops[] = {
> +static const struct regulator_ops *bd71847_hwcontrol_ops[] = {
>  	&BD718XX_HWOPNAME(bd718xx_dvs_buck_regulator_ops),
>  	&BD718XX_HWOPNAME(bd718xx_dvs_buck_regulator_ops),
>  	&BD718XX_HWOPNAME(bd718xx_pickable_range_buck_ops),
> @@ -899,7 +899,7 @@ static struct bd718xx_regulator_data
> bd71847_regulators[] = {
>  	},
>  };
>  
> -const struct regulator_ops *bd71837_swcontrol_ops[] = {
> +static const struct regulator_ops *bd71837_swcontrol_ops[] = {
>  	&bd718xx_dvs_buck_regulator_ops,
> &bd718xx_dvs_buck_regulator_ops,
>  	&bd718xx_dvs_buck_regulator_ops,
> &bd718xx_dvs_buck_regulator_ops,
>  	&bd71837_pickable_range_buck_ops, &bd71837_buck_regulator_ops,
> @@ -910,7 +910,7 @@ const struct regulator_ops
> *bd71837_swcontrol_ops[] = {
>  	&bd71837_ldo_regulator_ops,
>  };
>  
> -const struct regulator_ops *bd71837_hwcontrol_ops[] = {
> +static const struct regulator_ops *bd71837_hwcontrol_ops[] = {
>  	&BD718XX_HWOPNAME(bd718xx_dvs_buck_regulator_ops),
>  	&BD718XX_HWOPNAME(bd718xx_dvs_buck_regulator_ops),
>  	&bd71837_buck34_ops_hwctrl, &bd71837_buck34_ops_hwctrl,


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

* Re: [PATCH -next] regulator: bd718x7: Make some variable static
  2020-09-10  3:42 [PATCH -next] regulator: bd718x7: Make some variable static YueHaibing
  2020-09-10  5:01 ` Vaittinen, Matti
@ 2020-09-10 12:51 ` Mark Brown
  1 sibling, 0 replies; 3+ messages in thread
From: Mark Brown @ 2020-09-10 12:51 UTC (permalink / raw)
  To: YueHaibing, matti.vaittinen, lgirdwood; +Cc: linux-power, linux-kernel

On Thu, 10 Sep 2020 11:42:40 +0800, YueHaibing wrote:
> Fix sparse warnings:
> 
> drivers/regulator/bd718x7-regulator.c:576:28: warning: symbol 'bd71847_swcontrol_ops' was not declared. Should it be static?
> drivers/regulator/bd718x7-regulator.c:585:28: warning: symbol 'bd71847_hwcontrol_ops' was not declared. Should it be static?
> drivers/regulator/bd718x7-regulator.c:902:28: warning: symbol 'bd71837_swcontrol_ops' was not declared. Should it be static?
> drivers/regulator/bd718x7-regulator.c:913:28: warning: symbol 'bd71837_hwcontrol_ops' was not declared. Should it be static?

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next

Thanks!

[1/1] regulator: bd718x7: Make some variable static
      commit: 02f8eaab0cb644478c170237f354db32b718e5ff

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

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

end of thread, other threads:[~2020-09-10 12:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-10  3:42 [PATCH -next] regulator: bd718x7: Make some variable static YueHaibing
2020-09-10  5:01 ` Vaittinen, Matti
2020-09-10 12:51 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).