* [PATCH 01/12] gpio: dln2: use new line value setter callbacks
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-07 8:50 ` Andy Shevchenko
2025-04-07 7:13 ` [PATCH 02/12] gpio: eic-sprd: " Bartosz Golaszewski
` (11 subsequent siblings)
12 siblings, 1 reply; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
struct gpio_chip now has callbacks for setting line values that return
an integer, allowing to indicate failures. Convert the driver to using
them.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/gpio-dln2.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/gpio/gpio-dln2.c b/drivers/gpio/gpio-dln2.c
index 596da59d4b13..4bd3c47eaf93 100644
--- a/drivers/gpio/gpio-dln2.c
+++ b/drivers/gpio/gpio-dln2.c
@@ -220,11 +220,12 @@ static int dln2_gpio_get(struct gpio_chip *chip, unsigned int offset)
return dln2_gpio_pin_get_out_val(dln2, offset);
}
-static void dln2_gpio_set(struct gpio_chip *chip, unsigned offset, int value)
+static int dln2_gpio_set(struct gpio_chip *chip, unsigned int offset,
+ int value)
{
struct dln2_gpio *dln2 = gpiochip_get_data(chip);
- dln2_gpio_pin_set_out_val(dln2, offset, value);
+ return dln2_gpio_pin_set_out_val(dln2, offset, value);
}
static int dln2_gpio_set_direction(struct gpio_chip *chip, unsigned offset,
@@ -468,7 +469,7 @@ static int dln2_gpio_probe(struct platform_device *pdev)
dln2->gpio.base = -1;
dln2->gpio.ngpio = pins;
dln2->gpio.can_sleep = true;
- dln2->gpio.set = dln2_gpio_set;
+ dln2->gpio.set_rv = dln2_gpio_set;
dln2->gpio.get = dln2_gpio_get;
dln2->gpio.request = dln2_gpio_request;
dln2->gpio.free = dln2_gpio_free;
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* Re: [PATCH 01/12] gpio: dln2: use new line value setter callbacks
2025-04-07 7:13 ` [PATCH 01/12] gpio: dln2: use new line value setter callbacks Bartosz Golaszewski
@ 2025-04-07 8:50 ` Andy Shevchenko
0 siblings, 0 replies; 26+ messages in thread
From: Andy Shevchenko @ 2025-04-07 8:50 UTC (permalink / raw)
To: Bartosz Golaszewski
Cc: Linus Walleij, Orson Zhai, Baolin Wang, Chunyan Zhang,
Peter Tyser, linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, Apr 07, 2025 at 09:13:10AM +0200, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> struct gpio_chip now has callbacks for setting line values that return
> an integer, allowing to indicate failures. Convert the driver to using
> them.
...
> -static void dln2_gpio_set(struct gpio_chip *chip, unsigned offset, int value)
> +static int dln2_gpio_set(struct gpio_chip *chip, unsigned int offset,
> + int value)
It gets even shorter. If you are fan of 80 characters from last decade,
it still fits.
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 26+ messages in thread
* [PATCH 02/12] gpio: eic-sprd: use new line value setter callbacks
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
2025-04-07 7:13 ` [PATCH 01/12] gpio: dln2: use new line value setter callbacks Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-07 7:13 ` [PATCH 03/12] gpio: em: " Bartosz Golaszewski
` (10 subsequent siblings)
12 siblings, 0 replies; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
struct gpio_chip now has callbacks for setting line values that return
an integer, allowing to indicate failures. Convert the driver to using
them.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/gpio-eic-sprd.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/gpio/gpio-eic-sprd.c b/drivers/gpio/gpio-eic-sprd.c
index d4bf8d187e16..f2973d0b7138 100644
--- a/drivers/gpio/gpio-eic-sprd.c
+++ b/drivers/gpio/gpio-eic-sprd.c
@@ -203,9 +203,10 @@ static int sprd_eic_direction_input(struct gpio_chip *chip, unsigned int offset)
return 0;
}
-static void sprd_eic_set(struct gpio_chip *chip, unsigned int offset, int value)
+static int sprd_eic_set(struct gpio_chip *chip, unsigned int offset, int value)
{
/* EICs are always input, nothing need to do here. */
+ return 0;
}
static int sprd_eic_set_debounce(struct gpio_chip *chip, unsigned int offset,
@@ -662,7 +663,7 @@ static int sprd_eic_probe(struct platform_device *pdev)
sprd_eic->chip.request = sprd_eic_request;
sprd_eic->chip.free = sprd_eic_free;
sprd_eic->chip.set_config = sprd_eic_set_config;
- sprd_eic->chip.set = sprd_eic_set;
+ sprd_eic->chip.set_rv = sprd_eic_set;
fallthrough;
case SPRD_EIC_ASYNC:
case SPRD_EIC_SYNC:
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* [PATCH 03/12] gpio: em: use new line value setter callbacks
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
2025-04-07 7:13 ` [PATCH 01/12] gpio: dln2: use new line value setter callbacks Bartosz Golaszewski
2025-04-07 7:13 ` [PATCH 02/12] gpio: eic-sprd: " Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-07 7:13 ` [PATCH 04/12] gpio: exar: " Bartosz Golaszewski
` (9 subsequent siblings)
12 siblings, 0 replies; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
struct gpio_chip now has callbacks for setting line values that return
an integer, allowing to indicate failures. Convert the driver to using
them.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/gpio-em.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/gpio/gpio-em.c b/drivers/gpio/gpio-em.c
index 6c862c572322..857c28895131 100644
--- a/drivers/gpio/gpio-em.c
+++ b/drivers/gpio/gpio-em.c
@@ -204,13 +204,15 @@ static void __em_gio_set(struct gpio_chip *chip, unsigned int reg,
(BIT(shift + 16)) | (value << shift));
}
-static void em_gio_set(struct gpio_chip *chip, unsigned offset, int value)
+static int em_gio_set(struct gpio_chip *chip, unsigned int offset, int value)
{
/* output is split into two registers */
if (offset < 16)
__em_gio_set(chip, GIO_OL, offset, value);
else
__em_gio_set(chip, GIO_OH, offset - 16, value);
+
+ return 0;
}
static int em_gio_direction_output(struct gpio_chip *chip, unsigned offset,
@@ -304,7 +306,7 @@ static int em_gio_probe(struct platform_device *pdev)
gpio_chip->direction_input = em_gio_direction_input;
gpio_chip->get = em_gio_get;
gpio_chip->direction_output = em_gio_direction_output;
- gpio_chip->set = em_gio_set;
+ gpio_chip->set_rv = em_gio_set;
gpio_chip->to_irq = em_gio_to_irq;
gpio_chip->request = pinctrl_gpio_request;
gpio_chip->free = em_gio_free;
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* [PATCH 04/12] gpio: exar: use new line value setter callbacks
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
` (2 preceding siblings ...)
2025-04-07 7:13 ` [PATCH 03/12] gpio: em: " Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-07 8:51 ` Andy Shevchenko
2025-04-07 7:13 ` [PATCH 05/12] gpio: allow building port-mapped GPIO drivers with COMPILE_TEST=y Bartosz Golaszewski
` (8 subsequent siblings)
12 siblings, 1 reply; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
struct gpio_chip now has callbacks for setting line values that return
an integer, allowing to indicate failures. Convert the driver to using
them.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/gpio-exar.c | 16 +++++++++-------
1 file changed, 9 insertions(+), 7 deletions(-)
diff --git a/drivers/gpio/gpio-exar.c b/drivers/gpio/gpio-exar.c
index d5909a4f0433..beb98286d13e 100644
--- a/drivers/gpio/gpio-exar.c
+++ b/drivers/gpio/gpio-exar.c
@@ -93,8 +93,8 @@ static int exar_get_value(struct gpio_chip *chip, unsigned int offset)
return !!(regmap_test_bits(exar_gpio->regmap, addr, BIT(bit)));
}
-static void exar_set_value(struct gpio_chip *chip, unsigned int offset,
- int value)
+static int exar_set_value(struct gpio_chip *chip, unsigned int offset,
+ int value)
{
struct exar_gpio_chip *exar_gpio = gpiochip_get_data(chip);
unsigned int addr = exar_offset_to_lvl_addr(exar_gpio, offset);
@@ -105,7 +105,7 @@ static void exar_set_value(struct gpio_chip *chip, unsigned int offset,
* regmap_write_bits() forces value to be written when an external
* pull up/down might otherwise indicate value was already set.
*/
- regmap_write_bits(exar_gpio->regmap, addr, BIT(bit), bit_value);
+ return regmap_write_bits(exar_gpio->regmap, addr, BIT(bit), bit_value);
}
static int exar_direction_output(struct gpio_chip *chip, unsigned int offset,
@@ -114,11 +114,13 @@ static int exar_direction_output(struct gpio_chip *chip, unsigned int offset,
struct exar_gpio_chip *exar_gpio = gpiochip_get_data(chip);
unsigned int addr = exar_offset_to_sel_addr(exar_gpio, offset);
unsigned int bit = exar_offset_to_bit(exar_gpio, offset);
+ int ret;
- exar_set_value(chip, offset, value);
- regmap_clear_bits(exar_gpio->regmap, addr, BIT(bit));
+ ret = exar_set_value(chip, offset, value);
+ if (ret)
+ return ret;
- return 0;
+ return regmap_clear_bits(exar_gpio->regmap, addr, BIT(bit));
}
static int exar_direction_input(struct gpio_chip *chip, unsigned int offset)
@@ -209,7 +211,7 @@ static int gpio_exar_probe(struct platform_device *pdev)
exar_gpio->gpio_chip.direction_input = exar_direction_input;
exar_gpio->gpio_chip.get_direction = exar_get_direction;
exar_gpio->gpio_chip.get = exar_get_value;
- exar_gpio->gpio_chip.set = exar_set_value;
+ exar_gpio->gpio_chip.set_rv = exar_set_value;
exar_gpio->gpio_chip.base = -1;
exar_gpio->gpio_chip.ngpio = ngpios;
exar_gpio->index = index;
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* Re: [PATCH 04/12] gpio: exar: use new line value setter callbacks
2025-04-07 7:13 ` [PATCH 04/12] gpio: exar: " Bartosz Golaszewski
@ 2025-04-07 8:51 ` Andy Shevchenko
0 siblings, 0 replies; 26+ messages in thread
From: Andy Shevchenko @ 2025-04-07 8:51 UTC (permalink / raw)
To: Bartosz Golaszewski
Cc: Linus Walleij, Orson Zhai, Baolin Wang, Chunyan Zhang,
Peter Tyser, linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, Apr 07, 2025 at 09:13:13AM +0200, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> struct gpio_chip now has callbacks for setting line values that return
> an integer, allowing to indicate failures. Convert the driver to using
> them.
...
> -static void exar_set_value(struct gpio_chip *chip, unsigned int offset,
> - int value)
> +static int exar_set_value(struct gpio_chip *chip, unsigned int offset,
> + int value)
It can be located on one line (81 characters).
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 26+ messages in thread
* [PATCH 05/12] gpio: allow building port-mapped GPIO drivers with COMPILE_TEST=y
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
` (3 preceding siblings ...)
2025-04-07 7:13 ` [PATCH 04/12] gpio: exar: " Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-07 9:00 ` Andy Shevchenko
` (2 more replies)
2025-04-07 7:13 ` [PATCH 06/12] gpio: f7188: use new line value setter callbacks Bartosz Golaszewski
` (7 subsequent siblings)
12 siblings, 3 replies; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Extend the build coverage by allowing the port-mapped drivers to be
build with COMPILE_TEST enabled.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/Kconfig | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index f2c39bbff83a..5bbc7f724a09 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -889,7 +889,7 @@ config GPIO_IDT3243X
endmenu
menu "Port-mapped I/O GPIO drivers"
- depends on X86 && HAS_IOPORT # I/O space access
+ depends on (X86 && HAS_IOPORT) || COMPILE_TEST # I/O space access
config GPIO_VX855
tristate "VIA VX855/VX875 GPIO"
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* Re: [PATCH 05/12] gpio: allow building port-mapped GPIO drivers with COMPILE_TEST=y
2025-04-07 7:13 ` [PATCH 05/12] gpio: allow building port-mapped GPIO drivers with COMPILE_TEST=y Bartosz Golaszewski
@ 2025-04-07 9:00 ` Andy Shevchenko
2025-04-15 8:30 ` Linus Walleij
2025-04-17 11:57 ` Bartosz Golaszewski
2 siblings, 0 replies; 26+ messages in thread
From: Andy Shevchenko @ 2025-04-07 9:00 UTC (permalink / raw)
To: Bartosz Golaszewski
Cc: Linus Walleij, Orson Zhai, Baolin Wang, Chunyan Zhang,
Peter Tyser, linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, Apr 07, 2025 at 09:13:14AM +0200, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> Extend the build coverage by allowing the port-mapped drivers to be
> build with COMPILE_TEST enabled.
...
> menu "Port-mapped I/O GPIO drivers"
> - depends on X86 && HAS_IOPORT # I/O space access
> + depends on (X86 && HAS_IOPORT) || COMPILE_TEST # I/O space access
Are you sure about this? Do we have IO accessor stubs? I don't remember that.
What about
depends on HAS_IOPORT # I/O space access
depends on X86 || COMPILE_TEST
instead?
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 05/12] gpio: allow building port-mapped GPIO drivers with COMPILE_TEST=y
2025-04-07 7:13 ` [PATCH 05/12] gpio: allow building port-mapped GPIO drivers with COMPILE_TEST=y Bartosz Golaszewski
2025-04-07 9:00 ` Andy Shevchenko
@ 2025-04-15 8:30 ` Linus Walleij
2025-04-17 11:57 ` Bartosz Golaszewski
2 siblings, 0 replies; 26+ messages in thread
From: Linus Walleij @ 2025-04-15 8:30 UTC (permalink / raw)
To: Bartosz Golaszewski
Cc: Orson Zhai, Baolin Wang, Chunyan Zhang, Andy Shevchenko,
Peter Tyser, linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, Apr 7, 2025 at 9:13 AM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> Extend the build coverage by allowing the port-mapped drivers to be
> build with COMPILE_TEST enabled.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
That's really helpful!
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 05/12] gpio: allow building port-mapped GPIO drivers with COMPILE_TEST=y
2025-04-07 7:13 ` [PATCH 05/12] gpio: allow building port-mapped GPIO drivers with COMPILE_TEST=y Bartosz Golaszewski
2025-04-07 9:00 ` Andy Shevchenko
2025-04-15 8:30 ` Linus Walleij
@ 2025-04-17 11:57 ` Bartosz Golaszewski
2 siblings, 0 replies; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-17 11:57 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, Apr 7, 2025 at 9:13 AM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
>
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> Extend the build coverage by allowing the port-mapped drivers to be
> build with COMPILE_TEST enabled.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> ---
This caused numerous problems in next so I'm dropping it.
Bartosz
^ permalink raw reply [flat|nested] 26+ messages in thread
* [PATCH 06/12] gpio: f7188: use new line value setter callbacks
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
` (4 preceding siblings ...)
2025-04-07 7:13 ` [PATCH 05/12] gpio: allow building port-mapped GPIO drivers with COMPILE_TEST=y Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-07 9:02 ` Andy Shevchenko
2025-04-07 7:13 ` [PATCH 07/12] gpio: graniterapids: " Bartosz Golaszewski
` (6 subsequent siblings)
12 siblings, 1 reply; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
struct gpio_chip now has callbacks for setting line values that return
an integer, allowing to indicate failures. Convert the driver to using
them.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/gpio-f7188x.c | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/drivers/gpio/gpio-f7188x.c b/drivers/gpio/gpio-f7188x.c
index 3875fd940ccb..dfcd3634f279 100644
--- a/drivers/gpio/gpio-f7188x.c
+++ b/drivers/gpio/gpio-f7188x.c
@@ -159,7 +159,8 @@ static int f7188x_gpio_direction_in(struct gpio_chip *chip, unsigned offset);
static int f7188x_gpio_get(struct gpio_chip *chip, unsigned offset);
static int f7188x_gpio_direction_out(struct gpio_chip *chip,
unsigned offset, int value);
-static void f7188x_gpio_set(struct gpio_chip *chip, unsigned offset, int value);
+static int f7188x_gpio_set(struct gpio_chip *chip, unsigned int offset,
+ int value);
static int f7188x_gpio_set_config(struct gpio_chip *chip, unsigned offset,
unsigned long config);
@@ -172,7 +173,7 @@ static int f7188x_gpio_set_config(struct gpio_chip *chip, unsigned offset,
.direction_input = f7188x_gpio_direction_in, \
.get = f7188x_gpio_get, \
.direction_output = f7188x_gpio_direction_out, \
- .set = f7188x_gpio_set, \
+ .set_rv = f7188x_gpio_set, \
.set_config = f7188x_gpio_set_config, \
.base = -1, \
.ngpio = _ngpio, \
@@ -391,7 +392,8 @@ static int f7188x_gpio_direction_out(struct gpio_chip *chip,
return 0;
}
-static void f7188x_gpio_set(struct gpio_chip *chip, unsigned offset, int value)
+static int f7188x_gpio_set(struct gpio_chip *chip, unsigned int offset,
+ int value)
{
int err;
struct f7188x_gpio_bank *bank = gpiochip_get_data(chip);
@@ -400,7 +402,8 @@ static void f7188x_gpio_set(struct gpio_chip *chip, unsigned offset, int value)
err = superio_enter(sio->addr);
if (err)
- return;
+ return err;
+
superio_select(sio->addr, sio->device);
data_out = superio_inb(sio->addr, f7188x_gpio_data_out(bank->regbase));
@@ -411,6 +414,8 @@ static void f7188x_gpio_set(struct gpio_chip *chip, unsigned offset, int value)
superio_outb(sio->addr, f7188x_gpio_data_out(bank->regbase), data_out);
superio_exit(sio->addr);
+
+ return 0;
}
static int f7188x_gpio_set_config(struct gpio_chip *chip, unsigned offset,
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* Re: [PATCH 06/12] gpio: f7188: use new line value setter callbacks
2025-04-07 7:13 ` [PATCH 06/12] gpio: f7188: use new line value setter callbacks Bartosz Golaszewski
@ 2025-04-07 9:02 ` Andy Shevchenko
0 siblings, 0 replies; 26+ messages in thread
From: Andy Shevchenko @ 2025-04-07 9:02 UTC (permalink / raw)
To: Bartosz Golaszewski
Cc: Linus Walleij, Orson Zhai, Baolin Wang, Chunyan Zhang,
Peter Tyser, linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, Apr 07, 2025 at 09:13:15AM +0200, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> struct gpio_chip now has callbacks for setting line values that return
> an integer, allowing to indicate failures. Convert the driver to using
> them.
...
> -static void f7188x_gpio_set(struct gpio_chip *chip, unsigned offset, int value);
> +static int f7188x_gpio_set(struct gpio_chip *chip, unsigned int offset,
> + int value);
Same comment, I suggest you to correct editor configuration to make sure
80 is 80 and not seventy something.
...
> -static void f7188x_gpio_set(struct gpio_chip *chip, unsigned offset, int value)
> +static int f7188x_gpio_set(struct gpio_chip *chip, unsigned int offset,
> + int value)
Ditto.
...
But personally I would leave that archaism in the last decade or even century.
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 26+ messages in thread
* [PATCH 07/12] gpio: graniterapids: use new line value setter callbacks
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
` (5 preceding siblings ...)
2025-04-07 7:13 ` [PATCH 06/12] gpio: f7188: use new line value setter callbacks Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-07 9:02 ` Andy Shevchenko
2025-04-07 7:13 ` [PATCH 08/12] gpio: gw-pld: " Bartosz Golaszewski
` (5 subsequent siblings)
12 siblings, 1 reply; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
struct gpio_chip now has callbacks for setting line values that return
an integer, allowing to indicate failures. Convert the driver to using
them.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/gpio-graniterapids.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/gpio/gpio-graniterapids.c b/drivers/gpio/gpio-graniterapids.c
index ad6a045fd3d2..f25283e5239d 100644
--- a/drivers/gpio/gpio-graniterapids.c
+++ b/drivers/gpio/gpio-graniterapids.c
@@ -116,7 +116,7 @@ static int gnr_gpio_get(struct gpio_chip *gc, unsigned int gpio)
return !!(dw & GNR_CFG_DW_RXSTATE);
}
-static void gnr_gpio_set(struct gpio_chip *gc, unsigned int gpio, int value)
+static int gnr_gpio_set(struct gpio_chip *gc, unsigned int gpio, int value)
{
u32 clear = 0;
u32 set = 0;
@@ -126,7 +126,7 @@ static void gnr_gpio_set(struct gpio_chip *gc, unsigned int gpio, int value)
else
clear = GNR_CFG_DW_TXSTATE;
- gnr_gpio_configure_line(gc, gpio, clear, set);
+ return gnr_gpio_configure_line(gc, gpio, clear, set);
}
static int gnr_gpio_get_direction(struct gpio_chip *gc, unsigned int gpio)
@@ -159,7 +159,7 @@ static const struct gpio_chip gnr_gpio_chip = {
.owner = THIS_MODULE,
.request = gnr_gpio_request,
.get = gnr_gpio_get,
- .set = gnr_gpio_set,
+ .set_rv = gnr_gpio_set,
.get_direction = gnr_gpio_get_direction,
.direction_input = gnr_gpio_direction_input,
.direction_output = gnr_gpio_direction_output,
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* Re: [PATCH 07/12] gpio: graniterapids: use new line value setter callbacks
2025-04-07 7:13 ` [PATCH 07/12] gpio: graniterapids: " Bartosz Golaszewski
@ 2025-04-07 9:02 ` Andy Shevchenko
0 siblings, 0 replies; 26+ messages in thread
From: Andy Shevchenko @ 2025-04-07 9:02 UTC (permalink / raw)
To: Bartosz Golaszewski
Cc: Linus Walleij, Orson Zhai, Baolin Wang, Chunyan Zhang,
Peter Tyser, linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, Apr 07, 2025 at 09:13:16AM +0200, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> struct gpio_chip now has callbacks for setting line values that return
> an integer, allowing to indicate failures. Convert the driver to using
> them.
I'll take this via my tree, thanks!
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 26+ messages in thread
* [PATCH 08/12] gpio: gw-pld: use new line value setter callbacks
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
` (6 preceding siblings ...)
2025-04-07 7:13 ` [PATCH 07/12] gpio: graniterapids: " Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-07 7:13 ` [PATCH 09/12] gpio: htc-egpio: enable building with COMPILE_TEST=y Bartosz Golaszewski
` (4 subsequent siblings)
12 siblings, 0 replies; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
struct gpio_chip now has callbacks for setting line values that return
an integer, allowing to indicate failures. Convert the driver to using
them.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/gpio-gw-pld.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/gpio/gpio-gw-pld.c b/drivers/gpio/gpio-gw-pld.c
index 7e29a2d8de1a..a40ba99a3aea 100644
--- a/drivers/gpio/gpio-gw-pld.c
+++ b/drivers/gpio/gpio-gw-pld.c
@@ -62,9 +62,9 @@ static int gw_pld_output8(struct gpio_chip *gc, unsigned offset, int value)
return i2c_smbus_write_byte(gw->client, gw->out);
}
-static void gw_pld_set8(struct gpio_chip *gc, unsigned offset, int value)
+static int gw_pld_set8(struct gpio_chip *gc, unsigned int offset, int value)
{
- gw_pld_output8(gc, offset, value);
+ return gw_pld_output8(gc, offset, value);
}
static int gw_pld_probe(struct i2c_client *client)
@@ -86,7 +86,7 @@ static int gw_pld_probe(struct i2c_client *client)
gw->chip.direction_input = gw_pld_input8;
gw->chip.get = gw_pld_get8;
gw->chip.direction_output = gw_pld_output8;
- gw->chip.set = gw_pld_set8;
+ gw->chip.set_rv = gw_pld_set8;
gw->client = client;
/*
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* [PATCH 09/12] gpio: htc-egpio: enable building with COMPILE_TEST=y
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
` (7 preceding siblings ...)
2025-04-07 7:13 ` [PATCH 08/12] gpio: gw-pld: " Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-15 8:33 ` Linus Walleij
2025-04-07 7:13 ` [PATCH 10/12] gpio: htc-egpio: use new line value setter callbacks Bartosz Golaszewski
` (3 subsequent siblings)
12 siblings, 1 reply; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Extend the build coverage by allowing to build the module with
COMPILE_TEST enabled.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/Kconfig | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index 5bbc7f724a09..decd150810b7 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -1365,7 +1365,7 @@ config GPIO_DLN2
config HTC_EGPIO
bool "HTC EGPIO support"
- depends on ARM
+ depends on ARM || COMPILE_TEST
help
This driver supports the CPLD egpio chip present on
several HTC phones. It provides basic support for input
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* Re: [PATCH 09/12] gpio: htc-egpio: enable building with COMPILE_TEST=y
2025-04-07 7:13 ` [PATCH 09/12] gpio: htc-egpio: enable building with COMPILE_TEST=y Bartosz Golaszewski
@ 2025-04-15 8:33 ` Linus Walleij
0 siblings, 0 replies; 26+ messages in thread
From: Linus Walleij @ 2025-04-15 8:33 UTC (permalink / raw)
To: Bartosz Golaszewski
Cc: Orson Zhai, Baolin Wang, Chunyan Zhang, Andy Shevchenko,
Peter Tyser, linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, Apr 7, 2025 at 9:25 AM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> Extend the build coverage by allowing to build the module with
> COMPILE_TEST enabled.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 26+ messages in thread
* [PATCH 10/12] gpio: htc-egpio: use new line value setter callbacks
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
` (8 preceding siblings ...)
2025-04-07 7:13 ` [PATCH 09/12] gpio: htc-egpio: enable building with COMPILE_TEST=y Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-07 7:13 ` [PATCH 11/12] gpio: ich: enable building with COMPILE_TEST=y Bartosz Golaszewski
` (2 subsequent siblings)
12 siblings, 0 replies; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
struct gpio_chip now has callbacks for setting line values that return
an integer, allowing to indicate failures. Convert the driver to using
them.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/gpio-htc-egpio.c | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/drivers/gpio/gpio-htc-egpio.c b/drivers/gpio/gpio-htc-egpio.c
index a40bd56673fe..b1844a676c7c 100644
--- a/drivers/gpio/gpio-htc-egpio.c
+++ b/drivers/gpio/gpio-htc-egpio.c
@@ -170,7 +170,7 @@ static int egpio_direction_input(struct gpio_chip *chip, unsigned offset)
* Output pins
*/
-static void egpio_set(struct gpio_chip *chip, unsigned offset, int value)
+static int egpio_set(struct gpio_chip *chip, unsigned int offset, int value)
{
unsigned long flag;
struct egpio_chip *egpio;
@@ -198,6 +198,8 @@ static void egpio_set(struct gpio_chip *chip, unsigned offset, int value)
egpio->cached_values &= ~(1 << offset);
egpio_writew((egpio->cached_values >> shift) & ei->reg_mask, ei, reg);
spin_unlock_irqrestore(&ei->lock, flag);
+
+ return 0;
}
static int egpio_direction_output(struct gpio_chip *chip,
@@ -206,12 +208,10 @@ static int egpio_direction_output(struct gpio_chip *chip,
struct egpio_chip *egpio;
egpio = gpiochip_get_data(chip);
- if (test_bit(offset, &egpio->is_out)) {
- egpio_set(chip, offset, value);
- return 0;
- } else {
- return -EINVAL;
- }
+ if (test_bit(offset, &egpio->is_out))
+ return egpio_set(chip, offset, value);
+
+ return -EINVAL;
}
static int egpio_get_direction(struct gpio_chip *chip, unsigned offset)
@@ -324,7 +324,7 @@ static int __init egpio_probe(struct platform_device *pdev)
chip->parent = &pdev->dev;
chip->owner = THIS_MODULE;
chip->get = egpio_get;
- chip->set = egpio_set;
+ chip->set_rv = egpio_set;
chip->direction_input = egpio_direction_input;
chip->direction_output = egpio_direction_output;
chip->get_direction = egpio_get_direction;
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* [PATCH 11/12] gpio: ich: enable building with COMPILE_TEST=y
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
` (9 preceding siblings ...)
2025-04-07 7:13 ` [PATCH 10/12] gpio: htc-egpio: use new line value setter callbacks Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-07 8:54 ` Andy Shevchenko
2025-04-15 8:30 ` Linus Walleij
2025-04-07 7:13 ` [PATCH 12/12] gpio: ich: use new line value setter callbacks Bartosz Golaszewski
2025-04-16 15:56 ` [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
12 siblings, 2 replies; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Extend the build coverage by allowing to build the module with
COMPILE_TEST enabled.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/Kconfig | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index decd150810b7..c13b95813c6c 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -368,8 +368,7 @@ config GPIO_HLWD
config GPIO_ICH
tristate "Intel ICH GPIO"
- depends on X86
- depends on LPC_ICH
+ depends on (X86 && LPC_ICH) || COMPILE_TEST
help
Say yes here to support the GPIO functionality of a number of Intel
ICH-based chipsets. Currently supported devices: ICH6, ICH7, ICH8
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* Re: [PATCH 11/12] gpio: ich: enable building with COMPILE_TEST=y
2025-04-07 7:13 ` [PATCH 11/12] gpio: ich: enable building with COMPILE_TEST=y Bartosz Golaszewski
@ 2025-04-07 8:54 ` Andy Shevchenko
2025-04-15 8:30 ` Linus Walleij
1 sibling, 0 replies; 26+ messages in thread
From: Andy Shevchenko @ 2025-04-07 8:54 UTC (permalink / raw)
To: Bartosz Golaszewski
Cc: Linus Walleij, Orson Zhai, Baolin Wang, Chunyan Zhang,
Peter Tyser, linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, Apr 07, 2025 at 09:13:20AM +0200, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> Extend the build coverage by allowing to build the module with
> COMPILE_TEST enabled.
...
> config GPIO_ICH
> tristate "Intel ICH GPIO"
> - depends on X86
> - depends on LPC_ICH
> + depends on (X86 && LPC_ICH) || COMPILE_TEST
I don't see why LPC_ICH should be here.
We do all-or-none approach for compile test for (x86) MFD drivers,
no need to test it separately (it makes a little sense).
depends on X86 || COMPILE_TEST
depends on LPC_ICH
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 11/12] gpio: ich: enable building with COMPILE_TEST=y
2025-04-07 7:13 ` [PATCH 11/12] gpio: ich: enable building with COMPILE_TEST=y Bartosz Golaszewski
2025-04-07 8:54 ` Andy Shevchenko
@ 2025-04-15 8:30 ` Linus Walleij
1 sibling, 0 replies; 26+ messages in thread
From: Linus Walleij @ 2025-04-15 8:30 UTC (permalink / raw)
To: Bartosz Golaszewski
Cc: Orson Zhai, Baolin Wang, Chunyan Zhang, Andy Shevchenko,
Peter Tyser, linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, Apr 7, 2025 at 9:13 AM Bartosz Golaszewski <brgl@bgdev.pl> wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> Extend the build coverage by allowing to build the module with
> COMPILE_TEST enabled.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 26+ messages in thread
* [PATCH 12/12] gpio: ich: use new line value setter callbacks
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
` (10 preceding siblings ...)
2025-04-07 7:13 ` [PATCH 11/12] gpio: ich: enable building with COMPILE_TEST=y Bartosz Golaszewski
@ 2025-04-07 7:13 ` Bartosz Golaszewski
2025-04-07 8:54 ` Andy Shevchenko
2025-04-16 15:56 ` [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
12 siblings, 1 reply; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-07 7:13 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Orson Zhai, Baolin Wang,
Chunyan Zhang, Andy Shevchenko, Peter Tyser
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
struct gpio_chip now has callbacks for setting line values that return
an integer, allowing to indicate failures. Convert the driver to using
them.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
drivers/gpio/gpio-ich.c | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/drivers/gpio/gpio-ich.c b/drivers/gpio/gpio-ich.c
index 0be9285efebc..67089b2423d8 100644
--- a/drivers/gpio/gpio-ich.c
+++ b/drivers/gpio/gpio-ich.c
@@ -175,12 +175,16 @@ static int ichx_gpio_direction_input(struct gpio_chip *gpio, unsigned int nr)
static int ichx_gpio_direction_output(struct gpio_chip *gpio, unsigned int nr,
int val)
{
+ int ret;
+
/* Disable blink hardware which is available for GPIOs from 0 to 31. */
if (nr < 32 && ichx_priv.desc->have_blink)
ichx_write_bit(GPO_BLINK, nr, 0, 0);
/* Set GPIO output value. */
- ichx_write_bit(GPIO_LVL, nr, val, 0);
+ ret = ichx_write_bit(GPIO_LVL, nr, val, 0);
+ if (ret)
+ return ret;
/*
* Try setting pin as an output and verify it worked since many pins
@@ -252,9 +256,9 @@ static int ich6_gpio_request(struct gpio_chip *chip, unsigned int nr)
return ichx_gpio_request(chip, nr);
}
-static void ichx_gpio_set(struct gpio_chip *chip, unsigned int nr, int val)
+static int ichx_gpio_set(struct gpio_chip *chip, unsigned int nr, int val)
{
- ichx_write_bit(GPIO_LVL, nr, val, 0);
+ return ichx_write_bit(GPIO_LVL, nr, val, 0);
}
static void ichx_gpiolib_setup(struct gpio_chip *chip)
@@ -269,7 +273,7 @@ static void ichx_gpiolib_setup(struct gpio_chip *chip)
chip->get = ichx_priv.desc->get ?
ichx_priv.desc->get : ichx_gpio_get;
- chip->set = ichx_gpio_set;
+ chip->set_rv = ichx_gpio_set;
chip->get_direction = ichx_gpio_get_direction;
chip->direction_input = ichx_gpio_direction_input;
chip->direction_output = ichx_gpio_direction_output;
--
2.45.2
^ permalink raw reply related [flat|nested] 26+ messages in thread
* Re: [PATCH 12/12] gpio: ich: use new line value setter callbacks
2025-04-07 7:13 ` [PATCH 12/12] gpio: ich: use new line value setter callbacks Bartosz Golaszewski
@ 2025-04-07 8:54 ` Andy Shevchenko
0 siblings, 0 replies; 26+ messages in thread
From: Andy Shevchenko @ 2025-04-07 8:54 UTC (permalink / raw)
To: Bartosz Golaszewski
Cc: Linus Walleij, Orson Zhai, Baolin Wang, Chunyan Zhang,
Peter Tyser, linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, Apr 07, 2025 at 09:13:21AM +0200, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> struct gpio_chip now has callbacks for setting line values that return
> an integer, allowing to indicate failures. Convert the driver to using
> them.
I'll take it via my tree. Thanks!
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 00/12] gpio: convert more GPIO chips to using new value setters
2025-04-07 7:13 [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
` (11 preceding siblings ...)
2025-04-07 7:13 ` [PATCH 12/12] gpio: ich: use new line value setter callbacks Bartosz Golaszewski
@ 2025-04-16 15:56 ` Bartosz Golaszewski
2025-04-16 18:05 ` Andy Shevchenko
12 siblings, 1 reply; 26+ messages in thread
From: Bartosz Golaszewski @ 2025-04-16 15:56 UTC (permalink / raw)
To: Linus Walleij, Orson Zhai, Baolin Wang, Chunyan Zhang,
Andy Shevchenko, Peter Tyser, Bartosz Golaszewski
Cc: linux-gpio, linux-kernel, Bartosz Golaszewski
On Mon, 07 Apr 2025 09:13:09 +0200, Bartosz Golaszewski wrote:
> struct gpio_chip now has callbacks for setting line values that return
> an integer, allowing to indicate failures. We're in the process of
> converting all GPIO drivers to using the new API. This series converts
> another round of GPIO controllers.
>
>
Applied, thanks!
[01/12] gpio: dln2: use new line value setter callbacks
https://git.kernel.org/brgl/linux/c/afb4aed832f9000a5d15ecd28a7b2faa5789d28d
[02/12] gpio: eic-sprd: use new line value setter callbacks
https://git.kernel.org/brgl/linux/c/21d3c6531b113b1aaecd99ae90dddd55c20f372b
[03/12] gpio: em: use new line value setter callbacks
https://git.kernel.org/brgl/linux/c/097cf61ba5bd69328a69c4920f3454089fae0a43
[04/12] gpio: exar: use new line value setter callbacks
https://git.kernel.org/brgl/linux/c/bcdd5b37640cc577cd93d20f00519e70d7add8a6
[05/12] gpio: allow building port-mapped GPIO drivers with COMPILE_TEST=y
https://git.kernel.org/brgl/linux/c/f031312c8e1903859a3a2a58ab5a3f97ba8b0ae9
[06/12] gpio: f7188: use new line value setter callbacks
https://git.kernel.org/brgl/linux/c/56193775d1ec9ab5ac23b05c821c26704debe040
[07/12] gpio: graniterapids: use new line value setter callbacks
https://git.kernel.org/brgl/linux/c/04eaa41eb8ebb7be4c78d1e57442a581d0bfdc22
[08/12] gpio: gw-pld: use new line value setter callbacks
https://git.kernel.org/brgl/linux/c/674817f336bdde5887191c61eaecf3f0a70cd405
[09/12] gpio: htc-egpio: enable building with COMPILE_TEST=y
https://git.kernel.org/brgl/linux/c/6be51668eda37089d9a484bc8a41c1e9ecd6f577
[10/12] gpio: htc-egpio: use new line value setter callbacks
https://git.kernel.org/brgl/linux/c/4c71b46278c2b0cfc8e019e4fe3ec31ce258741e
[11/12] gpio: ich: enable building with COMPILE_TEST=y
https://git.kernel.org/brgl/linux/c/10b16abc29e17c6ca86bcb8ceebf840e509b0ce5
[12/12] gpio: ich: use new line value setter callbacks
https://git.kernel.org/brgl/linux/c/69e230a0a288a73ce2a8e9373bcb7b37239cafaa
Best regards,
--
Bartosz Golaszewski <brgl@bgdev.pl>
^ permalink raw reply [flat|nested] 26+ messages in thread
* Re: [PATCH 00/12] gpio: convert more GPIO chips to using new value setters
2025-04-16 15:56 ` [PATCH 00/12] gpio: convert more GPIO chips to using new value setters Bartosz Golaszewski
@ 2025-04-16 18:05 ` Andy Shevchenko
0 siblings, 0 replies; 26+ messages in thread
From: Andy Shevchenko @ 2025-04-16 18:05 UTC (permalink / raw)
To: Bartosz Golaszewski
Cc: Linus Walleij, Orson Zhai, Baolin Wang, Chunyan Zhang,
Peter Tyser, linux-gpio, linux-kernel, Bartosz Golaszewski
On Wed, Apr 16, 2025 at 05:56:24PM +0200, Bartosz Golaszewski wrote:
>
> On Mon, 07 Apr 2025 09:13:09 +0200, Bartosz Golaszewski wrote:
> > struct gpio_chip now has callbacks for setting line values that return
> > an integer, allowing to indicate failures. We're in the process of
> > converting all GPIO drivers to using the new API. This series converts
> > another round of GPIO controllers.
> [07/12] gpio: graniterapids: use new line value setter callbacks
> [12/12] gpio: ich: use new line value setter callbacks
I believe I have taken these two via my tree. Can it be like this?
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 26+ messages in thread