summaryrefslogtreecommitdiffstats
path: root/tools/gpio
diff options
context:
space:
mode:
authorLinus Walleij <linus.walleij@linaro.org>2016-02-25 21:01:48 +0100
committerLinus Walleij <linus.walleij@linaro.org>2016-02-25 21:07:23 +0100
commit214338e372af2b856af07978daa771dbe087f990 (patch)
tree07ad030d3338a037874c3b1e80e5ad9e976f5fdc /tools/gpio
parentd27c17285eb7ebb6aa513da7a3338e2a507b1216 (diff)
downloadlinux-214338e372af2b856af07978daa771dbe087f990.tar.gz
linux-214338e372af2b856af07978daa771dbe087f990.tar.bz2
linux-214338e372af2b856af07978daa771dbe087f990.zip
gpio: present the consumer of a line to userspace
I named the field representing the current user of GPIO line as "label" but this is too vague and ambiguous. Before anyone gets confused, rename it to "consumer" and indicate clearly in the documentation that this is a string set by the user of the line. Also clean up leftovers in the documentation. Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'tools/gpio')
-rw-r--r--tools/gpio/lsgpio.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/gpio/lsgpio.c b/tools/gpio/lsgpio.c
index 6af118cc7efb..1124da375942 100644
--- a/tools/gpio/lsgpio.c
+++ b/tools/gpio/lsgpio.c
@@ -116,10 +116,10 @@ int list_device(const char *device_name)
fprintf(stdout, " \"%s\"", linfo.name);
else
fprintf(stdout, " unnamed");
- if (linfo.label[0])
- fprintf(stdout, " \"%s\"", linfo.label);
+ if (linfo.consumer[0])
+ fprintf(stdout, " \"%s\"", linfo.consumer);
else
- fprintf(stdout, " unlabeled");
+ fprintf(stdout, " unused");
if (linfo.flags) {
fprintf(stdout, " [");
print_flags(linfo.flags);