All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kent Gibson <warthog618@gmail.com>
To: Bartosz Golaszewski <brgl@bgdev.pl>
Cc: Linus Walleij <linus.walleij@linaro.org>,
	linux-gpio@vger.kernel.org,
	Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Subject: Re: [libgpiod][PATCH] bindings: cxx: tests: set direction when reconfiguring lines
Date: Mon, 8 Jul 2024 18:00:23 +0800	[thread overview]
Message-ID: <20240708100023.GA195083@rigel> (raw)
In-Reply-To: <20240708094827.84986-1-brgl@bgdev.pl>

On Mon, Jul 08, 2024 at 11:48:27AM +0200, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
>
> Linux kernel commit b44039638741 ("gpiolib: cdev: Ignore reconfiguration
> without direction") made the direction setting mandatory for line config
> passed to the kernel when reconfiguring requested lines. Fix the C++ test
> case which doesn't do it and now fails due to the rest of the settings
> being ignored.
>
> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
> ---
>  bindings/cxx/tests/tests-line-request.cpp | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/bindings/cxx/tests/tests-line-request.cpp b/bindings/cxx/tests/tests-line-request.cpp
> index af8b979..a99bd44 100644
> --- a/bindings/cxx/tests/tests-line-request.cpp
> +++ b/bindings/cxx/tests/tests-line-request.cpp
> @@ -208,6 +208,7 @@ TEST_CASE("values can be read", "[line-request]")
>  				.add_line_settings(
>  					offs,
>  					::gpiod::line_settings()
> +						.set_direction(direction::INPUT)
>  						.set_active_low(true))
>  		);
>

My bad - I hadn't tried the C++ or Rust tests with that patch, or I
would've patched these myself.

Reviewed-by: Kent Gibson <warthog618@gmail.com>

for both C++ and Rust.


  reply	other threads:[~2024-07-08 10:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-08  9:48 [libgpiod][PATCH] bindings: cxx: tests: set direction when reconfiguring lines Bartosz Golaszewski
2024-07-08 10:00 ` Kent Gibson [this message]
2024-07-08 18:53 ` 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=20240708100023.GA195083@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 \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.