All of lore.kernel.org
 help / color / mirror / Atom feed
* [LTP] [PATCH] Fix landlock06 test
@ 2024-08-13  8:11 Andreas Schwab
  2024-08-13  8:19 ` Andrea Cervesato via ltp
  0 siblings, 1 reply; 6+ messages in thread
From: Andreas Schwab @ 2024-08-13  8:11 UTC (permalink / raw)
  To: ltp

Initialize the flag variable, so that FIOASYNC does not spuriously fail
with ENOTTY (/dev/zero has no support for FASYNC).

Signed-off-by: Andreas Schwab <schwab@suse.de>
---
 testcases/kernel/syscalls/landlock/landlock06.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/testcases/kernel/syscalls/landlock/landlock06.c b/testcases/kernel/syscalls/landlock/landlock06.c
index 4dc1f532a..1a6e59241 100644
--- a/testcases/kernel/syscalls/landlock/landlock06.c
+++ b/testcases/kernel/syscalls/landlock/landlock06.c
@@ -28,7 +28,7 @@ static void run(void)
 	if (SAFE_FORK())
 		return;
 
-	int flag;
+	int flag = 0;
 	size_t sz = 0;
 
 	TST_EXP_PASS(ioctl(file_fd, FIONREAD, &sz));
-- 
2.46.0


-- 
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE  1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [LTP] [PATCH] Fix landlock06 test
  2024-08-13  8:11 [LTP] [PATCH] Fix landlock06 test Andreas Schwab
@ 2024-08-13  8:19 ` Andrea Cervesato via ltp
  2024-08-13  8:47   ` Andreas Schwab
  0 siblings, 1 reply; 6+ messages in thread
From: Andrea Cervesato via ltp @ 2024-08-13  8:19 UTC (permalink / raw)
  To: Andreas Schwab, ltp

Hi Andreas,

thank you for this patch. I was just about to debug the test and to find 
a solution :-)
Do you have a validation test (for example in openQA) for this patch?

On 8/13/24 10:11, Andreas Schwab wrote:
> Initialize the flag variable, so that FIOASYNC does not spuriously fail
> with ENOTTY (/dev/zero has no support for FASYNC).
>
> Signed-off-by: Andreas Schwab <schwab@suse.de>
> ---
>   testcases/kernel/syscalls/landlock/landlock06.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/testcases/kernel/syscalls/landlock/landlock06.c b/testcases/kernel/syscalls/landlock/landlock06.c
> index 4dc1f532a..1a6e59241 100644
> --- a/testcases/kernel/syscalls/landlock/landlock06.c
> +++ b/testcases/kernel/syscalls/landlock/landlock06.c
> @@ -28,7 +28,7 @@ static void run(void)
>   	if (SAFE_FORK())
>   		return;
>   
> -	int flag;
> +	int flag = 0;
>   	size_t sz = 0;
>   
>   	TST_EXP_PASS(ioctl(file_fd, FIONREAD, &sz));
Andrea

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [LTP] [PATCH] Fix landlock06 test
  2024-08-13  8:19 ` Andrea Cervesato via ltp
@ 2024-08-13  8:47   ` Andreas Schwab
  2024-08-13  8:53     ` Andrea Cervesato via ltp
  0 siblings, 1 reply; 6+ messages in thread
From: Andreas Schwab @ 2024-08-13  8:47 UTC (permalink / raw)
  To: Andrea Cervesato; +Cc: ltp

On Aug 13 2024, Andrea Cervesato wrote:

> Do you have a validation test (for example in openQA) for this patch?

I don't understand this question.  Please expand.

-- 
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE  1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [LTP] [PATCH] Fix landlock06 test
  2024-08-13  8:47   ` Andreas Schwab
@ 2024-08-13  8:53     ` Andrea Cervesato via ltp
  2024-08-13  9:09       ` Andreas Schwab
  0 siblings, 1 reply; 6+ messages in thread
From: Andrea Cervesato via ltp @ 2024-08-13  8:53 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: ltp

We had some testing failures in openSUSE TW which can be reproduced 
publicly in openQA, both for Jeos and x86_64:

https://openqa.opensuse.org/tests/4394255#step/landlock06/7
https://openqa.opensuse.org/tests/4398508#step/landlock06/7

My question was if you tested it locally, or you have a link to a public 
testing for different platforms. I can eventually trigger them otherwise.

On 8/13/24 10:47, Andreas Schwab wrote:
> On Aug 13 2024, Andrea Cervesato wrote:
>
>> Do you have a validation test (for example in openQA) for this patch?
> I don't understand this question.  Please expand.
>

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [LTP] [PATCH] Fix landlock06 test
  2024-08-13  8:53     ` Andrea Cervesato via ltp
@ 2024-08-13  9:09       ` Andreas Schwab
  2024-08-13 11:27         ` Andrea Cervesato via ltp
  0 siblings, 1 reply; 6+ messages in thread
From: Andreas Schwab @ 2024-08-13  9:09 UTC (permalink / raw)
  To: Andrea Cervesato; +Cc: ltp

On Aug 13 2024, Andrea Cervesato wrote:

> My question was if you tested it locally,

Yes, I did.

-- 
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE  1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [LTP] [PATCH] Fix landlock06 test
  2024-08-13  9:09       ` Andreas Schwab
@ 2024-08-13 11:27         ` Andrea Cervesato via ltp
  0 siblings, 0 replies; 6+ messages in thread
From: Andrea Cervesato via ltp @ 2024-08-13 11:27 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: ltp

The patch works well in Tumbleweed: 
https://openqa.opensuse.org/tests/4401154#step/landlock06/8

I will push the fix in the upstream.

Reviewed-by: Andrea Cervesato <andrea.cervesato@suse.com>


Thank you,
Andrea

On 8/13/24 11:09, Andreas Schwab wrote:
> On Aug 13 2024, Andrea Cervesato wrote:
>
>> My question was if you tested it locally,
> Yes, I did.
>

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2024-08-13 11:28 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-13  8:11 [LTP] [PATCH] Fix landlock06 test Andreas Schwab
2024-08-13  8:19 ` Andrea Cervesato via ltp
2024-08-13  8:47   ` Andreas Schwab
2024-08-13  8:53     ` Andrea Cervesato via ltp
2024-08-13  9:09       ` Andreas Schwab
2024-08-13 11:27         ` Andrea Cervesato via ltp

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.