OpenSS7
SS7 for the
Common Man
© Copyright 1997-2007 OpenSS7 Corporation All Rights Reserved.
Last modified: Sat, 01 Nov 2008 10:41:56 GMT
Home TopIndex FirstPrev Next LastMore Download Info FAQ Mail  Home -> Documentation -> Man Pages -> Manual Page
Quick Links

Download

SCTP

SIGTRAN

SS7

Hardware

STREAMS

Asterisk

Related

Package

Manual

FAQ

Man Pages

Applications

SS7 Stack

ISDN Stack

SIGTRAN Stack

VoIP Stack

MG Stack

SS7/ISDN Devices

IP Transport

Embedded Systems

OS

Documentation

FAQ

SIGTRAN

Design

Conformance

Performance

References

Man Pages

Manuals

Papers

Home

Overview

Status

Documentation

Resources

About

News

Description: Manual Page

Keywords: ss7 ss7/ip ss7 over ip ss7 mtp ss7 sccp ss7 tcap sigtran mtp sccp tcap openss7 acb56 linux telephony pstn linux telephony linux nebs linux compactpci


QPROCSOFF

Section: Linux Fast-STREAMS DDI/DKI (9)
Updated: 2008-10-31
Index Return to Main Contents

NAME

qprocsoff - disables STREAMS message queue processing for multi-processing

SYNOPSIS

#include <sys/stream.h>
#include <sys/ddi.h>

void qprocsoff(queue_t *qp);

ARGUMENTS

qp

the read queue pointer of the queue pair for which to turn queue procedures off.

INTERFACE

STREAMS.

DESCRIPTION

qprocsoff() disables invocation of qi_putp(9) and qi_srvp(9) procedures for the queue pair whose read queue pointer is pointed to by qp.

If there are existing threads other than the calling thread executing qi_putp(9) or qi_srvp(9) procedures for either queue in the the queue pair, qp, then qprocsoff() will block until these threads exit before returning. Once qprocsoff() returns, it is guaranteed that a STREAMS driver or module queue pair is single threaded after qprocsoff() returns and before qprocson(9) is called.

RETURN

qprocsoff() returns void.

ERRORS

qprocsoff() is always successful.

CONTEXT

qprocsoff() can be called from any context including user context, queue procedures, call-outs, callbacks, soft interrupts (tasklets and bottom halves), and interrupt service routines; however, it is only intended to be called by a module qi_qclose(9) procedure. qprocsoff() must be called by the qi_qclose(9) procedure (i.e. in user context) before returning.

MP-STREAMS

qprocsoff() is MP-safe. Upon return from qprocsoff() the the queue pair is guaranteed to be single threaded. qprocsoff() should not be called twice for the same queue pair from the same thread.

qprocsoff() must be called before removing or invalidating module private state information attached to the q_ptr for either queue in the queue pair as part of the qi_qclose(9) procedure for the driver or module, regardless of whether the underlying architecture is UP or MP.

NOTICES

qprocsoff() must be called with a valid read queue pointer for a queue pair. qprocsoff() must not be called on a stream that is frozen with freezestr(9), or single-party deadlock will result.

Before a call to qprocsoff() a driver or module is fully attached on a stream. qprocsoff() bypasses the module so that any upstream or downstream module calling putnext(9) will bypass the module. Pending qi_putp(9) events on the queue pair will be run before qprocsoff() returns. Pending qi_srvp(9) events will be cancelled. All pending synchronous call-out and callback events for the queue pair will be blocked. All pending asynchronous call-outs and callbacks for the queue pair (e.g., timeout(9), bufcall(9)) will not be blocked. It is still the caller's responsibility to cancel all pending call-outs and callbacks for which a call id was returned.

qprocsoff() can be called twice on the same queue pair without consequence.

After a call to qprocsoff() the caller must not directly or indirectly invoke any queue entry points. This includes all queue utility functions and other STREAMS utility functions that take qp or WR(qp) as an argument.

