NAME | SYNOPSIS | DESCRIPTION | RETURN VALUES | ERRORS | ATTRIBUTES | SEE ALSO
cc - mt [ flag... ] file...- lpthread [ library... ] #include <pthread.h>int pthread_mutexattr_setprioceiling(pthread_mutexattr_t *attr, int prioceiling int *oldceiling);
The pthread_mutexattr_getprioceiling() and pthread_mutexattr_setprioceiling() functions, respectively, get and set the priority ceiling attribute of a mutex attribute object pointed to by attr which was previously created by the function pthread_mutexattr_init().
The prioceiling attribute contains the priority ceiling of initialized mutexes. The values of prioceiling will be within the maximum range of priorities defined by SCHED_FIFO.
The prioceiling attribute defines the priority ceiling of initialized mutexes, which is the minimum priority level at which the critical section guarded by the mutex is executed. In order to avoid priority inversion, the priority ceiling of the mutex will be set to a priority higher than or equal to the highest priority of all the threads that may lock that mutex. The values of prioceiling will be within the maximum range of priorities defined under the SCHED_FIFO scheduling policy.
These functions are not currently supported and will always return ENOSYS.
Upon successful completion, the pthread_mutexattr_getprioceiling() and pthread_mutexattr_setprioceiling() functions return 0. Otherwise, an error number is returned to indicate the error.
These functions are not currently supported and will always return ENOSYS.
The pthread_mutexattr_getprioceiling() and pthread_mutexattr_setprioceiling() functions will fail if:
The option _POSIX_THREAD_PRIO_PROTECT is not defined and the implementation does not support the function.
The pthread_mutexattr_getprioceiling() and pthread_mutexattr_setprioceiling() functions may fail if:
The value specified by attr or prioceiling is invalid.
The caller does not have the privilege to perform the operation.
See attributes(5) for descriptions of the following attributes:
ATTRIBUTE TYPE | ATTRIBUTE VALUE |
---|---|
MT-Level | MT-Safe |
NAME | SYNOPSIS | DESCRIPTION | RETURN VALUES | ERRORS | ATTRIBUTES | SEE ALSO