All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] leds: lp55xx: Initialize enable GPIO direction to output
@ 2021-05-10 20:40 Doug Zobel
  2021-06-23 20:10 ` Pavel Machek
  0 siblings, 1 reply; 2+ messages in thread
From: Doug Zobel @ 2021-05-10 20:40 UTC (permalink / raw)
  To: linux-leds; +Cc: Pavel Machek

The "Convert to use GPIO descriptors" commit changed the
initialization of the enable GPIO from GPIOF_DIR_OUT to
GPIOD_ASIS.  This breaks systems where the GPIO does not
default to output.  Changing the enable initialization
to GPIOD_OUT_LOW.

Signed-off-by: Doug Zobel <dougdev334@gmail.com>
---
 drivers/leds/leds-lp55xx-common.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/leds/leds-lp55xx-common.c b/drivers/leds/leds-lp55xx-common.c
index 81de1346bf5d..d1657c46ee2f 100644
--- a/drivers/leds/leds-lp55xx-common.c
+++ b/drivers/leds/leds-lp55xx-common.c
@@ -694,7 +694,7 @@ struct lp55xx_platform_data *lp55xx_of_populate_pdata(struct device *dev,
 	of_property_read_u8(np, "clock-mode", &pdata->clock_mode);
 
 	pdata->enable_gpiod = devm_gpiod_get_optional(dev, "enable",
-						      GPIOD_ASIS);
+						      GPIOD_OUT_LOW);
 	if (IS_ERR(pdata->enable_gpiod))
 		return ERR_CAST(pdata->enable_gpiod);
 
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] leds: lp55xx: Initialize enable GPIO direction to output
  2021-05-10 20:40 [PATCH] leds: lp55xx: Initialize enable GPIO direction to output Doug Zobel
@ 2021-06-23 20:10 ` Pavel Machek
  0 siblings, 0 replies; 2+ messages in thread
From: Pavel Machek @ 2021-06-23 20:10 UTC (permalink / raw)
  To: Doug Zobel; +Cc: linux-leds

[-- Attachment #1: Type: text/plain, Size: 387 bytes --]

On Mon 2021-05-10 15:40:00, Doug Zobel wrote:
> The "Convert to use GPIO descriptors" commit changed the
> initialization of the enable GPIO from GPIOF_DIR_OUT to
> GPIOD_ASIS.  This breaks systems where the GPIO does not
> default to output.  Changing the enable initialization
> to GPIOD_OUT_LOW.

Thanks, applied.
							Pavel

-- 
http://www.livejournal.com/~pavelmachek

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-06-23 20:11 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-10 20:40 [PATCH] leds: lp55xx: Initialize enable GPIO direction to output Doug Zobel
2021-06-23 20:10 ` Pavel Machek

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.