minix/test
David van Moolenbroek 74302b1a47 PM: resolve fork/kill race condition
When a process forks, VFS is informed on behalf of the child. This is
correct, because otherwise signals to the new child could get lost.
However, that means that the parent is not blocked from being killed
by a signal while the child is blocked on this VFS call. As a result,
by the time that the VFS reply comes in, the parent may already be
dead, and the child may thus have been assigned a new parent: INIT.

Previously, PM would blindly reply to the parent when the VFS reply
for the fork came in. Thus, it could end up sending a reply to INIT,
even though INIT did not issue the fork(2) call. This could end up
satisfying a different call from INIT (typically waitpid(2)) and then
cause an error when that other call was complete.

It would be possible to set VFS_CALL on both forking parent and child.
This patch instead adds a flag (NEW_PARENT) to note that a process's
parent has changed during a VFS call.

Change-Id: Iad930b2e441db54fe6f7d2fd011f0f6a26e2923d
2013-11-05 18:26:28 +01:00
..
blocktest work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
ds Removing obsolete _MINIX define 2013-02-26 09:44:20 +00:00
fbdtest Add fbd -- Faulty Block Device driver 2011-12-11 22:45:46 +01:00
ipc Removing obsolete _MINIX define 2013-02-26 09:44:20 +00:00
kernel kernel: move do_padconf and add a test case 2013-08-29 09:23:10 -04:00
safecopy Removing obsolete _MINIX define 2013-02-26 09:44:20 +00:00
common.c Fix e_f to print the saved errno. 2013-08-23 13:20:42 +02:00
common.h many new tests 2013-04-19 16:21:48 +00:00
magic.h tests cleanup 2013-04-17 22:00:59 +00:00
Makefile PM: rework signal handling 2013-11-05 18:26:22 +01:00
mod.c ld.so: be more mmap()-behaviour-independent 2012-06-25 14:13:07 +02:00
run PM: rework signal handling 2013-11-05 18:26:22 +01:00
t10a.c retire _PROTOTYPE 2012-03-25 16:17:10 +02:00
t11a.c retire _PROTOTYPE 2012-03-25 16:17:10 +02:00
t11b.c retire _PROTOTYPE 2012-03-25 16:17:10 +02:00
t40a.c tests cleanup 2013-04-17 22:00:59 +00:00
t40b.c tests cleanup 2013-04-17 22:00:59 +00:00
t40c.c work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
t40d.c tests cleanup 2013-04-17 22:00:59 +00:00
t40e.c tests cleanup 2013-04-17 22:00:59 +00:00
t40f.c tests cleanup 2013-04-17 22:00:59 +00:00
t40g.c work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
t60a.c Implement issetugid syscall 2011-11-28 10:03:43 +00:00
t60b.c Implement issetugid syscall 2011-11-28 10:03:43 +00:00
t67a.c test67: test opening files and sockets with O_CLOEXEC 2013-02-28 10:08:54 +00:00
t67b.c test67: test opening files and sockets with O_CLOEXEC 2013-02-28 10:08:54 +00:00
t68a.c test68: test pipe2 functionality 2013-02-28 10:08:54 +00:00
t68b.c test68: test pipe2 functionality 2013-02-28 10:08:54 +00:00
test1.c tests cleanup 2013-04-17 22:00:59 +00:00
test2.c work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
test3.c tests cleanup 2013-04-17 22:00:59 +00:00
test4.c tests cleanup 2013-04-17 22:00:59 +00:00
test5.c tests cleanup 2013-04-17 22:00:59 +00:00
test6.c tests cleanup 2013-04-17 22:00:59 +00:00
test7.c tests cleanup 2013-04-17 22:00:59 +00:00
test8.c tests cleanup 2013-04-17 22:00:59 +00:00
test9.c tests cleanup 2013-04-17 22:00:59 +00:00
test10.c tests cleanup 2013-04-17 22:00:59 +00:00
test11.c tests cleanup 2013-04-17 22:00:59 +00:00
test12.c tests cleanup 2013-04-17 22:00:59 +00:00
test13.c tests cleanup 2013-04-17 22:00:59 +00:00
test14.c tests cleanup 2013-04-17 22:00:59 +00:00
test15.c tests cleanup 2013-04-17 22:00:59 +00:00
test16.c tests cleanup 2013-04-17 22:00:59 +00:00
test17.c tests cleanup 2013-04-17 22:00:59 +00:00
test18.c tests cleanup 2013-04-17 22:00:59 +00:00
test19.c tests cleanup 2013-04-17 22:00:59 +00:00
test20.c tests cleanup 2013-04-17 22:00:59 +00:00
test21.c tests cleanup 2013-04-17 22:00:59 +00:00
test22.c tests cleanup 2013-04-17 22:00:59 +00:00
test23.c tests cleanup 2013-04-17 22:00:59 +00:00
test24.c tests cleanup 2013-04-17 22:00:59 +00:00
test25.c tests cleanup 2013-04-17 22:00:59 +00:00
test26.c tests cleanup 2013-04-17 22:00:59 +00:00
test27.c tests cleanup 2013-04-17 22:00:59 +00:00
test28.c tests cleanup 2013-04-17 22:00:59 +00:00
test29.c tests cleanup 2013-04-17 22:00:59 +00:00
test30.c tests cleanup 2013-04-17 22:00:59 +00:00
test31.c tests cleanup 2013-04-17 22:00:59 +00:00
test32.c tests cleanup 2013-04-17 22:00:59 +00:00
test33.c tests cleanup 2013-04-17 22:00:59 +00:00
test34.c tests cleanup 2013-04-17 22:00:59 +00:00
test35.c tests cleanup 2013-04-17 22:00:59 +00:00
test36.c tests cleanup 2013-04-17 22:00:59 +00:00
test37.c tests cleanup 2013-04-17 22:00:59 +00:00
test38.c tests cleanup 2013-04-17 22:00:59 +00:00
test39.c tests cleanup 2013-04-17 22:00:59 +00:00
test40.c work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
test41.c tests cleanup 2013-04-17 22:00:59 +00:00
test42.c test42: skip single step test 2013-06-25 13:51:24 +02:00
test43.c tests cleanup 2013-04-17 22:00:59 +00:00
test44.c tests cleanup 2013-04-17 22:00:59 +00:00
test45.c tests cleanup 2013-04-17 22:00:59 +00:00
test45.h tests cleanup 2013-04-17 22:00:59 +00:00
test46.c tests cleanup 2013-04-17 22:00:59 +00:00
test47.c tests cleanup 2013-04-17 22:00:59 +00:00
test48.c tests cleanup 2013-04-17 22:00:59 +00:00
test49.c tests cleanup 2013-04-17 22:00:59 +00:00
test50.c tests cleanup 2013-04-17 22:00:59 +00:00
test51.c tests cleanup 2013-04-17 22:00:59 +00:00
test52.c tests cleanup 2013-04-17 22:00:59 +00:00
test53.c tests cleanup 2013-04-17 22:00:59 +00:00
test54.c arm:fix for test54 and test55 2013-09-27 15:15:37 +02:00
test55.c work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
test56.c test56: fix race condition 2013-11-05 18:25:52 +01:00
test57.c tests cleanup 2013-04-17 22:00:59 +00:00
test57loop.S Macros for symbols used in both ASM and C 2010-08-17 16:44:07 +00:00
test58.c tests cleanup 2013-04-17 22:00:59 +00:00
test59.c tests cleanup 2013-04-17 22:00:59 +00:00
test60.c tests cleanup 2013-04-17 22:00:59 +00:00
test61.c tests cleanup 2013-04-17 22:00:59 +00:00
test62.c tests cleanup 2013-04-17 22:00:59 +00:00
test63.c tests cleanup 2013-04-17 22:00:59 +00:00
test64.c tests cleanup 2013-04-17 22:00:59 +00:00
test65.c tests cleanup 2013-04-17 22:00:59 +00:00
test66.c tests cleanup 2013-04-17 22:00:59 +00:00
test66expected.h test66: float smoke test, floating point fixes (arm) 2013-02-20 12:29:37 +00:00
test67.c tests cleanup 2013-04-17 22:00:59 +00:00
test68.c tests cleanup 2013-04-17 22:00:59 +00:00
test69.c tests cleanup 2013-04-17 22:00:59 +00:00
test70.c test70: reduce ITERATIONS 2013-09-16 15:33:44 +00:00
test71.c vm: mmap support 2013-05-31 15:42:01 +00:00
test72.c work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
test73.c many new tests 2013-04-19 16:21:48 +00:00
test74.c vm: mmap support 2013-05-31 15:42:01 +00:00
test75.c test75: fix child run time check bug 2013-10-14 13:20:44 +02:00
test76.c work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
test77.c work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
test79.c PM: resolve fork/kill race condition 2013-11-05 18:26:28 +01:00
testcache.c vm: mmap support 2013-05-31 15:42:01 +00:00
testcache.h vm: mmap support 2013-05-31 15:42:01 +00:00
testinterp.sh vfs,avfs: verify an interpreter was found on #! line 2011-12-21 23:44:13 +01:00
testsh1.sh Importing usr.bin/wc 2013-08-25 18:51:35 +02:00
testsh2.sh Importing usr.bin/hexdump 2013-10-29 15:18:45 -04:00
testvm.c work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
testvm.conf work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
testvm.h many new tests 2013-04-19 16:21:48 +00:00
testvnd.sh work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00
tvnd.c work-3.2.1 squash commit 2013-11-05 18:25:04 +01:00