STREAMS/UX for the HP 9000 Reference Manual

47
Differences Between STREAMS/UX and System V Release 4 STREAMS
HP-UX Modifications to STREAMS/UX Utilities
MP SV_WAIT has a priority argument that specifies the priority the caller
would like to run at after waking. Since the HP-UX SV_WAIT is
implemented by calling sleep, the HP-UX priorities are different than the
SVR4 MP ones. On HP-UX, the priority passed into SV_WAIT is
subtracted from PZERO-1. pridisk, prinet, pritty, pritape, prihi, primed, and
prilo are defined to be 0, and do not affect the caller's priority. If you need to
change the process's priority, study the priorities in /usr/include/sys/param.h
or /usr/conf/h/param.h, and pass the needed offset to PZERO-1 in the
priority parameter.
SV_WAIT_SIG
STREAMS/UX implements a subset of the SVR4 MP synchronization
variable utilities using sleep and wakeup. The HP-UX SV_WAIT_SIG
differs from the SVR4 MP utility in the following ways. When the SVR4
MP SV_WAIT_SIG returns, the lkp spinlock is not held, and the priority
level is set to plbase (SPLNOPREEMPT on HP-UX). On a multiprocessor
system, the HP-UX SV_WAIT_SIG lowers the priority level to the value
before the caller acquired the lkp spinlock, which may not be
SPLNOPREEMPT. If the caller acquired the lock while holding other
spinlocks, the priority level is lowered to the value before the first of these
nested spinlock calls. Also, the SVR4 MP SV_WAIT_SIG has a priority
argument that specifies the priority the caller would like to run at after
waking. Since the HP-UX SV_WAIT_SIG is implemented by calling sleep,
the HP-UX priorities are different than the SVR4 MP ones. On HP-UX, the
priority passed into SV_WAIT_SIG is added to PZERO+1|PCATCH.
pridisk, prinet, pritty, pritape, prihi, primed, and prilo are defined to be 0,
and do not affect the caller's priority. If you need to change the process's
priority, study the priorities in /usr/include/sys/param.h or
/usr/conf/h/param.h, and pass the needed offset to PZERO+1|PCATCH in
the priority parameter. The last difference is that the SVR4 MP
SV_WAIT_SIG returns if the process is first stopped by a job control signal
and then continued. The HP-UX SV_WAIT_SIG continues to sleep until it
receives a signal which does not stop the process, or an SV_BROADCAST
wakes up the process.