HP-UX Reference (11i v1 00/12) - 2 System Calls (vol 5)
__________________________________________________________________________________________________________________________________________________________________________________________________
__________________________________________________________________________________________________________________________________________________________________________________________________
STANDARD Printed by: Nora Chuang [nchuang] STANDARD
/build/1111/BRICK/man2/!!!intro.2
________________________________________________________________
___ ___
r
rtsched(2) rtsched(2)
[ENOSYS] The function is not supported by this implementation.
[EPERM] The requesting process does not have permission to set the scheduling policy of the
specified process.
[ESRCH] No process can be found corresponding to that specified by pid.
sched_getscheduler()
[ENOSYS] The function is not supported by this implementation.
[ESRCH] No process can be found corresponding to that specified by pid.
sched_yield()
[ENOSYS] The function is not supported by this implementation.
sched_get_priority_max()
sched_get_priority_min()
[EINVAL] The value of the policy parameter does not represent a defined scheduling policy.
[ENOSYS] The function is not supported by this implementation.
sched_rr_get_interval()
[ENOSYS] The function is not supported by this implementation.
[ESRCH] No process can be found corresponding to that specified by pid.
EXAMPLES
Change the calling process to use the strongest
FIFO priority:
#include <sched.h>
struct sched_param param;
int maxpri;
maxpri = sched_get_priority_max(SCHED_FIFO);
if (maxpri == -1) {
perror("sched_get_priority_max() failed");
exit(1);
}
param.sched_priority = maxpri;
if (sched_setscheduler(getpid(), SCHED_FIFO, ¶m) == -1) {
perror("sched_setscheduler() failed");
exit(1);
}
AUTHOR
The sched_*() functions were derived from the proposed IEEE POSIX P1003.4 standard, draft 14.
PRI_HPUX_TO_POSIX() and PRI_POSIX_TO_HPUX() were developed by HP.
SEE ALSO
rtsched(1), rtprio(2).
STANDARDS CONFORMANCE
sched_get_priority_max()
:POSIX.4
sched_get_priority_min():POSIX.4
sched_getparam():POSIX.4
sched_getscheduler():POSIX.4
sched_rr_getinterval():POSIX.4
sched_setparam():POSIX.4
sched_setscheduler():POSIX.4
sched_yield():POSIX.4
HP-UX Release 11i: December 2000 − 7 − Section 2−−271
___
___