projects
/
platform
/
kernel
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d7124f0
)
gpio: Fix pin's status display for pin with GPIOF_UNUSED function
author
Patrice Chotard
<patrice.chotard@foss.st.com>
Tue, 30 Aug 2022 12:09:12 +0000
(14:09 +0200)
committer
Tom Rini
<trini@konsulko.com>
Thu, 15 Sep 2022 13:55:30 +0000
(09:55 -0400)
Even pin with GPIOF_UNUSED function can have a label.
The criteria to add or not a space character is linked to label not to
the used/unused status.
Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
drivers/gpio/gpio-uclass.c
patch
|
blob
|
history
diff --git
a/drivers/gpio/gpio-uclass.c
b/drivers/gpio/gpio-uclass.c
index
d60e461
..
a00880e
100644
(file)
--- a/
drivers/gpio/gpio-uclass.c
+++ b/
drivers/gpio/gpio-uclass.c
@@
-916,7
+916,7
@@
int gpio_get_status(struct udevice *dev, int offset, char *buf, int buffsize)
snprintf(str + len, buffsize - len, ": %d [%c]%s%s",
ret,
used ? 'x' : ' ',
-
used
? " " : "",
+
label
? " " : "",
label ? label : "");
break;
}