From: Kent Gibson <warthog618@gmail.com>
To: Bartosz Golaszewski <brgl@bgdev.pl>
Cc: Linus Walleij <linus.walleij@linaro.org>,
linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org,
Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Subject: Re: [PATCH] gpio: cdev: don't report GPIOs requested as interrupts as used
Date: Fri, 1 Nov 2024 08:48:09 +0800 [thread overview]
Message-ID: <20241101004809.GA10513@rigel> (raw)
In-Reply-To: <20241031200842.22712-1-brgl@bgdev.pl>
On Thu, Oct 31, 2024 at 09:08:41PM +0100, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> GPIOs used as shared irqs can still be requested by user-space (or
> kernel drivers for that matter) yet we report them as used over the
> chardev ABI. Drop the test for FLAG_USED_AS_IRQ from
> gpio_desc_to_lineinfo().
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Reviewed-by: Kent Gibson <warthog618@gmail.com>
> ---
> drivers/gpio/gpiolib-cdev.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/drivers/gpio/gpiolib-cdev.c b/drivers/gpio/gpiolib-cdev.c
> index 0ec162b0ea04..629e9372fd57 100644
> --- a/drivers/gpio/gpiolib-cdev.c
> +++ b/drivers/gpio/gpiolib-cdev.c
> @@ -2275,7 +2275,6 @@ static void gpio_desc_to_lineinfo(struct gpio_desc *desc,
> */
> if (test_bit(FLAG_REQUESTED, &dflags) ||
> test_bit(FLAG_IS_HOGGED, &dflags) ||
> - test_bit(FLAG_USED_AS_IRQ, &dflags) ||
> test_bit(FLAG_EXPORT, &dflags) ||
> test_bit(FLAG_SYSFS, &dflags) ||
> !gpiochip_line_is_valid(guard.gc, info->offset)) {
> --
> 2.45.2
>
next prev parent reply other threads:[~2024-11-01 0:48 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-31 20:08 [PATCH] gpio: cdev: don't report GPIOs requested as interrupts as used Bartosz Golaszewski
2024-11-01 0:48 ` Kent Gibson [this message]
2024-11-01 10:34 ` Linus Walleij
2024-11-01 12:49 ` Bartosz Golaszewski
2024-11-04 8:08 ` Bartosz Golaszewski
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=20241101004809.GA10513@rigel \
--to=warthog618@gmail.com \
--cc=bartosz.golaszewski@linaro.org \
--cc=brgl@bgdev.pl \
--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