aboutsummaryrefslogtreecommitdiff
path: root/proc
Commit message (Collapse)AuthorAgeFilesLines
* .Roland McGrath2002-06-051-0/+5
|
* 2002-06-05 Roland McGrath <roland@frob.com>Roland McGrath2002-06-051-0/+8
| | | | | * info.c (S_proc_getprocinfo): If PI_FETCH_TASKEVENTS is set in *FLAGS, fill in PI->taskevents using task_info with TASK_EVENTS_INFO.
* .Roland McGrath2002-05-081-0/+20
|
* 2002-05-07 Roland McGrath <roland@frob.com>Roland McGrath2002-05-082-45/+45
| | | | | | | | * mgt.c (S_proc_reauthenticate, S_proc_getallpids): Likewise. (add_tasks, S_proc_dostop): Likewise. (S_proc_exception_raise): int -> integer_t * pgrp.c (S_proc_getsessionpids, S_proc_getsessionpgids): Likewise. (S_proc_getpgrppids): Likewise.
* 2002-05-07 Roland McGrath <roland@frob.com>Roland McGrath2002-05-082-44/+58
| | | | | | | | | * host.c (S_proc_setexecdata, S_proc_getexecdata): u_int -> size_t (initialize_version_info): Likewise. Fix cast in host_info arg. (get_string_array): Likewise. * info.c (get_string, S_proc_getprocargs, S_proc_getprocenv): Likewise. (S_proc_getprocinfo, S_proc_getloginpids): Likewise. (S_proc_getprocinfo): int -> size_t; fix casts in *_info argument.
* .Roland McGrath2001-12-221-0/+5
|
* 2001-12-22 Roland McGrath <roland@frob.com>Roland McGrath2001-12-222-14/+17
| | | | | * proc.h (check_owner): Move this extern inline function ... * info.c (check_owner): ... to here, made static inline.
* 2001-08-14 Marcus Brinkmann <marcus@gnu.org>Marcus Brinkmann2001-08-142-1/+9
| | | | | * mgt.c (S_proc_dostop): If task_threads fails, resume the suspended task.
* .Roland McGrath2001-08-061-0/+8
|
* 2001-08-06 Roland McGrath <roland@frob.com>Roland McGrath2001-08-061-1/+1
| | | | | * wait.c (S_proc_wait: reap): Set *PID_STATUS to CHILD->p_pid. Reported by Neal H Walfield <neal@cs.uml.edu>.
* 2001-08-06 Roland McGrath <roland@frob.com>Roland McGrath2001-08-061-1/+1
| | | | | * mgt.c (allocate_proc): Don't zero P->p_pi. Reported by Neal H Walfield <neal@cs.uml.edu>.
* .Roland McGrath2001-08-051-0/+5
|
* 2001-08-05 Roland McGrath <roland@frob.com>Roland McGrath2001-08-051-14/+81
| | | | | * wait.c (sample_rusage): New function. (S_proc_mark_exit): Call it.
* .Roland McGrath2001-08-041-0/+10
|
* 2001-08-04 Roland McGrath <roland@frob.com>Roland McGrath2001-08-042-44/+63
| | | | | | | | | | * proc.h (struct proc): New members p_rusage, p_child_rusage. * wait.c (rusage_add): New static function. (alert_parent): Use it to add dead child's p_rusage into parent's p_child_rusage. (S_proc_wait): Fill *RU out param with CHILD->p_rusage, not just zeros. Rewrote subfunction child_ready and its two callers into new subfunction reap to reduce duplicated code.
* 2001-08-04 Roland McGrath <roland@frob.com>Roland McGrath2001-08-041-0/+3
| | | | * mgt.c (process_has_exited): Call ports_interrupt_rpcs last thing.
* .Roland McGrath2001-08-041-0/+10
|
* 2001-08-04 Roland McGrath <roland@frob.com>Roland McGrath2001-08-041-20/+18
| | | | | | | | | * mgt.c (S_proc_reauthenticate): Release global_lock while making RPC. Don't mach_port_deallocate an argument port when returning an error, because mig does it for us. 2001-08-03 Roland McGrath <roland@frob.com> * mgt.c (allocate_proc): Use memset instead of lots of 0 initializers.
* .Roland McGrath2001-08-021-0/+4
|
* 2001-08-01 Roland McGrath <roland@frob.com>Roland McGrath2001-08-021-22/+8
| | | | * mgt.c (genpid): Rewritten.
* 2001-08-02 Marcus Brinkmann <marcus@gnu.org>Marcus Brinkmann2001-08-022-0/+11
| | | | | * mgt.c (genpid): Before checking if NEXTPID is free, check if it is greater than WRAP, and if yes, start over.
* 2001-07-13 Marcus Brinkmann <marcus@gnu.org>Marcus Brinkmann2001-07-132-1/+23
| | | | | | | | | | | * host.c (S_proc_getexecdata): New variable PORTS_ALLOCATED. Set it if we allocated a new buffer for PORTS. If it is set, and allocation of a new buffer for INTS fails, unmap the buffer for PORTS. * host.c (S_proc_getexecdata): New variable I. Go over all standard ports and increase the send right user reference by one. Set *PORTSPOLY to MACH_MSG_TYPE_MOVE_SEND.
* 2001-06-27 Marcus Brinkmann <marcus@gnu.org>Marcus Brinkmann2001-06-272-1/+11
| | | | | * info.c (S_proc_getprocinfo): If we return because mmap failed for *PIARRAY, be sure to munmap THDS if necessary.
* 2001-05-12 Marcus Brinkmann <marcus@gnu.org>Marcus Brinkmann2001-05-122-1/+9
| | | | | * host.c (initialize_version_info): Clear last byte of KV to make sure that the string is null-terminated.
* .Roland McGrath2001-04-151-0/+67
|
* 2000-04-03 Neal H Walfield <neal@cs.uml.edu>Roland McGrath2001-04-151-3/+2
| | | | | | | | | | | | | | | | * proc.h (struct ids): Drop gids and ngids, we never use them. Turn uids into a zero length array. * mgt.c (make_ids): Conform to new semantics. (ids_free): Removed. Rendered obsolete by ids_rele. (ids_rele): New function. Drop a reference to the given ids. (ids_ref): Add a reference to the given ids. (S_proc_reauthenticate): Use ids_rele and new make_ids semantics. (S_proc_child): Use ids_rele and ids_ref. (create_startup_proc): Conform to new make_ids semantics. (complete_proc): Use ids_ref. (process_has_exited): Use ids_rele.
* 2000-04-03 Neal H Walfield <neal@cs.uml.edu>Roland McGrath2001-04-152-5/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * host.c (S_proc_setexecdata): Check for memory allocation errors. Use memcpy, not bcopy. (S_proc_getexecdata): Likewise. (S_proc_execdata_notify): Check return of malloc. (S_proc_register_version): Likewise. (initialize_version_info): Add asserts. * info.c (S_proc_pid2task): Do not bother searching for the pid if we do not have a valid caller. (S_proc_pid2proc): Likewise. Use memcpy, not bcopy. (S_proc_getprocinfo): Doc fixes. Use MAP_FAILED not -1. Use memcpy, not bcopy. (S_proc_getloginpids): Check return value of malloc. Use realloc correctly. (S_proc_setlogin): Check return value of malloc. * main.c (main): Assert allocate_proc. * mgt.c (make_ids): Check return value of malloc and fail accordingly. (S_proc_reauthenticate): Check return value of make_ids and fail accordingly. (S_proc_child): Call task_find after we know that we were passed a valid child. (S_proc_reassign): Likewise. (S_proc_handle_exceptions): Use memcpy, not bcopy. (allocate_proc): Check return value of ports_create_port and fail accordingly. (create_startup_proc): Add asserts. (complete_proc): Do not assume the length of "<none>". * msg.c (S_proc_getmsgport): Call pid_find_allow_zombie after we know we were passed a valid caller. * pgrp.c: Include assert.h. (new_pgrp): Check return value of malloc and fail accordingly. (new_session): Likewise. (boot_setsid): Assert sess. (S_proc_getsessionpids): Use MAP_FAILED not -1. (S_proc_getsessionppids): Likewise. (S_proc_getpgrppids): Likewise. * wait.c (S_proc_wait): Use memset, not bzero.
* 2000-04-03 Neal H Walfield <neal@cs.uml.edu>Roland McGrath2001-04-154-76/+176
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * host.c: Doc fix: ``Implement foo as described in <hurd/proc.defs>'' => ``Implement foo as described in <hurd/process.defs>'' * info.c: Likewise. * mgt.c: Likewise. * pgrp.c: Likewise. * wait.c: Likewise. * host.c (S_proc_setexecdata): Check for memory allocation errors. Use memcpy, not bcopy. (S_proc_getexecdata): Likewise. (S_proc_execdata_notify): Check return of malloc. (S_proc_register_version): Likewise. (initialize_version_info): Add asserts. * info.c (S_proc_pid2task): Do not bother searching for the pid if we do not have a valid caller. (S_proc_pid2proc): Likewise. Use memcpy, not bcopy. (S_proc_getprocinfo): Doc fixes. Use MAP_FAILED not -1. Use memcpy, not bcopy. (S_proc_getloginpids): Check return value of malloc. Use realloc correctly. (S_proc_setlogin): Check return value of malloc. * main.c (main): Assert allocate_proc. * mgt.c (make_ids): Check return value of malloc and fail accordingly. (S_proc_reauthenticate): Check return value of make_ids and fail accordingly. (S_proc_child): Call task_find after we know that we were passed a valid child. (S_proc_reassign): Likewise. (S_proc_handle_exceptions): Use memcpy, not bcopy. (allocate_proc): Check return value of ports_create_port and fail accordingly. (create_startup_proc): Add asserts. (complete_proc): Do not assume the length of "<none>". * msg.c (S_proc_getmsgport): Call pid_find_allow_zombie after we know we were passed a valid caller. * pgrp.c: Include assert.h. (new_pgrp): Check return value of malloc and fail accordingly. (new_session): Likewise. (boot_setsid): Assert sess. (S_proc_getsessionpids): Use MAP_FAILED not -1. (S_proc_getsessionppids): Likewise. (S_proc_getpgrppids): Likewise. * wait.c (S_proc_wait): Use memset, not bzero.
* 2000-04-03 Neal H Walfield <neal@cs.uml.edu>Roland McGrath2001-04-151-61/+84
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * proc.h (struct ids): Drop gids and ngids, we never use them. Turn uids into a zero length array. * mgt.c (make_ids): Conform to new semantics. (ids_free): Removed. Rendered obsolete by ids_rele. (ids_rele): New function. Drop a reference to the given ids. (ids_ref): Add a reference to the given ids. (S_proc_reauthenticate): Use ids_rele and new make_ids semantics. (S_proc_child): Use ids_rele and ids_ref. (create_startup_proc): Conform to new make_ids semantics. (complete_proc): Use ids_ref. (process_has_exited): Use ids_rele. * host.c: Doc fix: ``Implement foo as described in <hurd/proc.defs>'' => ``Implement foo as described in <hurd/process.defs>'' * info.c: Likewise. * mgt.c: Likewise. * pgrp.c: Likewise. * wait.c: Likewise. * mgt.c (S_proc_reauthenticate): Calculate the value of NGEN_UIDS, NAUX_UIDS, NGEN_GIDS AND NAUX_GIDS; do not use a constant. (create_startup_proc): Add asserts. * host.c (S_proc_setexecdata): Check for memory allocation errors. Use memcpy, not bcopy. (S_proc_getexecdata): Likewise. (S_proc_execdata_notify): Check return of malloc. (S_proc_register_version): Likewise. (initialize_version_info): Add asserts. * info.c (S_proc_pid2task): Do not bother searching for the pid if we do not have a valid caller. (S_proc_pid2proc): Likewise. Use memcpy, not bcopy. (S_proc_getprocinfo): Doc fixes. Use MAP_FAILED not -1. Use memcpy, not bcopy. (S_proc_getloginpids): Check return value of malloc. Use realloc correctly. (S_proc_setlogin): Check return value of malloc. * main.c (main): Assert allocate_proc. * mgt.c (make_ids): Check return value of malloc and fail accordingly. (S_proc_reauthenticate): Check return value of make_ids and fail accordingly. (S_proc_child): Call task_find after we know that we were passed a valid child. (S_proc_reassign): Likewise. (S_proc_handle_exceptions): Use memcpy, not bcopy. (allocate_proc): Check return value of ports_create_port and fail accordingly. (create_startup_proc): Add asserts. (complete_proc): Do not assume the length of "<none>". * msg.c (S_proc_getmsgport): Call pid_find_allow_zombie after we know we were passed a valid caller. * pgrp.c: Include assert.h. (new_pgrp): Check return value of malloc and fail accordingly. (new_session): Likewise. (boot_setsid): Assert sess. (S_proc_getsessionpids): Use MAP_FAILED not -1. (S_proc_getsessionppids): Likewise. (S_proc_getpgrppids): Likewise. * wait.c (S_proc_wait): Use memset, not bzero.
* .Roland McGrath2000-03-171-0/+4
|
* 2000-03-17 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath2000-03-171-3/+1
| | | | * main.c (main): Use ports_get_send_right.
* .Roland McGrath2000-03-141-0/+7
|
* 2000-03-13 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath2000-03-141-3/+29
| | | | | | | | | * mgt.c (S_proc_exception_raise): Check for MACH_SEND_NOTIFY_IN_PROGRESS rather than MACH_SEND_INVALID_NOTIFY. Don't deallocate THREAD and TASK ports before the switch, since the successful case uses THREAD again and the failure case uses TASK again. Instead, deallocate them at the end of the successful case. At the end of the error case, use mach_port_destroy on THREAD only.
* .Roland McGrath2000-03-131-0/+13
|
* 2000-03-13 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath2000-03-131-88/+120
| | | | | | | | | | | | | * stubs.c (struct msg_sig_post_request): New type, broken out of send_signal, where it was anonymous. (struct msg_spec): Type removed. (blocking_message_send): Change type to any_t -> any_t. Don't call cthread_wire; it's a no-op in GNU anyway. Just return instead of calling cthread_exit. Argument is now a pointer to struct msg_sig_post_request. Check mach_msg return value for sanity assert. (send_signal): Make MESSAGE auto instead of static, use new type name. This problem tracked down by Mark Kettenis <kettenis@gnu.org>.
* .Roland McGrath2000-03-121-0/+9
|
* 2000-03-12 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath2000-03-123-10/+24
| | | | | | | | | * mgt.c (allocate_proc): Don't do mach_port_request_notification here. (proc_death_notify): New function, do it here instead. (complete_proc): Call proc_death_notify. * main.c (main): Call proc_death_notify on STARTUP_PROC after we have set its task port. * proc.h: Declare proc_death_notify.
* .Roland McGrath2000-01-241-0/+7
|
* 2000-01-23 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath2000-01-241-21/+22
| | | | | | | * info.c (get_string): New arg, pass back length of string. (get_string_array): Use it, rather than repeating strlen. When increasing NEWSIZE to fit, round it to page size. Diddle a few casts to be prettier.
* obsolete file removedRoland McGrath2000-01-072-135/+5
|
* 2000-01-06 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath2000-01-071-2/+1
| | | | | * primes.c: File removed (long obsolete). * proc.h: Don't declare nextprime.
* .Roland McGrath1999-07-111-0/+4
|
* 1999-07-11 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath1999-07-111-1/+2
| | | | * proc.h: Add #include <sys/mman.h>.
* 1999-07-09 Thomas Bushnell, BSG <tb@mit.edu>Thomas Bushnell1999-07-114-15/+28
| | | | | | | | | | * info.c (get_string_array): Use mmap instead of vm_allocate. (S_proc_getprocinfo): Likewise. (S_proc_getloginpids): Likewise. * mgt.c (S_proc_getallpids): Likewise. * pgrp.c (S_proc_getsessionpids): Likewise. (S_proc_getsessionpgids): Likewise. (S_proc_getpgrppids): Likewise.
* .Roland McGrath1999-07-111-0/+5
|
* 1999-07-10 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath1999-07-112-0/+2
| | | | | * info.c: Add #include <sys/mman.h> for munmap decl. * mgt.c: Likewise.
* 1999-07-03 Thomas Bushnell, BSG <tb@mit.edu>Thomas Bushnell1999-07-033-27/+26
| | | | | | | | | | * info.c (get_string): Use munmap instead of vm_deallocate. (get_vector): Likewise. (get_string_array): Likewise. (S_proc_getprocinfo): Likewise. * mgt.c (S_proc_reauthenticate): Likewise. (S_proc_dostop): Likewise. (add_tasks): Likewise.
* .Roland McGrath1999-06-191-0/+4
|
* 1999-06-19 Roland McGrath <roland@baalperazim.frob.com>Roland McGrath1999-06-191-4/+0
| | | | * main.c (main): Remove commented-out wire_task_self call, #include.
* .Roland McGrath1999-06-051-0/+5
|