See also ``COMPATIBILITY'', below.

SEE ALSO

freezestr(9), qprocson(9), qunbufcall(9), quntimeout(9), liscompat(9).

BUGS

qprocsoff() has no known bugs.

COMPATIBILITY

qprocsoff() is compatible with SVR 4.2 MP DDI/DKI[1], and systems based on SVR 4, with the following portability considerations:

---
qprocson() can be called with private queue pairs allocated with allocq(9). This is a non-portable Linux Fast-STREAMS[2] extension.
Portable STREAMS drivers and modules will not allocate private queue pairs.
---
qprocsoff() sets the QPROCS flag in the queue(9) structure for both queues in the queue pair. qprocsoff() can be called repeatedly for the same queue pair and only the first call will have an effect. This can crash or lock processors on other systems (with the exception of HP-UX®[3] as noted below.)
Portable STREAMS drivers and modules will not call qprocsoff() repeatedly for the same queue without first calling qprocson(9).
---
qprocsoff() is not bug for bug compatible with LiS.
qprocsoff() waits for all other threads to exit qi_qopen(9), qi_qclose(9), qi_putp(9) and qi_srvp(9) procedures before returning. This is consistent with SVR 4.2 MP DDI/DKI and documentation for Solaris® but inconsistent with LiS[1,4,5]. Under LiS, qprocsoff() does not wait for qi_qopen(9), qi_qclose(9), qi_putp(9) or qi_srvp(9) procedures on other threads to exit before returning, but simply sets a flag.
Portable STREAMS drivers and modules will use Linux Fast-STREAMS[2] in place of LiS.
---
The driver or module can neglect to call qprocsoff() before returning from the module's qi_qclose(9) procedure and the STREAMS scheduler will perform an implicit qprocsoff(). This is consistent with LiS behavior but different from SVR 4.2 MP DDI/DKI, UnixWare®, OSF/1®, and Solaris®. Because SVR 4.2 MP DDI/DKI, UnixWare®, OSF/1®, and Solaris® should never return from qi_qclose(9) without calling qprocsoff(), there should be no compatibility issues.
Portable STREAMS drivers and modules will call qprocsoff() before returning from the qi_qclose(9) procedure (invoked on the last close of a stream).
---
AIX® OSF/1® and UXP/V® do not document a qprocson(9) or qprocsoff() function[6..8]. On HP-UX®, qprocson(9) and qprocsoff() are a null operations[3].
Portable STREAMS drivers and modules will call qprocsoff() before the last close return from a qi_qclose(9) procedure.
---
qprocsoff() can be called twice without danger. This is not true for SVR 4.2 MP DDI/DKI or Solaris® but is consistent with HP-UX® and LiS[1,3..5].
Portable STREAMS drivers and modules will not call qprocsoff() repeatedly for the same queue without first calling qprocson(9).
---
qprocsoff() is not bug for bug compatible with LiS.
qprocsoff() blocks other threads attempting to enter the qi_putp(9) procedure until it returns. Under LiS, attempts to enter the qi_putp(9) procedure will result in the message being dropped or freed. See qi_putp(9) for more information.
Portable STREAMS drivers and modules will use Linux Fast-STREAMS[2] in place of LiS.
---
qprocsoff() may be called on a stream frozen with freezestr(9). SVR 4.2 MP DDI/DKI, Solaris®, SUPER-UX® and UnixWare® do not permit qprocsoff() to be called on a stream frozen with freezestr(9)[1,9..11].
Portable STREAMS drivers and modules will not call qprocsoff() on a stream frozen with freezestr(9).
---
Binary compatibility is not guaranteed.

See STREAMS(9) for additional compatibility information.

CONFORMANCE

SVR 4.2 MP DDI/DKI[1,12].

HISTORY

qprocsoff() first appeared in SVR 4.0 MP and SVR 4.2 MP[1,13].

REFERENCES

