Skip to contentSkip to conversation

Fix landlock06 test

PATCH In review Andreas Schwab 2 participants 6 messages Aug 13, 2024

lore
Share & tools
lore
#1 lore raw
In reply to Andreas Schwab

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?

Quoted 13 lines · Andreas Schwab

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

---
  testcases/kernel/syscalls/landlock/landlock06.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
testcases/kernel/syscalls/landlock/landlock06.c +0 -0
index 4dc1f532a..1a6e59241 100644

testcases/kernel/syscalls/landlock/landlock06.c static void run(void) · line 34

Quoted 8 lines
testcases/kernel/syscalls/landlock/landlock06.c +1 -1
@@ -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

Signature · 1 line
Mailing list info: https://lists.linux.it/listinfo/ltp
#0 lore raw

PATCH 1/1 Fix landlock06 test

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

---
 testcases/kernel/syscalls/landlock/landlock06.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
testcases/kernel/syscalls/landlock/landlock06.c +1 -1
index 4dc1f532a..1a6e59241 100644
@@ -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));
Signature · 10 lines
2.46.0


-- 
Andreas Schwab, SUSE Labs, [email protected]
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
#2 lore raw
In reply to Andrea Cervesato via ltp
Quoted 1 line · Andrea Cervesato

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

I don't understand this question. Please expand.

Signature · 6 lines
Andreas Schwab, SUSE Labs, [email protected]
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
#3 lore raw

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.

Quoted 5 lines · Andreas Schwab
Quoted 1 line · Andrea Cervesato

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

I don't understand this question. Please expand.

Signature · 1 line
Mailing list info: https://lists.linux.it/listinfo/ltp
#4 lore raw
Quoted 1 line · Andrea Cervesato

My question was if you tested it locally,

Yes, I did.

Signature · 6 lines
Andreas Schwab, SUSE Labs, [email protected]
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