[PATCH v2 36/62] treewide: rename pinctrl_gpio_can_use_line_new()

From: Bartosz Golaszewski
Date: Wed Oct 11 2023 - 08:12:37 EST


From: Bartosz Golaszewski <bartosz.golaszewski@xxxxxxxxxx>

Now that pinctrl_gpio_can_use_line() is no longer used, let's drop the
'_new' suffix from its improved variant.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@xxxxxxxxxx>
---
drivers/gpio/gpiolib-cdev.c | 2 +-
drivers/pinctrl/core.c | 4 ++--
include/linux/pinctrl/consumer.h | 4 ++--
3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/gpio/gpiolib-cdev.c b/drivers/gpio/gpiolib-cdev.c
index 54ee075410db..02ffda6c1e51 100644
--- a/drivers/gpio/gpiolib-cdev.c
+++ b/drivers/gpio/gpiolib-cdev.c
@@ -2287,7 +2287,7 @@ static void gpio_desc_to_lineinfo(struct gpio_desc *desc,
* FIXME: find a non-racy way to retrieve this information. Maybe a
* lock common to both frameworks?
*/
- ok_for_pinctrl = pinctrl_gpio_can_use_line_new(gc, info->offset);
+ ok_for_pinctrl = pinctrl_gpio_can_use_line(gc, info->offset);

spin_lock_irqsave(&gpio_lock, flags);

diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c
index 99514119c2bd..2c8d0ef798f5 100644
--- a/drivers/pinctrl/core.c
+++ b/drivers/pinctrl/core.c
@@ -755,7 +755,7 @@ int pinctrl_get_group_selector(struct pinctrl_dev *pctldev,
return -EINVAL;
}

-bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offset)
+bool pinctrl_gpio_can_use_line(struct gpio_chip *gc, unsigned int offset)
{
struct pinctrl_dev *pctldev;
struct pinctrl_gpio_range *range;
@@ -781,7 +781,7 @@ bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offset)

return result;
}
-EXPORT_SYMBOL_GPL(pinctrl_gpio_can_use_line_new);
+EXPORT_SYMBOL_GPL(pinctrl_gpio_can_use_line);

/**
* pinctrl_gpio_request_new() - request a single pin to be used as GPIO
diff --git a/include/linux/pinctrl/consumer.h b/include/linux/pinctrl/consumer.h
index bcd09f584525..220f69f342e1 100644
--- a/include/linux/pinctrl/consumer.h
+++ b/include/linux/pinctrl/consumer.h
@@ -26,7 +26,7 @@ struct pinctrl_state;
#ifdef CONFIG_PINCTRL

/* External interface to pin control */
-bool pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offset);
+bool pinctrl_gpio_can_use_line(struct gpio_chip *gc, unsigned int offset);
int pinctrl_gpio_request_new(struct gpio_chip *gc, unsigned int offset);
void pinctrl_gpio_free_new(struct gpio_chip *gc, unsigned int offset);
int pinctrl_gpio_direction_input_new(struct gpio_chip *gc,
@@ -73,7 +73,7 @@ static inline bool pinctrl_gpio_can_use_line(unsigned gpio)
}

static inline bool
-pinctrl_gpio_can_use_line_new(struct gpio_chip *gc, unsigned int offset)
+pinctrl_gpio_can_use_line(struct gpio_chip *gc, unsigned int offset)
{
return true;
}
--
2.39.2