Rechercher une page de manuel
kstate
Langue: en
Version: 58963 (mandriva - 22/10/07)
Section: 2 (Appels système)
NAME
kstate - Get synchronization status of a LAM process.SYNOPSIS
#include <kreq.h>int kstate (int pid, struct kstatus *status);
DESCRIPTION
The function kstate() enables a LAM process to inquire about the synchronization status of any process on the local node, including itself. The argument pid is the identifier of the process to be stated. The special identifier 0 indicates the calling process. Information returned from the daemon will be stored in the structure addressed by the status argument. The structure is defined in <kreq.h> as shown below.struct kstatus { int ks_state; int ks_priority; int ks_event; int ks_type; int ks_signal; int ks_flags; int ks_length; int ks_fyi[KNFYI]; };
Upon return from kstate(), the individual fields are filled with the information described below.
- ks_state
- scheduling status (see below)
- ks_priority
- synchronization priority (see kenter(2))
- ks_event
- currently blocked or last used message event
- ks_type
- currently blocked or last used message type
- ks_signal
- pending signals to be delivered
- ks_flags
- internal process management flags
- ks_length
- currently blocked or last used message length
- ks_fyi
- application specific information
The process states, defined in <kreq.h>, are described below.
- KSREADY
- ready to run
- KSRECV
- blocked on krecv(2) to receive a message
- KSSEND
- blocked on ksend(2) to send a message
ERRORS
- ENOTPROCESS
- The process whose process identifier was passed to kstate() is not a LAM process.
- ENOTATTACHED
- The calling process is not a LAM process.
SEE ALSO
rpstate(2)Contenus ©2006-2024 Benjamin Poulain
Design ©2006-2024 Maxime Vantorre