* [PATCH 1/2] gpio: correct docs about return value of gpiod_get_direction
@ 2018-01-09 11:35 Wolfram Sang
2018-01-09 11:35 ` [PATCH 2/2] Documentation: gpio: correct " Wolfram Sang
2018-01-09 14:35 ` [PATCH 1/2] gpio: correct docs about " Linus Walleij
0 siblings, 2 replies; 4+ messages in thread
From: Wolfram Sang @ 2018-01-09 11:35 UTC (permalink / raw)
To: linux-gpio; +Cc: linux-renesas-soc, Linus Walleij, Wolfram Sang
From: Wolfram Sang <wsa+renesas@sang-engineering.com>
The use of the GPIOF_* flags is deprecated, so don't advertise them
here. Document the plain numbers for now until we have a better
solution.
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
drivers/gpio/gpiolib.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c
index aad84a6306c4e5..d3a91cf8fc73d4 100644
--- a/drivers/gpio/gpiolib.c
+++ b/drivers/gpio/gpiolib.c
@@ -195,7 +195,7 @@ static int gpiochip_find_base(int ngpio)
* gpiod_get_direction - return the current direction of a GPIO
* @desc: GPIO to get the direction of
*
- * Return GPIOF_DIR_IN or GPIOF_DIR_OUT, or an error code in case of error.
+ * Returns 0 for output, 1 for input, or an error code in case of error.
*
* This function may sleep if gpiod_cansleep() is true.
*/
--
2.11.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/2] Documentation: gpio: correct return value of gpiod_get_direction
2018-01-09 11:35 [PATCH 1/2] gpio: correct docs about return value of gpiod_get_direction Wolfram Sang
@ 2018-01-09 11:35 ` Wolfram Sang
2018-01-09 14:36 ` Linus Walleij
2018-01-09 14:35 ` [PATCH 1/2] gpio: correct docs about " Linus Walleij
1 sibling, 1 reply; 4+ messages in thread
From: Wolfram Sang @ 2018-01-09 11:35 UTC (permalink / raw)
To: linux-gpio; +Cc: linux-renesas-soc, Linus Walleij, Wolfram Sang
From: Wolfram Sang <wsa+renesas@sang-engineering.com>
The use of the GPIOF_* flags is deprecated, so don't advertise them
here. Document the plain numbers for now until we have a better
solution.
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
Documentation/gpio/consumer.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Documentation/gpio/consumer.txt b/Documentation/gpio/consumer.txt
index 63e1bd1d88e324..7aac3308151016 100644
--- a/Documentation/gpio/consumer.txt
+++ b/Documentation/gpio/consumer.txt
@@ -184,7 +184,7 @@ A driver can also query the current direction of a GPIO:
int gpiod_get_direction(const struct gpio_desc *desc)
-This function will return either GPIOF_DIR_IN or GPIOF_DIR_OUT.
+This function returns 0 for output, 1 for input, or an error code in case of error.
Be aware that there is no default direction for GPIOs. Therefore, **using a GPIO
without setting its direction first is illegal and will result in undefined
--
2.11.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/2] gpio: correct docs about return value of gpiod_get_direction
2018-01-09 11:35 [PATCH 1/2] gpio: correct docs about return value of gpiod_get_direction Wolfram Sang
2018-01-09 11:35 ` [PATCH 2/2] Documentation: gpio: correct " Wolfram Sang
@ 2018-01-09 14:35 ` Linus Walleij
1 sibling, 0 replies; 4+ messages in thread
From: Linus Walleij @ 2018-01-09 14:35 UTC (permalink / raw)
To: Wolfram Sang; +Cc: linux-gpio, Linux-Renesas, Wolfram Sang
On Tue, Jan 9, 2018 at 12:35 PM, Wolfram Sang <wsa@the-dreams.de> wrote:
> From: Wolfram Sang <wsa+renesas@sang-engineering.com>
>
> The use of the GPIOF_* flags is deprecated, so don't advertise them
> here. Document the plain numbers for now until we have a better
> solution.
>
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Patch applied.
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 2/2] Documentation: gpio: correct return value of gpiod_get_direction
2018-01-09 11:35 ` [PATCH 2/2] Documentation: gpio: correct " Wolfram Sang
@ 2018-01-09 14:36 ` Linus Walleij
0 siblings, 0 replies; 4+ messages in thread
From: Linus Walleij @ 2018-01-09 14:36 UTC (permalink / raw)
To: Wolfram Sang; +Cc: linux-gpio, Linux-Renesas, Wolfram Sang
On Tue, Jan 9, 2018 at 12:35 PM, Wolfram Sang <wsa@the-dreams.de> wrote:
> From: Wolfram Sang <wsa+renesas@sang-engineering.com>
>
> The use of the GPIOF_* flags is deprecated, so don't advertise them
> here. Document the plain numbers for now until we have a better
> solution.
>
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Patch applied.
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-01-09 14:36 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-09 11:35 [PATCH 1/2] gpio: correct docs about return value of gpiod_get_direction Wolfram Sang
2018-01-09 11:35 ` [PATCH 2/2] Documentation: gpio: correct " Wolfram Sang
2018-01-09 14:36 ` Linus Walleij
2018-01-09 14:35 ` [PATCH 1/2] gpio: correct docs about " Linus Walleij
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.