linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/6] gpio: notify user-space about config changes in the kernel
@ 2024-10-10  9:10 Bartosz Golaszewski
  2024-10-10  9:10 ` [PATCH v2 1/6] gpiolib: notify user-space when a driver requests its own desc Bartosz Golaszewski
                   ` (5 more replies)
  0 siblings, 6 replies; 24+ messages in thread
From: Bartosz Golaszewski @ 2024-10-10  9:10 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Kent Gibson
  Cc: linux-gpio, linux-kernel, Bartosz Golaszewski

We currently only emit events on changed line config to user-space on
changes made from user-space. Users have no way of getting notified
about in-kernel changes. This series improves the situation and also
contains a couple other related improvements.

This is a reworked approach which gets and stores as much info (all of
it actually, except for the pinctrl state) the moment the event occurrs
but moves the actual queueing of the event on the kfifo to a dedicated
high-priority, ordered workqueue.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
---
Changes in v2:
- put all line-info events emitting on a workqueue to allow queueing
  them from atomic context
- switch the notifier type used for emitting info events to atomic
- add a patch notifying user-space about drivers requesting their own
  descs
- drop patches that were picked up
- Link to v1: https://lore.kernel.org/r/20241004-gpio-notify-in-kernel-events-v1-0-8ac29e1df4fe@linaro.org

---
Bartosz Golaszewski (6):
      gpiolib: notify user-space when a driver requests its own desc
      gpio: cdev: prepare gpio_desc_to_lineinfo() for being called from atomic
      gpiolib: add a per-gpio_device line state notification workqueue
      gpio: cdev: put emitting the line state events on a workqueue
      gpiolib: switch the line state notifier to atomic
      gpiolib: notify user-space about in-kernel line state changes

 drivers/gpio/gpiolib-cdev.c | 126 +++++++++++++++++++++++++++++++++-----------
 drivers/gpio/gpiolib.c      |  79 +++++++++++++++++++++++----
 drivers/gpio/gpiolib.h      |   8 ++-
 3 files changed, 171 insertions(+), 42 deletions(-)
---
base-commit: b7adfb6076ff0c1ebbde56d1903daa3d07db92c5
change-id: 20240924-gpio-notify-in-kernel-events-07cd912153e8

Best regards,
-- 
Bartosz Golaszewski <bartosz.golaszewski@linaro.org>


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

end of thread, other threads:[~2024-10-14  9:58 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-10  9:10 [PATCH v2 0/6] gpio: notify user-space about config changes in the kernel Bartosz Golaszewski
2024-10-10  9:10 ` [PATCH v2 1/6] gpiolib: notify user-space when a driver requests its own desc Bartosz Golaszewski
2024-10-10  9:10 ` [PATCH v2 2/6] gpio: cdev: prepare gpio_desc_to_lineinfo() for being called from atomic Bartosz Golaszewski
2024-10-14  1:58   ` Kent Gibson
2024-10-14  7:45     ` Bartosz Golaszewski
2024-10-14  8:32       ` Kent Gibson
2024-10-14  8:41         ` Bartosz Golaszewski
2024-10-10  9:10 ` [PATCH v2 3/6] gpiolib: add a per-gpio_device line state notification workqueue Bartosz Golaszewski
2024-10-10  9:10 ` [PATCH v2 4/6] gpio: cdev: put emitting the line state events on a workqueue Bartosz Golaszewski
2024-10-14  2:09   ` Kent Gibson
2024-10-14  7:47     ` Bartosz Golaszewski
2024-10-10  9:10 ` [PATCH v2 5/6] gpiolib: switch the line state notifier to atomic Bartosz Golaszewski
2024-10-14  2:11   ` Kent Gibson
2024-10-14  7:48     ` Bartosz Golaszewski
2024-10-14  9:24       ` Kent Gibson
2024-10-14  9:27         ` Bartosz Golaszewski
2024-10-14  9:29           ` Kent Gibson
2024-10-14  9:32             ` Bartosz Golaszewski
2024-10-14  9:55               ` Kent Gibson
2024-10-14  9:57                 ` Bartosz Golaszewski
2024-10-10  9:10 ` [PATCH v2 6/6] gpiolib: notify user-space about in-kernel line state changes Bartosz Golaszewski
2024-10-14  2:24   ` Kent Gibson
2024-10-14  8:13     ` Bartosz Golaszewski
2024-10-14  8:42       ` Kent Gibson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).