* [PATCH] selftest: gpio: remove obsolete gpio-mockup test
@ 2024-03-05 0:21 Kent Gibson
2024-03-05 15:52 ` Christophe Leroy
2024-03-05 19:02 ` Bartosz Golaszewski
0 siblings, 2 replies; 3+ messages in thread
From: Kent Gibson @ 2024-03-05 0:21 UTC (permalink / raw)
To: linux-kernel, linux-kselftest, linux-gpio, bartosz.golaszewski,
andriy.shevchenko, christophe.leroy, shuah, bamv2005
Cc: Kent Gibson, Pengfei Xu, Yi Lai
With the removal of the ARCH_NR_GPIOS, the number of available GPIOs
is effectively unlimited, causing the gpio-mockup module load failure
test that overflowed the number of GPIOs to unexpectedly succeed, and
so fail.
The test is no longer relevant so remove it.
Promote the "no lines defined" test so there is still one load
failure test in the basic set.
Fixes: 7b61212f2a07 ("gpiolib: Get rid of ARCH_NR_GPIOS")
Reported-by: Pengfei Xu <pengfei.xu@intel.com>
Reported-by: Yi Lai <yi1.lai@intel.com>
Closes: https://lore.kernel.org/linux-gpio/ZC6OHBjdwBdT4sSb@xpf.sh.intel.com/
Signed-off-by: Kent Gibson <warthog618@gmail.com>
---
tools/testing/selftests/gpio/gpio-mockup.sh | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/tools/testing/selftests/gpio/gpio-mockup.sh b/tools/testing/selftests/gpio/gpio-mockup.sh
index 0d6c5f7f95d2..fc2dd4c24d06 100755
--- a/tools/testing/selftests/gpio/gpio-mockup.sh
+++ b/tools/testing/selftests/gpio/gpio-mockup.sh
@@ -377,13 +377,10 @@ if [ "$full_test" ]; then
insmod_test "0,32,32,44,-1,22,-1,31" 32 12 22 31
fi
echo "2. Module load error tests"
-echo "2.1 gpio overflow"
-# Currently: The max number of gpio(1024) is defined in arm architecture.
-insmod_test "-1,1024"
+echo "2.1 no lines defined"
+insmod_test "0,0"
if [ "$full_test" ]; then
- echo "2.2 no lines defined"
- insmod_test "0,0"
- echo "2.3 ignore range overlap"
+ echo "2.2 ignore range overlap"
insmod_test "0,32,0,1" 32
insmod_test "0,32,1,5" 32
insmod_test "0,32,30,35" 32
--
2.39.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] selftest: gpio: remove obsolete gpio-mockup test
2024-03-05 0:21 [PATCH] selftest: gpio: remove obsolete gpio-mockup test Kent Gibson
@ 2024-03-05 15:52 ` Christophe Leroy
2024-03-05 19:02 ` Bartosz Golaszewski
1 sibling, 0 replies; 3+ messages in thread
From: Christophe Leroy @ 2024-03-05 15:52 UTC (permalink / raw)
To: Kent Gibson, linux-kernel@vger.kernel.org,
linux-kselftest@vger.kernel.org, linux-gpio@vger.kernel.org,
bartosz.golaszewski@linaro.org, andriy.shevchenko@linux.intel.com,
shuah@kernel.org, bamv2005@gmail.com
Cc: Pengfei Xu, Yi Lai
Le 05/03/2024 à 01:21, Kent Gibson a écrit :
> [Vous ne recevez pas souvent de courriers de warthog618@gmail.com. Découvrez pourquoi ceci est important à https://aka.ms/LearnAboutSenderIdentification ]
>
> With the removal of the ARCH_NR_GPIOS, the number of available GPIOs
> is effectively unlimited, causing the gpio-mockup module load failure
> test that overflowed the number of GPIOs to unexpectedly succeed, and
> so fail.
>
> The test is no longer relevant so remove it.
> Promote the "no lines defined" test so there is still one load
> failure test in the basic set.
>
> Fixes: 7b61212f2a07 ("gpiolib: Get rid of ARCH_NR_GPIOS")
> Reported-by: Pengfei Xu <pengfei.xu@intel.com>
> Reported-by: Yi Lai <yi1.lai@intel.com>
> Closes: https://lore.kernel.org/linux-gpio/ZC6OHBjdwBdT4sSb@xpf.sh.intel.com/
> Signed-off-by: Kent Gibson <warthog618@gmail.com>
Acked-by: Christophe Leroy <christophe.leroy@csgroup.eu>
> ---
> tools/testing/selftests/gpio/gpio-mockup.sh | 9 +++------
> 1 file changed, 3 insertions(+), 6 deletions(-)
>
> diff --git a/tools/testing/selftests/gpio/gpio-mockup.sh b/tools/testing/selftests/gpio/gpio-mockup.sh
> index 0d6c5f7f95d2..fc2dd4c24d06 100755
> --- a/tools/testing/selftests/gpio/gpio-mockup.sh
> +++ b/tools/testing/selftests/gpio/gpio-mockup.sh
> @@ -377,13 +377,10 @@ if [ "$full_test" ]; then
> insmod_test "0,32,32,44,-1,22,-1,31" 32 12 22 31
> fi
> echo "2. Module load error tests"
> -echo "2.1 gpio overflow"
> -# Currently: The max number of gpio(1024) is defined in arm architecture.
> -insmod_test "-1,1024"
> +echo "2.1 no lines defined"
> +insmod_test "0,0"
> if [ "$full_test" ]; then
> - echo "2.2 no lines defined"
> - insmod_test "0,0"
> - echo "2.3 ignore range overlap"
> + echo "2.2 ignore range overlap"
> insmod_test "0,32,0,1" 32
> insmod_test "0,32,1,5" 32
> insmod_test "0,32,30,35" 32
> --
> 2.39.2
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] selftest: gpio: remove obsolete gpio-mockup test
2024-03-05 0:21 [PATCH] selftest: gpio: remove obsolete gpio-mockup test Kent Gibson
2024-03-05 15:52 ` Christophe Leroy
@ 2024-03-05 19:02 ` Bartosz Golaszewski
1 sibling, 0 replies; 3+ messages in thread
From: Bartosz Golaszewski @ 2024-03-05 19:02 UTC (permalink / raw)
To: Kent Gibson
Cc: linux-kernel, linux-kselftest, linux-gpio, bartosz.golaszewski,
andriy.shevchenko, christophe.leroy, shuah, bamv2005, Pengfei Xu,
Yi Lai
On Tue, Mar 5, 2024 at 1:26 AM Kent Gibson <warthog618@gmail.com> wrote:
>
> With the removal of the ARCH_NR_GPIOS, the number of available GPIOs
> is effectively unlimited, causing the gpio-mockup module load failure
> test that overflowed the number of GPIOs to unexpectedly succeed, and
> so fail.
>
> The test is no longer relevant so remove it.
> Promote the "no lines defined" test so there is still one load
> failure test in the basic set.
>
> Fixes: 7b61212f2a07 ("gpiolib: Get rid of ARCH_NR_GPIOS")
> Reported-by: Pengfei Xu <pengfei.xu@intel.com>
> Reported-by: Yi Lai <yi1.lai@intel.com>
> Closes: https://lore.kernel.org/linux-gpio/ZC6OHBjdwBdT4sSb@xpf.sh.intel.com/
> Signed-off-by: Kent Gibson <warthog618@gmail.com>
> ---
> tools/testing/selftests/gpio/gpio-mockup.sh | 9 +++------
> 1 file changed, 3 insertions(+), 6 deletions(-)
>
> diff --git a/tools/testing/selftests/gpio/gpio-mockup.sh b/tools/testing/selftests/gpio/gpio-mockup.sh
> index 0d6c5f7f95d2..fc2dd4c24d06 100755
> --- a/tools/testing/selftests/gpio/gpio-mockup.sh
> +++ b/tools/testing/selftests/gpio/gpio-mockup.sh
> @@ -377,13 +377,10 @@ if [ "$full_test" ]; then
> insmod_test "0,32,32,44,-1,22,-1,31" 32 12 22 31
> fi
> echo "2. Module load error tests"
> -echo "2.1 gpio overflow"
> -# Currently: The max number of gpio(1024) is defined in arm architecture.
> -insmod_test "-1,1024"
> +echo "2.1 no lines defined"
> +insmod_test "0,0"
> if [ "$full_test" ]; then
> - echo "2.2 no lines defined"
> - insmod_test "0,0"
> - echo "2.3 ignore range overlap"
> + echo "2.2 ignore range overlap"
> insmod_test "0,32,0,1" 32
> insmod_test "0,32,1,5" 32
> insmod_test "0,32,30,35" 32
> --
> 2.39.2
>
>
Applied, thanks!
Bart
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-03-05 19:02 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-05 0:21 [PATCH] selftest: gpio: remove obsolete gpio-mockup test Kent Gibson
2024-03-05 15:52 ` Christophe Leroy
2024-03-05 19:02 ` Bartosz Golaszewski
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox