Linux GPIO subsystem development
 help / color / mirror / Atom feed
From: andy.shevchenko@gmail.com
To: joe.slater@windriver.com
Cc: linux-gpio@vger.kernel.org, randy.macleod@windriver.com
Subject: Re: [v2][libgpiod][PATCH 1/1] gpio-tools-test.bats: modify delays in toggle test
Date: Mon, 5 Jun 2023 23:03:33 +0300	[thread overview]
Message-ID: <ZH4_lSlcDD6d5ZBa@surfacebook> (raw)
In-Reply-To: <20230605190051.3915571-1-joe.slater@windriver.com>

Mon, Jun 05, 2023 at 12:00:51PM -0700, joe.slater@windriver.com kirjoitti:
> From: Joe Slater <joe.slater@windriver.com>
> 
> The test "gpioset: toggle (continuous)" uses fixed delays to test
> toggling values.  This is not reliable, so we switch to looking
> for transitions from one value to another.
> 
> We wait for a transition up to 1.5 seconds.

...

> +gpiosim_wait_value() {
> +	local OFFSET=$2
> +	local EXPECTED=$3
> +	local DEVNAME=${GPIOSIM_DEV_NAME[$1]}
> +	local CHIPNAME=${GPIOSIM_CHIP_NAME[$1]}
> +	local PORT=$GPIOSIM_SYSFS/$DEVNAME/$CHIPNAME/sim_gpio$OFFSET/value
> +
> +	for i in {1..15} ; do

Do you need space before semicolon?

> +		[ "$(<$PORT)" = "$EXPECTED" ] && return
> +		sleep 0.1
> +	done
> +	return 1
> +}

...

> -			for LINE in $(find $BANKPATH/ | grep -E "line[0-9]+$")
> +			for LINE in $(find $BANKPATH/ | egrep "line[0-9]+$")

Seems stray change.

-- 
With Best Regards,
Andy Shevchenko



  reply	other threads:[~2023-06-05 20:03 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-05 19:00 [v2][libgpiod][PATCH 1/1] gpio-tools-test.bats: modify delays in toggle test joe.slater
2023-06-05 20:03 ` andy.shevchenko [this message]
2023-06-05 20:42   ` Slater, Joseph

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=ZH4_lSlcDD6d5ZBa@surfacebook \
    --to=andy.shevchenko@gmail.com \
    --cc=joe.slater@windriver.com \
    --cc=linux-gpio@vger.kernel.org \
    --cc=randy.macleod@windriver.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