Commit Graph

4 Commits

Author SHA1 Message Date
Tiezhu Yang ba70290678 selftests: gpio: Use "grep -E" instead of "egrep"
The latest version of grep claims the egrep is now obsolete so the build
now contains warnings that look like:
	egrep: warning: egrep is obsolescent; using grep -E
fix this up by moving the related file to use "grep -E" instead.

  sed -i "s/egrep/grep -E/g" `grep egrep -rwl tools/testing/selftests/gpio`

Here are the steps to install the latest grep:

  wget http://ftp.gnu.org/gnu/grep/grep-3.8.tar.gz
  tar xf grep-3.8.tar.gz
  cd grep-3.8 && ./configure && make
  sudo make install
  export PATH=/usr/local/bin:$PATH

Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
2022-11-25 10:57:23 -07:00
Bartosz Golaszewski 36ccddf80e selftests: gpio: gpio-sim: avoid forking test twice
Use '-o' within [] in order to avoid spawning two processes for test.

Suggested-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
2021-12-17 12:26:13 +01:00
Bartosz Golaszewski f7eda6fe03 selftests: gpio: gpio-sim: remove bashisms
'==' is a bashisms and not understood by POSIX shell. Drop it from
gpio-sim selftests.

Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
2021-12-17 12:26:13 +01:00
Bartosz Golaszewski 1d96b8f635 selftests: gpio: add test cases for gpio-sim
Add a set of tests for the new gpio-sim module. This is a pure shell
test-suite and uses the helper programs available in the gpio selftests
directory. These test-cases only test the functionalities exposed by the
gpio-sim driver, not those handled by core gpiolib code.

Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
2021-12-17 12:26:13 +01:00