staging: greybus: pwm: Consistently name pwm_chip variables "chip"
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Fri, 14 Jul 2023 20:56:23 +0000 (22:56 +0200)
committerThierry Reding <thierry.reding@gmail.com>
Fri, 21 Jul 2023 18:23:32 +0000 (20:23 +0200)
All function parameters of type pointer to struct pwm_chip in this
driver are called chip which is also the usual name of function
parameters and local variables in most other PWM drivers. For
consistency use the same name for the local variable of that type.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Reviewed-by: Alex Elder <elder@linaro.org>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
drivers/staging/greybus/pwm.c

index 88da1d796f132d2a63926094f12249b440322fda..c483e1f0738e6285a5674eca079836beee18cdaa 100644 (file)
@@ -267,7 +267,7 @@ static int gb_pwm_probe(struct gbphy_device *gbphy_dev,
 {
        struct gb_connection *connection;
        struct gb_pwm_chip *pwmc;
-       struct pwm_chip *pwm;
+       struct pwm_chip *chip;
        int ret;
 
        pwmc = kzalloc(sizeof(*pwmc), GFP_KERNEL);
@@ -295,13 +295,13 @@ static int gb_pwm_probe(struct gbphy_device *gbphy_dev,
        if (ret)
                goto exit_connection_disable;
 
-       pwm = &pwmc->chip;
+       chip = &pwmc->chip;
 
-       pwm->dev = &gbphy_dev->dev;
-       pwm->ops = &gb_pwm_ops;
-       pwm->npwm = pwmc->pwm_max + 1;
+       chip->dev = &gbphy_dev->dev;
+       chip->ops = &gb_pwm_ops;
+       chip->npwm = pwmc->pwm_max + 1;
 
-       ret = pwmchip_add(pwm);
+       ret = pwmchip_add(chip);
        if (ret) {
                dev_err(&gbphy_dev->dev,
                        "failed to register PWM: %d\n", ret);