The pthread_setintrtype callable service sets the specified interruptability type of the calling thread and atomically returns the previous interruptability type.
Operation | Environment |
---|---|
Authorization: | Supervisor state or problem state, any PSW key |
Dispatchable unit mode: | Task |
Cross memory mode: | PASN = HASN |
AMODE (BPX1PST): | 31-bit |
AMODE (BPX4PST): | 64-bit |
ASC mode: | Primary mode |
Interrupt status: | Enabled for interrupts |
Locks: | Unlocked |
Control parameters: | All parameters must be addressable by the caller and in the primary address space. |
|
AMODE 64 callers use BPX4PST with the same parameters.
Constant | Description |
---|---|
PTHREAD_INTR_ASYNCHRONOUS# | When interruptability is enabled and the interruptability type is set to PTHREAD_INTR_ASYNCHRONOUS#, cancelation requests can be acted upon at any time. |
PTHREAD_INTR_CONTROLLED# | When interruptability is enabled and the interruptability type is set to PTHREAD_INTR_CONTROLLED#, cancelation requests are held pending until a cancelation point is reached. See the usage notes for a definition of cancelation points. |
The name of a fullword to which the service returns the previous interrupt type, or -1 if the service did not complete.
Return code | Explanation |
---|---|
EINVAL | One of the parameters contains a value that is not valid. |
The name of a fullword in which the pthread_setintrtype service stores the reason code. The pthread_setintrtype service returns Reason_code only if Return_value is -1. Reason_code further qualifies the Return_code value. For the reason codes, see z/OS UNIX System Services Messages and Codes.
There are no restrictions on the use of the pthread_setintrtype service.
For an example using this callable service, see BPX1PST (pthread_setintrtype) example.