wait4(): retrieve dead team entries usage information.

* This adds a parameter to the wait_for_child syscall. I extended the test case
to show the actual retrieved information.
* fix #13546
This commit is contained in:
Jérôme Duval
2017-10-10 17:20:46 +02:00
parent c80ec6a9fe
commit a295d3f46e
7 changed files with 52 additions and 20 deletions
+2 -1
View File
@@ -69,7 +69,8 @@ thread_id _user_load_image(const char* const* flatArgs, size_t flatArgsSize,
status_t _user_wait_for_team(team_id id, status_t *_returnCode);
void _user_exit_team(status_t returnValue);
status_t _user_kill_team(thread_id thread);
pid_t _user_wait_for_child(thread_id child, uint32 flags, siginfo_t* info);
pid_t _user_wait_for_child(thread_id child, uint32 flags, siginfo_t* info,
team_usage_info* usageInfo);
status_t _user_exec(const char *path, const char* const* flatArgs,
size_t flatArgsSize, int32 argCount, int32 envCount, mode_t umask);
thread_id _user_fork(void);
+2
View File
@@ -116,6 +116,8 @@ struct job_control_entry : DoublyLinkedListLinkImpl<job_control_entry> {
status_t status;
uint16 reason; // reason for the team's demise, one of the
// CLD_* values defined in <signal.h>
bigtime_t user_time;
bigtime_t kernel_time;
job_control_entry();
~job_control_entry();
+1 -1
View File
@@ -141,7 +141,7 @@ extern status_t _kern_kill_team(team_id team);
extern team_id _kern_get_current_team();
extern status_t _kern_wait_for_team(team_id team, status_t *_returnCode);
extern pid_t _kern_wait_for_child(thread_id child, uint32 flags,
siginfo_t* info);
siginfo_t* info, team_usage_info* usageInfo);
extern status_t _kern_exec(const char *path, const char* const* flatArgs,
size_t flatArgsSize, int32 argCount, int32 envCount,
mode_t umask);