diff mbox series

[-next] pwm: make pwm_apply_state_debug static

Message ID 20200402065718.32433-1-yanaijie@huawei.com
State Accepted
Headers show
Series [-next] pwm: make pwm_apply_state_debug static | expand

Commit Message

Jason Yan April 2, 2020, 6:57 a.m. UTC
Fix the following gcc warning:

drivers/pwm/core.c:467:6: warning: symbol 'pwm_apply_state_debug' was
not declared. Should it be static?

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Jason Yan <yanaijie@huawei.com>
---
 drivers/pwm/core.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Uwe Kleine-König April 2, 2020, 2:10 p.m. UTC | #1
On Thu, Apr 02, 2020 at 02:57:18PM +0800, Jason Yan wrote:
> Fix the following gcc warning:
> 
> drivers/pwm/core.c:467:6: warning: symbol 'pwm_apply_state_debug' was
> not declared. Should it be static?
> 
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Jason Yan <yanaijie@huawei.com>

Looks sensible:

Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Fixes: 3ad1f3a33286 ("pwm: Implement some checks for lowlevel drivers")

Thanks
Uwe
Thierry Reding April 3, 2020, 7:43 p.m. UTC | #2
On Thu, Apr 02, 2020 at 02:57:18PM +0800, Jason Yan wrote:
> Fix the following gcc warning:
> 
> drivers/pwm/core.c:467:6: warning: symbol 'pwm_apply_state_debug' was
> not declared. Should it be static?
> 
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Jason Yan <yanaijie@huawei.com>
> ---
>  drivers/pwm/core.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

Applied, thanks.

Thierry
diff mbox series

Patch

diff --git a/drivers/pwm/core.c b/drivers/pwm/core.c
index e9b9283cff28..9973c442b455 100644
--- a/drivers/pwm/core.c
+++ b/drivers/pwm/core.c
@@ -464,8 +464,8 @@  void pwm_free(struct pwm_device *pwm)
 }
 EXPORT_SYMBOL_GPL(pwm_free);
 
-void pwm_apply_state_debug(struct pwm_device *pwm,
-			   const struct pwm_state *state)
+static void pwm_apply_state_debug(struct pwm_device *pwm,
+				  const struct pwm_state *state)
 {
 	struct pwm_state *last = &pwm->last;
 	struct pwm_chip *chip = pwm->chip;