Sets and gets the I/O priority of a specified pthread.
Threads Library (libpthreads.a)
The pthread_getiopri_np subroutine stores the I/O scheduling priority of the pthread into the pri argument. The pthread_setiopri_np subroutine sets the I/O scheduling priority to the pri argument of the specified pthread.
AIX® provides the ability to prioritize I/O buffers on a per-I/O and per-process basis. With the pthread_getiopri_np subroutine and the pthread_setiopri_np subroutine, AIX provides the ability to prioritize I/O buffers on a per-thread basis.
Item | Description |
---|---|
pthread | Specifies the target thread. |
pri | I/O priority field used to set or store the current I/O priority of the pthread. |
Upon successful completion, the pthread_getiopri_np subroutine or the pthread_setiopri_np subroutine returns zero. A non-zero value indicates an error.
If any of the following conditions occur, the pthread_getiopri_np subroutine and the pthread_setiopri_np subroutine fail and return the corresponding value:
Item | Description |
---|---|
ESRCH | The provided pthread is not valid. |
ENOTSUP | This function was called in a Process Scope (M:N) environment. |
EPERM | The caller does not have the valid Role Based Access Control (RBAC) permissions (the ACT_P_GETPRI permission for the pthread_getiopri_np subroutine, the ACT_P_SETPRI permission for the pthread_setiopri_np subroutine). |
EINVAL | The specified I/O priority is not valid. |