[1]
USL DDI/DKI, Device Driver Interface/Driver-Kernel Interface (DDI/DKI) Reference Manual for Intel Processors, 1992, (Englewood Cliffs, New Jersey), AT&T UNIX System Laboratories, Inc., Prentice Hall.
[2]
streams-0.9.2, Linux Fast-STREAMS (LfS) 0.9.2 Source Code, Brian Bidulock, ed., OpenSS7 Corporation. <http://www.openss7.org/>
[3]
HP-UX STREAMS, STREAMS Programmer's Guide -- HP 9000 and Integrity Server Computer Systems, October 2005, (Palo Alto, California), Hewlett-Packard Development Company L.P., HP. <http://docs.hp.com/>
[4]
Solaris® 8, Solaris 8 Docmentation, 2001, (Santa Clara, California), Sun Microsystems, Inc., Sun. <http://docs.sun.com/>
[5]
LIS 2.18, Linux STREAMS (LiS) 2.18.6 Source Code, Brian Bidulock, ed., OpenSS7 Corporation. <http://www.openss7.org/>
[6]
AIX® 5L Version 5.1, AIX 5L Version 5.1 Documentation, 2001, (Boulder, Colorado), Internatonal Business Machines Corp., IBM. <http://publibn.boulder.ibm.com/>
[7]
Digital® UNIX (OSF/1.2), Digital UNIX Documentation Library, 2003, (Palo Alto, California), Digital Equipment Corporation, Hewlett-Packard Company. <http://www.true64unix.compaq.com/docs/>
[8]
UXP/V® V10L10, UXP/V V10L10 Documentation, 1997, Fujitsu Limited, Fujitsu.
[9]
Solaris® 8, STREAMS Programming Guide, August 1999, (Palo Alto, California), Sun Microsystems, Inc., Sun. [Part No: 805-7478-05] <http://docs-pdf.sun.com/>
[10]
SUPER-UX® Release 9.2, SUPER-UX STREAMS Programmers Guide, 1999, NEC Corporation, NEC.
[11]
UnixWare® 7.1.3, UnixWare® 7 STREAMS Programmer's Guide, 2002, (Lindon, Utah), Caldera International, Inc., Caldera. <http://uw713doc.sco.com/>
[12]
SVR 4.2, STREAMS Programmer's Guide, 1992, (Englewood Cliffs, New Jersey), AT&T UNIX System Laboratories, Inc., Prentice Hall.
[13]
SVR 4 DDI/DKI, UNIX® System V Release 4 Device Driver Interface/Driver-Kernel Interface (DDI/DKI) Reference Manual, 1990, (Englewood Cliffs, New Jersey), AT&T UNIX System Laboratories, Inc., Prentice Hall.

TRADEMARKS

OpenSS7tm
is a trademark of OpenSS7 Corporation.
Linux®
is a registered trademark of Linus Torvalds.
UNIX®
is a registered trademark of The Open Group.
Solaris®
is a registered trademark of Sun Microsystems.

Other trademarks are the property of their respective owners.

IDENTIFICATION


Linux Fast-STREAMS: Package streams version 0.9.2.4 released 2008-10-31.

Copyright©1997-2008OpenSS7 Corp. All Rights Reserved.
(See roff source for permission notice.)



Index

NAME
SYNOPSIS
ARGUMENTS
INTERFACE
DESCRIPTION
RETURN
ERRORS
CONTEXT
MP-STREAMS
NOTICES
SEE ALSO
BUGS
COMPATIBILITY
CONFORMANCE
HISTORY
REFERENCES
TRADEMARKS
IDENTIFICATION

This document was created by man2html, using the manual pages.
Time: 22:50:15 GMT, May 23, 2013
OpenSS7
SS7 for the
Common Man
Home TopIndex FirstPrev Next LastMore Download Info FAQ Mail  Home -> Documentation -> Man Pages -> Manual Page
Last modified: Sat, 01 Nov 2008 10:41:56 GMT
© Copyright 1997-2007 OpenSS7 Corporation All Rights Reserved.