[PATCH v1 3/3] gpiolib: Rename gpio_do_set_config() --> gpiod_do_set_config()

Andy Shevchenko
2025-03-03T16:03:49Z

In order to reduce the 'gpio' namespace when operate over GPIO descriptor
rename gpio_do_set_config() to gpiod_do_set_config().

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
drivers/gpio/gpiolib-cdev.c | 2 +-
drivers/gpio/gpiolib.c | 6 +++---
drivers/gpio/gpiolib.h | 2 +-
3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/gpio/gpiolib-cdev.c b/drivers/gpio/gpiolib-cdev.c
index c8b7499a1e6e..68b6e27ce6ef 100644
--- a/drivers/gpio/gpiolib-cdev.c
+++ b/drivers/gpio/gpiolib-cdev.c
@@ -927,7 +927,7 @@ static int debounce_setup(struct line *line, unsigned int debounce_period_us)
* Try hardware. Skip gpiod_set_config() to avoid emitting two
* CHANGED_CONFIG line state events.
*/
- ret = gpio_do_set_config(line->desc,
+ ret = gpiod_do_set_config(line->desc,
pinconf_to_config_packed(PIN_CONFIG_INPUT_DEBOUNCE,
debounce_period_us));
if (ret != -ENOTSUPP)
diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c
index 8980eef6802c..efaf34a30c20 100644
--- a/drivers/gpio/gpiolib.c
+++ b/drivers/gpio/gpiolib.c
@@ -2599,7 +2599,7 @@ EXPORT_SYMBOL_GPL(gpiochip_free_own_desc);
* rely on gpio_request() having been called beforehand.
*/

-int gpio_do_set_config(struct gpio_desc *desc, unsigned long config)
+int gpiod_do_set_config(struct gpio_desc *desc, unsigned long config)
{
int ret;

@@ -2634,7 +2634,7 @@ static int gpio_set_config_with_argument(struct gpio_desc *desc,
unsigned long config;

config = pinconf_to_config_packed(mode, argument);
- return gpio_do_set_config(desc, config);
+ return gpiod_do_set_config(desc, config);
}

static int gpio_set_config_with_argument_optional(struct gpio_desc *desc,
@@ -3104,7 +3104,7 @@ int gpiod_set_config(struct gpio_desc *desc, unsigned long config)

VALIDATE_DESC(desc);

- ret = gpio_do_set_config(desc, config);
+ ret = gpiod_do_set_config(desc, config);
if (ret)
return ret;

diff --git a/drivers/gpio/gpiolib.h b/drivers/gpio/gpiolib.h
index b3ea7b710995..4f603a530d38 100644
--- a/drivers/gpio/gpiolib.h
+++ b/drivers/gpio/gpiolib.h
@@ -260,7 +260,7 @@ struct gpio_desc *gpiod_find_and_request(struct device *consumer,
const char *label,
bool platform_lookup_allowed);

-int gpio_do_set_config(struct gpio_desc *desc, unsigned long config);
+int gpiod_do_set_config(struct gpio_desc *desc, unsigned long config);
int gpiod_configure_flags(struct gpio_desc *desc, const char *con_id,
unsigned long lflags, enum gpiod_flags dflags);
int gpiod_do_set_debounce(struct gpio_desc *desc, unsigned int debounce);
--
2.47.2