From: Kent Gibson <warthog618@gmail.com>
To: David Jander <david@protonic.nl>
Cc: Bartosz Golaszewski <brgl@bgdev.pl>,
Bartosz Golaszewski <bartosz.golaszewski@linaro.org>,
Linus Walleij <linus.walleij@linaro.org>,
linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: regression: gpiolib: switch the line state notifier to atomic unexpected impact on performance
Date: Wed, 12 Mar 2025 09:32:56 +0800 [thread overview]
Message-ID: <20250312013256.GB27058@rigel> (raw)
In-Reply-To: <20250311120346.21ba086d@erd003.prtnl>
On Tue, Mar 11, 2025 at 12:03:46PM +0100, David Jander wrote:
>
>
> Indeed, it does. My application is written in python and uses the python gpiod
> module. Even in such an environment the impact is killing.
>
Interesting - the only reason I could think of for an application
requesting/releasing GPIOs at a high rate was it if was built on top of
the libgpiod tools and so was unable to hold the request fd.
Generally an application should request the lines it requires once and hold
them for the duration. Similarly functions such as find_line() should be
performed once per line.
From a performance perspective, NOT having to re-request a line is
considerably faster than requesting it - even with Bart's fix.
Is there something unusual about your app that requires the lines be
released?
Cheers,
Kent.
next prev parent reply other threads:[~2025-03-12 1:33 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-11 10:00 regression: gpiolib: switch the line state notifier to atomic unexpected impact on performance David Jander
2025-03-11 10:21 ` Bartosz Golaszewski
2025-03-11 11:03 ` David Jander
2025-03-12 1:32 ` Kent Gibson [this message]
2025-03-12 8:08 ` David Jander
2025-03-12 9:10 ` Kent Gibson
2025-03-12 10:24 ` David Jander
2025-03-12 12:10 ` Kent Gibson
2025-03-11 11:45 ` Bartosz Golaszewski
2025-03-11 12:30 ` David Jander
2025-03-11 13:21 ` Bartosz Golaszewski
2025-03-11 14:09 ` David Jander
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=20250312013256.GB27058@rigel \
--to=warthog618@gmail.com \
--cc=bartosz.golaszewski@linaro.org \
--cc=brgl@bgdev.pl \
--cc=david@protonic.nl \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/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