Skip to contentSkip to conversation

fcntl33: weakup child before exit if fail in parent

PATCH New Murphy Zhou 3 participants 5 messages Apr 30, 2019 – May 23, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 fcntl33: weakup child before exit if fail in parent

Now it failis on overlayfs this way:
fcntl33.c:120: INFO: .... failed on overlapfs as expected: EAGAIN/EWOULDBLOCK tst_checkpoint.c:149: BROK: fcntl33.c:178: tst_checkpoint_wait(0, 10000): ETIMEDOUT tst_test.c:357: BROK: Reported by child (12066)

---
 testcases/kernel/syscalls/fcntl/fcntl33.c | 1 +
 1 file changed, 1 insertion(+)
testcases/kernel/syscalls/fcntl/fcntl33.c +1 -0
index 43dc5a2af..ce27e1006 100644
@@ -121,6 +121,7 @@ static void do_test(unsigned int i)
 		} else {
 			tst_res(TFAIL | TTERRNO, "fcntl() failed to set lease");
 		}
+		TST_CHECKPOINT_WAKE(0);
 		goto exit;
 	}
 
Signature · 1 line
2.21.0
#1 lore raw

PATCH 1/1 fcntl33: weakup child before exit if fail in parent

Quoted 7 lines · Murphy Zhou

Now it failis on overlayfs this way:
fcntl33.c:120: INFO: .... failed on overlapfs as expected:
EAGAIN/EWOULDBLOCK
tst_checkpoint.c:149: BROK: fcntl33.c:178: tst_checkpoint_wait(0, 10000):
ETIMEDOUT
tst_test.c:357: BROK: Reported by child (12066)

I'm wondering that if the parent failed to set lease, should child still valuable to run the remaining test after it being wakened?

Quoted 27 lines
---
 testcases/kernel/syscalls/fcntl/fcntl33.c | 1 +
 1 file changed, 1 insertion(+)
testcases/kernel/syscalls/fcntl/fcntl33.c +1 -1
index 43dc5a2af..ce27e1006 100644
@@ -121,6 +121,7 @@ static void do_test(unsigned int i)
                } else {
                        tst_res(TFAIL | TTERRNO, "fcntl() failed to set
 lease");
                }
+               TST_CHECKPOINT_WAKE(0);
                goto exit;
        }
 
--

2.21.0

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

Signature · 5 lines
Regards,
Li Wang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linux.it/pipermail/ltp/attachments/20190430/356e929d/attachment-0001.html>
#2 lore raw

PATCH 1/1 fcntl33: weakup child before exit if fail in parent

Quoted 10 lines · Li Wang
Quoted 7 lines · Murphy Zhou

Now it failis on overlayfs this way:
fcntl33.c:120: INFO: .... failed on overlapfs as expected:
EAGAIN/EWOULDBLOCK
tst_checkpoint.c:149: BROK: fcntl33.c:178: tst_checkpoint_wait(0, 10000):
ETIMEDOUT
tst_test.c:357: BROK: Reported by child (12066)

Quoted 2 lines

I'm wondering that if the parent failed to set lease, should child still valuable to run the remaining test after it being wakened?

In do_child it just open file and calculate the time spent on it. Also parent will reap the child before exit anyway. That checkpoint is needed while everything goes fine, so even it's not that valuable to run the remaining tests in child, it's not hurting though, :)

Thanks for reviewing!
--
M

Quoted 34 lines
Quoted 29 lines
---
 testcases/kernel/syscalls/fcntl/fcntl33.c | 1 +
 1 file changed, 1 insertion(+)
testcases/kernel/syscalls/fcntl/fcntl33.c +1 -1
index 43dc5a2af..ce27e1006 100644
@@ -121,6 +121,7 @@ static void do_test(unsigned int i)
                } else {
                        tst_res(TFAIL | TTERRNO, "fcntl() failed to set
 lease");
                }
+               TST_CHECKPOINT_WAKE(0);
                goto exit;
        }
 
--

2.21.0

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

Signature · 2 lines
Regards,
Li Wang
#3 lore raw

PATCH 1/1 fcntl33: weakup child before exit if fail in parent

Quoted 12 lines · Murphy Zhou
Quoted 6 lines · Li Wang
Quoted 4 lines · Murphy Zhou

Now it failis on overlayfs this way:
fcntl33.c:120: INFO: .... failed on overlapfs as expected:
EAGAIN/EWOULDBLOCK
tst_checkpoint.c:149: BROK: fcntl33.c:178: tst_checkpoint_wait(0,

10000):

Quoted 4 lines
Quoted 3 lines

ETIMEDOUT
tst_test.c:357: BROK: Reported by child (12066)

Quoted 8 lines
Quoted 2 lines

I'm wondering that if the parent failed to set lease, should child still valuable to run the remaining test after it being wakened?

In do_child it just open file and calculate the time spent on it. Also parent will reap the child before exit anyway. That checkpoint is needed while everything goes fine, so even it's not that valuable to run the remaining tests in child, it's not hurting though, :)

Indeed, it sounds reasonable to me.

Quoted 39 lines

Thanks for reviewing!
--
M

Quoted 34 lines
Quoted 26 lines
---
 testcases/kernel/syscalls/fcntl/fcntl33.c | 1 +
 1 file changed, 1 insertion(+)
testcases/kernel/syscalls/fcntl/fcntl33.c +1 -1
index 43dc5a2af..ce27e1006 100644
@@ -121,6 +121,7 @@ static void do_test(unsigned int i)
                } else {
                        tst_res(TFAIL | TTERRNO, "fcntl() failed to set
 lease");
                }
+               TST_CHECKPOINT_WAKE(0);
                goto exit;
        }
 
--

2.21.0

Quoted 3 lines

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

--
Regards,
Li Wang

Signature · 5 lines
Regards,
Li Wang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linux.it/pipermail/ltp/attachments/20190430/4a25ec52/attachment.html>