2019-12-20 09:28:29

by Chen Wandun

[permalink] [raw]
Subject: [PATCH next] power: suppy: ucs1002: Make the symbol 'ucs1002_regulator_enable' static

Fix the following sparse warning:

drivers/power/supply/ucs1002_power.c:492:5: warning: symbol 'ucs1002_regulator_enable' was not declared. Should it be static?

Fixes: a3d70dacc727 ("power: suppy: ucs1002: disable power when maxcurrent is 0")
Signed-off-by: Chen Wandun <[email protected]>
---
drivers/power/supply/ucs1002_power.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/power/supply/ucs1002_power.c b/drivers/power/supply/ucs1002_power.c
index 0ca80d00b80a..cdb9a23d825f 100644
--- a/drivers/power/supply/ucs1002_power.c
+++ b/drivers/power/supply/ucs1002_power.c
@@ -489,7 +489,7 @@ static irqreturn_t ucs1002_alert_irq(int irq, void *data)
return IRQ_HANDLED;
}

-int ucs1002_regulator_enable(struct regulator_dev *rdev)
+static int ucs1002_regulator_enable(struct regulator_dev *rdev)
{
struct ucs1002_info *info = rdev_get_drvdata(rdev);

--
2.17.1


2020-01-15 21:31:16

by Sebastian Reichel

[permalink] [raw]
Subject: Re: [PATCH next] power: suppy: ucs1002: Make the symbol 'ucs1002_regulator_enable' static

Hi,

Thanks, queued.

-- Sebastian

On Fri, Dec 20, 2019 at 05:41:44PM +0800, Chen Wandun wrote:
> Fix the following sparse warning:
>
> drivers/power/supply/ucs1002_power.c:492:5: warning: symbol 'ucs1002_regulator_enable' was not declared. Should it be static?
>
> Fixes: a3d70dacc727 ("power: suppy: ucs1002: disable power when maxcurrent is 0")
> Signed-off-by: Chen Wandun <[email protected]>
> ---
> drivers/power/supply/ucs1002_power.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/power/supply/ucs1002_power.c b/drivers/power/supply/ucs1002_power.c
> index 0ca80d00b80a..cdb9a23d825f 100644
> --- a/drivers/power/supply/ucs1002_power.c
> +++ b/drivers/power/supply/ucs1002_power.c
> @@ -489,7 +489,7 @@ static irqreturn_t ucs1002_alert_irq(int irq, void *data)
> return IRQ_HANDLED;
> }
>
> -int ucs1002_regulator_enable(struct regulator_dev *rdev)
> +static int ucs1002_regulator_enable(struct regulator_dev *rdev)
> {
> struct ucs1002_info *info = rdev_get_drvdata(rdev);
>
> --
> 2.17.1
>


Attachments:
(No filename) (1.06 kB)
signature.asc (849.00 B)
Download all attachments