From: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
To: Linus Walleij <linus.walleij@linaro.org>,
Kent Gibson <warthog618@gmail.com>,
Vincent Fazio <vfazio@xes-inc.com>,
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: linux-gpio@vger.kernel.org, brgl@kernel.org,
Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
Subject: [PATCH RFC libgpiod 0/3] tools: new tool - gpioctl
Date: Fri, 16 Oct 2026 16:18:07 +0200 [thread overview]
Message-ID: <20261016-gpioctl-v1-0-8770622679b8@oss.qualcomm.com> (raw)
Here's is something I've had in the works for about a year now. It's
supposed to address the biggest issue with gpioset, namely the lack of
persistence beyond the process' lifetime by working somewhat similarly
to tmux: spawning a daemon on first invocation that retains the state
for a particular user. This daemon listens on a unix socket and can
handle clients that are different processes executed over time.
It's finally in a state where I'm happy showing it to others, so please
take a look.
--
Provide gpioctl, a new command-line tool for persistent GPIO line control.
Unlike gpioget and gpioset which release lines on exit, gpioctl holds
requested lines in a background daemon so their state survives across
multiple client invocations.
Before adding the new program: move some code we'll reuse out of gpioset
and gpiomon and into tools-common.
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
---
Bartosz Golaszewski (3):
tools: factor out line value parsing into tools-common
tools: factor out line event formatting into tools-common
tools: implement gpioctl
TODO | 14 -
docs/.gitignore | 2 +
docs/conf.py | 8 +
docs/gpio_tools.rst | 10 +-
docs/gpioctl_top.rst | 156 +++
man/meson.build | 39 +
tools/gpio-tools-test.bash | 1756 ++++++++++++++++++++++++++
tools/gpioctl-test-helper.c | 58 +
tools/gpioctl.c | 2838 +++++++++++++++++++++++++++++++++++++++++++
tools/gpiomon.c | 128 +-
tools/gpioset.c | 91 +-
tools/meson.build | 21 +-
tools/tools-common.c | 180 ++-
tools/tools-common.h | 9 +
14 files changed, 5091 insertions(+), 219 deletions(-)
---
base-commit: 25c56387337390bbbe42d145faa829c35f9c0611
change-id: 20251001-gpioctl-336556e702fd
Best regards,
--
Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
next reply other threads:[~2026-10-16 14:18 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-16 14:18 Bartosz Golaszewski [this message]
2026-10-16 14:18 ` [PATCH RFC libgpiod 1/3] tools: factor out line value parsing into tools-common Bartosz Golaszewski
2026-10-16 14:18 ` [PATCH RFC libgpiod 2/3] tools: factor out line event formatting " Bartosz Golaszewski
2026-10-16 14:18 ` [PATCH RFC libgpiod 3/3] tools: implement gpioctl Bartosz Golaszewski
2026-10-16 18:00 ` Linus Walleij
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261016-gpioctl-v1-0-8770622679b8@oss.qualcomm.com \
--to=bartosz.golaszewski@oss.qualcomm.com \
--cc=andriy.shevchenko@linux.intel.com \
--cc=brgl@kernel.org \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=vfazio@xes-inc.com \
--cc=warthog618@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox