| LiS ManualDescription: OpenSS7 Online ManualsA PDF version of this document is available here. Linux STREAMS (LiS)Linux STREAMS (LiS) Installation and Reference ManualAbout This ManualThis is Edition 6, last updated 2007-06-24, of The Linux STREAMS (LiS) Installation and Reference Manual, for Version 2.18 release 6 of the Linux STREAMS (LiS) package. PrefaceNoticeThis package is released and distributed under the GPL (see GNU General Public License). Please note, however, that there are different licensing terms for the manual pages and some of the documentation (derived from OpenGroup1 publications and other sources). Consult the permission notices contained in the documentation for more information. This manual is released under the FDL (see GNU Free Documentation License) with all sections invariant. AbstractThis manual provides a Installation and Reference Manual for Linux STREAMS (LiS). ObjectiveThe objective of this manual is to provide a guide for the STREAMS programmer when developing STREAMS modules, drivers and application programs for Linux STREAMS (LiS). This guide provides information to developers on the use of the STREAMS mechanism at user and kernel levels. STREAMS was incorporated in UNIX System V Release 3 to augment the character input/output (I/O) mechanism and to support development of communication services. STREAMS provides developers with integral functions, a set of utility routines, and facilities that expedite software design and implementation. Intent
The intent of this manual is to act as an introductory guide to the STREAMS programmer. It
is intended to be read alone and is not intended to replace or supplement the
Linux STREAMS (LiS) manual pages. For a reference for writing code, the manual pages
(see AudienceThis manual is intended for a highly technical audience. The reader should already be familiar with Linux kernel programming, the Linux file system, character devices, driver input and output, interrupts, software interrupt handling, scheduling, process contexts, multiprocessor locks, etc. The guide is intended for network and systems programmers, who use the STREAMS mechanism at user and kernel levels for Linux and UNIX system communication services. Readers of the guide are expected to possess prior knowledge of the Linux and UNIX system, programming, networking, and data communication. RevisionsTake care that you are working with a current version of this manual: you will not be notified of updates. To ensure that you are working with a current version, contact the Author, or check The OpenSS7 Project website for a current version. A current version of this manual is normally distributed with the Linux STREAMS (LiS) package. Version ControlLiS.texi,v Revision 1.1.6.23 2007/02/28 06:30:12 brian - updates and corrections, #ifdef instead of #if Revision 1.1.6.22 2006/09/18 01:06:12 brian - updated manuals and release texi docs Revision 1.1.6.21 2006/08/28 10:46:49 brian - correction Revision 1.1.6.20 2006/08/28 10:32:41 brian - updated references Revision 1.1.6.19 2006/08/27 12:26:26 brian - finalizing auto release files Revision 1.1.6.18 2006/08/26 18:31:29 brian - handle long urls Revision 1.1.6.17 2006/08/26 09:15:54 brian - better release file generation Revision 1.1.6.16 2006/08/23 11:00:19 brian - added preface, corrections and updates for release Revision 1.1.6.14 2006-07-02 06:13:45 -0600 brian - release documentation updates Revision 1.1.6.13 2006-03-22 03:01:55 -0700 brian - added makefile target index Revision 1.1.6.12 2005-09-15 06:59:33 -0600 brian - testsuite documentation update Revision 1.1.6.11 2005-06-24 07:38:56 -0600 brian - added troubleshooting section to manuals Revision 1.1.6.10 2005-06-23 21:35:15 -0600 brian - minor updates to documentation Revision 1.1.6.9 2005-05-14 02:35:10 -0600 brian - copyright header correction Revision 1.1.6.8 2005-04-12 03:28:52 -0600 brian - corrections Revision 1.1.6.7 2005-04-11 14:48:39 -0600 brian - documentation updates and corrections Revision 1.1.6.6 2005-04-04 22:30:00 -0600 brian - correct include path Revision 1.1.6.5 2005-03-15 05:06:37 -0700 brian - Updated texinfo documentation. Revision 1.1.6.4 2005-03-14 17:56:39 -0700 brian - Updated version numbering in texinfo files. Revision 1.1.6.3 2005-03-14 17:51:29 -0700 brian - Updated version numbering in texinfo files. Revision 1.1.6.2 2005-03-13 18:25:36 -0700 brian - manual updates for LiS-2.18 Revision 1.1.6.1 2005-03-09 16:14:15 -0700 brian - First stab at autoconf'ed 2.18.0. Results of merge. Revision 1.1.4.17 2005-02-17 13:00:03 -0700 brian - Fixes for texi documentation. Revision 1.1.4.16 2005-01-24 04:57:52 -0700 brian - Updated texinfo headers. Revision 1.1.4.15 2004-12-19 08:14:19 -0700 brian - Corrected include position. Revision 1.1.4.14 2004-12-16 21:02:34 -0700 brian - Improving spec files. Revision 1.1.4.13 2004-11-09 04:49:12 -0700 brian - Manual updates Revision 1.1.4.12 2004-11-06 02:14:24 -0700 brian - Use automatic node features. Revision 1.1.4.11 2004-10-11 20:26:26 -0600 brian - Added texinfo configuration file. Revision 1.1.4.10 2004-08-21 23:07:16 -0600 brian - Converted to common file operation. Revision 1.1.4.9 2004-08-20 15:15:51 -0600 brian - Documentation updates. Revision 1.1.4.8 2004-08-15 14:01:51 -0600 brian - Build system updates. Revision 1.1.4.7 2004-08-04 13:18:00 -0600 brian - Removed references to drivers and modules moved to strxns and strxnet. Revision 1.1.4.6 2004-08-04 11:24:52 -0600 brian - Typographical errors corrected. Revision 1.1.4.5 2004-05-25 23:25:55 -0600 brian - html target more sensitive to syntax Revision 1.1.4.4 2004-05-25 18:11:10 -0600 brian - Updated manual with NexusWare instructions. Revision 1.1.4.3 2004-05-25 14:03:06 -0600 brian - Updating release notes and documentation. Revision 1.1.4.2 2004-05-13 03:06:35 -0600 brian - made tli modules, inet driver and xnet library optional - added HTML output to texinfo build - passes distcheck Revision 1.1.4.1 2004-01-12 16:45:36 -0700 brian - Updated missing directories. Revision 1.1.2.5 2004-01-07 04:34:48 -0700 brian - Updated copyright dates. Revision 1.1.2.4 2003-12-22 21:07:31 -0700 brian - Updates to manuals. Revision 1.1.2.3 2003-12-16 17:23:42 -0700 brian - Added XTI/TLI package into release. Revision 1.1.2.2 2003-12-16 05:21:04 -0700 brian - Added license files and extra distributions. Revision 1.1.2.1 2003-12-15 16:38:03 -0700 brian - New info documentation. Revision 1.1 2003-12-15 16:38:03 -0700 brian file LiS.texi was initially added on branch LIS-2-16-16-autoconf. ISO 9000 ComplianceOnly the TeX, texinfo, or roff source for this manual is controlled. An opaque (printed, postscript or portable document format) version of this manual is an UNCONTROLLED VERSION. DisclaimerOpenSS7 Corporation disclaims all warranties with regard to this documentation including all implied warranties of merchantability, fitness for a particular purpose, non-infringement, or title; that the contents of the manual are suitable for any purpose, or that the implementation of such contents will not infringe on any third party patents, copyrights, trademarks or other rights. In no event shall OpenSS7 Corporation be liable for any direct, indirect, special or consequential damages or any damages whatsoever resulting from loss of use, data or profits, whether in an action of contract, negligence or other tortious action, arising out of or in connection with any use of this manual or the performance or implementation of the contents thereof. OpenSS7 Corporation reserves the right to revise this software and documentation for any reason, including but not limited to, conformity with standards promulgated by various agencies, utilization of advances in the state of the technical arts, or the reflection of changes in the design of any techniques, or procedures embodied, described, or referred to herein. OpenSS7 Corporation is under no obligation to provide any feature listed herein. U.S. Government Restricted RightsIf you are licensing this Software on behalf of the U.S. Government ("Government"), the following provisions apply to you. If the Software is supplied by the Department of Defense ("DoD"), it is classified as "Commercial Computer Software" under paragraph 252.227-7014 of the DoD Supplement to the Federal Acquisition Regulations ("DFARS") (or any successor regulations) and the Government is acquiring only the license rights granted herein (the license rights customarily provided to non-Government users). If the Software is supplied to any unit or agency of the Government other than DoD, it is classified as "Restricted Computer Software" and the Government's rights in the Software are defined in paragraph 52.227-19 of the Federal Acquisition Regulations ("FAR") (or any successor regulations) or, in the cases of NASA, in paragraph 18.52.227-86 of the NASA Supplement to the FAR (or any successor regulations). AcknowledgementsAs with most open source projects, this project would not have been possible without the valiant efforts and productive software of the Free Software Foundation and the Linux Kernel Community. SponsorsFunding for completion of the OpenSS7 Linux STREAMS (LiS) package was provided in part by:
Additional funding for The OpenSS7 Project was provided by: ContributorsThe current maintainer of the OpenSS7 Linux STREAMS (LiS) package is Brian F. G. Bidulock. Linux STREAMS (LiS) was originally written by: Packaging was performed by:
Packaging would not be what it is today without the invaluable help of these people:
The primary contributor to The OpenSS7 Project is Brian F. G. Bidulock. The following is a list of significant contributors to The OpenSS7 Project:
Additional people not named here that I missed putting on the list. We thank them too! AuthorsLinux STREAMS, termed LiS, is an SVR4 compatible STREAMS executive which runs in the Linux Kernel as a loadable module. It is the product of a joint effort among the following authors:
The authors of the OpenSS7 Linux STREAMS (LiS) package include:
See Author Index, for a complete listing and cross-index of authors to sections of this manual. MaintainerBrian Bidulock is the principal active maintainer of LiS, so please direct questions to him rather than the others.2 Ole Husgaard has contributed to the kerneld support and installation procedures. Jürgen Magin contributed patches for Linux SPARC. G Yeganjaiah added interrupt routine support. John Boyd implemented fattach and STREAMS pipes and FIFOs. Brian Bidulock developed a complete set of manual pages for LiS, converted the build process to autoconf, wrapped the source RPMS, updated this manual for texinfo and currently maintains the package. The maintainer of the OpenSS7 Linux STREAMS (LiS) package is:
Please send bug reports to bugs@openss7.org using the send-pr script included in the package, only after reading the BUGS file in the release, or See Problem Reports. Web ResourcesThe OpenSS7 Project provides a website dedicated to the software packages released by the OpenSS7 Project. Bug ReportsPlease send bug reports to bugs@openss7.org using the send-pr script included in the Linux STREAMS (LiS) package, only after reading the BUGS file in the release, or See Problem Reports. You can access the OpenSS7 GNATS database directly via the web, however, the preferred method for sending new bug reports is via mail with the send-pr script. Mailing ListsThe OpenSS7 Project provides a number of general discussion Mailing Lists for discussion concerning the OpenSS7 Linux STREAMS (LiS) package as well as other packages released by The OpenSS7 Project. These are mailman mailing lists and so have convenient web interfaces for subscribers to control their settings. See http://www.openss7.org/mailinglist.html. The mailing lists are as follows:
SpamTo avoid spam being sent to the members of the OpenSS7 mailing list(s), we have blocked mail from non-subscribers. Please subscribe to the mailing list before attempting to post to them. (Attempts to post when not subscribed get bounced.) As an additional measure against spam, subscriber lists for all OpenSS7 mailing lists are not accessible to non-subscribers; for most lists subscriber lists are only accessible to the list administrator. This keeps your mailing address from being picked off our website by bulk mailers. Acceptable Use PolicyIt is acceptable to post professional and courteous messages regarding the OpenSS7 package or any general information or questions concerning STREAMS, SS7, SIGTRAN, SCTP or telecommunications applications in general. Large AttachmentsThe mailing list is blocked from messages of greater than Quick Start GuideLinux STREAMS (LiS)Package LiS-2.18.6 was released under GPLv2 2007-06-24. The OpenSS7 Linux STREAMS (LiS) package is an OpenSS7 modified version of the LiS-2.18 package formerly from GCOM, and formerly maintained by David Grothe. Note: The original LiS package from GCOM is no longer actively maintained by either GCOM or the OpenSS7 Project: use the OpenSS7 Linux Fast-STREAMS package <http://www.openss7.org/STREAMS.html> instead. The following are claims made by its authors and original maintainer: The OpenSS7 Modified Linux STREAMS (LiS) package is as STREAMS framework that is compatible with SVR 4 STREAMS. It has lots of debugging features not found in other STREAMS packages. Good to do networking and other things. It allows for installation of binary drivers. Linux STREAMS (LiS) aims to provide SVR 4 compatible STREAMS implementation for Linux and claims to have special debugging facilities; however, the package suffers from the major failings that it is:
This distribution is only currently applicable to Linux 2.4 and 2.6 kernels and was targeted
at ReleaseThis is the LiS-2.18.6 package, released 2007-06-24. This `2.18.6' release, and the latest version, can be obtained from the download area of The OpenSS7 Project website using a command such as: $> wget http://www.openss7.org/tarballs/LiS-2.18.6.tar.bz2 The release is available as an autoconf(1) tarball, src.rpm or dsc, or as a set of binary rpms or debs. See the download page for the autoconf(1) tarballs, src.rpms or dscs. See the LiS package page for tarballs, source and binary packages. Please see the NEWS file for release notes and history of user visible changes for the current version, and the ChangeLog file for a more detailed history of implementation changes. The TODO file lists features not yet implemented and other outstanding items. Please see the INSTALL, INSTALL-LiS and README-make, files (or see Installation) for installation instructions. When working from cvs(1) or git(1), please see the README-cvs, file (or see Downloading from CVS). An abbreviated installation procedure that works for most applications appears below. This release of the package is published strictly under Version 2 of the GNU Public License which can be found in the file COPYING. Package specific licensing terms (if any) can be found in the file LICENSES. Please respect these licensing arrangements. If you are interested in different licensing terms, please contact the copyright holder, or OpenSS7 Corporation <sales@openss7.com>. See README-alpha (if it exists) for alpha release information. PrerequisitesThe quickest and easiest way to ensure that all prerequisites are met is to download and install this package from within the OpenSS7 Master Package, openss7-0.9.2.F, instead of separately. Prerequisites for the Linux STREAMS (LiS) package are as follows:
When configuring and building multiple OpenSS7 Project release packages, place all of the source packages (unpacked tarballs) at the same directory level and all build directories at the same directory level (e.g. all source packages under /usr/src). When installing packages that install as kernel modules, it is necessary to have the correct kernel development package installed. For the following distributions, use the following commands: Ubuntu: $> apt-get install linux-headers Debian: $> apt-get install kernel-headers Fedora: $> yum install kernel-devel You also need the same version of gcc(1) compiler with which the kernel was built. If it is not the default, add `CC=kgcc' on the line after `./configure', for example: $> ../LiS-2.18.6/configure CC='gcc-3.4' InstallationThe following commands will download, configure, build, check, install, validate, uninstall and remove the package: $> wget http://www.openss7.org/tarballs/LiS-2.18.6.tar.bz2 $> tar -xjvf LiS-2.18.6.tar.bz2 $> mkdir build $> pushd build $> ../LiS-2.18.6/configure --enable-autotest $> make $> make check $> sudo make install $> sudo make installcheck $> sudo make uninstall $> popd $> sudo rm -rf build $> rm -rf LiS-2.18.6 $> rm -f LiS-2.18.6.tar.bz2 If you have problems, try building with the logging targets instead. If the make of a logging target fails, an automatic problem report will be generated that can be mailed to The OpenSS7 Project.5 Installation steps using the logging targets proceed as follows: $> wget http://www.openss7.org/tarballs/LiS-2.18.6.tar.bz2 $> tar -xjvf LiS-2.18.6.tar.bz2 $> mkdir build $> pushd build $> ../LiS-2.18.6/configure --enable-autotest $> make compile.log $> make check.log $> sudo make install.log $> sudo make installcheck.log $> sudo make uninstall.log $> popd $> sudo rm -rf build $> rm -rf LiS-2.18.6 $> rm -f LiS-2.18.6.tar.bz2 See README-make for additional specialized make targets. For custom applications, see the INSTALL and INSTALL-LiS files or the see Installation, as listed below. If you encounter troubles, see Troubleshooting, before issuing a bug report. Brief Installation InstructionsThe Linux STREAMS (LiS) package is available from the downloads area of The OpenSS7 Project website using a command such as: $> wget http://www.openss7.org/tarballs/LiS-2.18.6.tar.bz2 Unpack the tarball using a command such as: $> tar -xjvf LiS-2.18.6.tar.bz2 The tarball will unpack into the relative subdirectory named after the package name: LiS-2.18.6. The package builds using the GNU autoconf utilities and the configure script. To build the package, we recommend using a separate build directory as follows: $> mkdir build $> cd build $> ../LiS-2.18.6/configure In general, the package configures and builds without adding any special options to the configure script. For general options to the configure script, see the GNU INSTALL file in the distribution: $> less ../LiS-2.18.6/INSTALL For specific options to the configure script, see the INSTALL-LiS file in the distribution, or simply execute the configure script with the --help option like so: $> ../LiS-2.18.6/configure --help After configuring the package, the package can be compiled simply by issuing the `make' command: $> make Some specialized makefile targets exists, see the README-make file in the distribution or simply invoke the `help' target like so: $> make help | less After successfully building the package, the package can be checked by invoking the `check' make target like so: $> make check After successfully checking the package, the package can be installed by invoking the `install' make target (as root) like so: $> sudo make install The test suites that ship with the package can be invoked after the package has been installed by invoking the `installcheck' target. This target can either be invoked as root, or as a normal user, like so: $> make installcheck (Note: you must add the --enable-autotest flag to configure, above for the test suites to be invoked with `make installcheck'.) The package can be cleanly removed by invoking the `uninstall' target (as root): $> sudo make uninstall Then the build directory and tarball can be simply removed: $> cd .. $> rm -rf build $> rm -rf LiS-2.18.6 $> rm -f LiS-2.18.6.tar.bz2 Detailed Installation InstructionsMore detailed installation instructions can be found in the Installation, contained in the distribution in `text', `info', `html' and `pdf' formats: $> cd ../LiS-2.18.6 $> less doc/manual/LiS.txt $> lynx doc/manual/LiS.html $> info doc/manual/LiS.info $> xpdf doc/manual/LiS.pdf The `text' version of the manual is always available in the MANUAL file in the release. The current manual is also always available online from The OpenSS7 Project website at: $> lynx http://www.openss7.org/LiS_manual.html 1 IntroductionThis manual documents the design, implementation, installation, operation and future development schedule of the Linux STREAMS (LiS) package. 1.1 OverviewThis manual documents the design, implementation, installation, operation and future development of the Linux STREAMS (LiS) package. LiS is a software package that comprises an implementation of SVR4 compatible STREAMS for Linux. It takes the form of a loadable module for the Linux kernel. LiS installs in any directory on your system, not in the kernel source tree. (see Installation) LiS-2.12 and beyond utilizes aggressive multi-tasking in multiple CPU SMP environments. For further information concerning this implementation, see LiS SMP Implementation. WARNING: This autoconf/RPM release of Linux STREAMS is distributed under the terms of the GNU Public License (GPL) and not the GNU Lesser Public License (LGPL). This means that you cannot link proprietary STREAMS drivers with LiS and load the entirety into the Linux kernel without violating license restrictions. OpenSS7 Corporation can remove this restriction for subscribers and sponsors of the OpenSS7 Project. 1.2 Organization of this ManualThis manual is organized (loosely) into several sections as follows:
1.3 Conventions and DefinitionsThis manual uses texinfo typographic conventions. 2 Objective3 Reference3.1 Files
3.2 DriversThe LiS package comes with a number of STREAMS drivers and pushable modules in source code form. A number of these drivers and modules are small entities that are used in the testing of LiS. They are included so as to make it easy for any user to run the LiS tests for themselves. Other drivers are used to implement STREAMS based pipes and FIFOs. A driver in STREAMS has a major and minor device number associated with it and an entry in the /dev directory. The driver is opened and closed just like any file. The driver names used in this manual are the declared names that appear in the LiS Config file for the particular driver. 3.2.1 clone-drvrDevice Name/dev/clone_drvr DescriptionThis driver is used to assist LiS in implementing the "clone" open function. It appears under its own name as /dev/clone_drvr. By convention, it is allocated the first major number of all the STREAMS drivers. In order to implement clone opens, one creates a node in the /dev directory for a device whose major number is set to that of the clone driver, and whose minor number is the major number of the driver to which the clone open is to be directed. The clone driver's open routine transfers the open call to the target driver, passing a unique flag that informs the driver that a clone open is being requested. The target driver then allocated a minor device number to uniquely associate with this instance of the open operation. The clone driver synthesizes a new major/minor "device id" to pass back to LiS. LiS recognizes the change of major/minor from the original open and takes steps to allocate control structures unique to this open. The "clone open" operation is intended to make is easy to open one device from a pool of devices, such as pseudo ttys or logical connections. It saves application programs from having to scan a list of device mnemonics issuing trial opens until one is found that succeeds. Note that the driver is named /dev/clone_drvr instead of the more traditional SVR4 /dev/clone. This is to avoid a conflict with another driver named /dev/clone on Linux systems. AuthorDavid Grothe dave@gcom.com 3.2.2 fifoDevice Name/dev/fifo (clone device) /dev/fifo.0 DescriptionThe fifo pseudo-driver (which is internal to LiS) provides STREAMS-based fifos as single character special files, and STREAMS-based pipes as pairs of character special files which are interconnected (see pipe(3)). STREAMS-based fifos differ from typical STREAMS-based character special files in that there are not separate stream head and driver queue pair within the STREAMS-based file. Instead, a fifo is created with only a single queue pair for the stream head. Moreover, in a typical driver queue pair, the write queue is not connected to a next queue. In a fifo, the write queue is directed to the read queue of the pair. A pipe comprises a pair of fifos, with the write queue of each pair directed to the read queue of the other. The two fifos comprising a pipe are referred to as peers, and each somewhat represents a driver to the other. As a degenerate case, a fifo is its own peer. STREAMS modules may be pushed onto fifos and pipes, but should not expect a driver below them; instead, the SAMESTR() function should be used from the write queue of a pair to determine if the module is the lowest in the STREAMS-based file (this is called the midpoint). The structure of a fifo or pipe is preserved when modules are pushed (and popped); i.e., the write queue at the midpoint will always be directed at the read queue of the peer. Input and output are handled at a fifo stream head as they would normally be handled at a stream head. In LiS, an fifo open() entry point exists to assign minor device numbers to new opens under the fifo major device number, and a close() entry point is used correspondingly to release them. These functions are kept in a streamtab data struc ture (as they would normally be for any STREAMS driver or module) which is private to the LiS implementation. Application UsageIn the current Linux kernels, character special major numbers are limited to 16 bits, and major and minor device numbers to 8 bits each. This limits a system to 256 total major device numbers and 256 total minor devices per major device number. This is a rather severe limitation where mechanisms like fifos and pipes are concerned. However, a driver may handle more than one major device number. The fifo pseudo-driver uses this to overcome this limitation, by supporting the automatic allocation and use of multiple major device numbers for fifos and pipes. Specifying more than 256 minor devices is done in the usual manner, i.e., by specifying the number of "units" in the appropriate Config file. Enough major device numbers will be allocated to cover the requested number of minor devices (if available, else an error will occur in strconf(8)). The number allocated will include one minor device per major number to be used as a fifo-specific clone minor device (specifically, minor number 0), which exhibits special behaviour. Normally, when cloning is done via the clone pseudo-driver, the clone major device number is used, along with the desired actual major number as the minor device number. When an open() is performed on such a device, the clone open() routine in turn calls the appropriate driver's open(), with the sflag parameter set to CLONEOPEN. The driver's open() is expected in this case to allocate an unused minor device number, and return it via an entirely new device number in the devp parameter. In this way, a driver can change the device number to be used for a STREAMS-based file. When minor device 0 for a specified for a fifo major device, the driver will also clone a new minor device number. However, LiS opens fifo devices differently; specifically, when an already-opened fifo-specific clone minor device is reopened, the new and subsequent opens will use the already-opened clone. Thus, using minor device 0 for a fifo when creating a file sys tem node will ensure that all concurrent opens of the associated path name will use the same STREAMS-based file; at the same time, opens of different file system nodes via different paths will open their respectively different STREAMS-based files. This is essentially how kernel-based fifos behave -applications and users of STREAMS-based fifos don't have to keep track of minor numbers to achieve this same behaviour when it is desired. It is in fact recommended that only two forms of file sys tem nodes be used for STREAMS-based fifos: the clone major number as major number with a fifo major number as minor number, to be used when every open of the associated path must clone a new fifo, and a fifo major number as major number with 0 as the minor number, to be used when new opens are to clone a new fifo but subsequent concurrent opens are to use the already opened fifo. These are represented by two device special file paths created when LiS is installed: /dev/fifo for the former, and /dev/fifo.0 for the latter. It is recommended that these be used, possibly along with the equivalent of stat(2) to determine appropriate major device numbers for the clone and fifo pseudo-drivers, which are also determined when LiS is installed. It can be noted that pipes are actually created as instances of the former, after which the write queues are peer-connected. The fifo pseudo-driver allocates minor devices in round-robin fashion; i.e., a list of available minor devices is kept, and once a minor number is finally closed, it is put at the end of this list. Thus, a fifo minor device which is opened and closed will not be immediately reused. WarningsBecause STREAMS-based fifos and pipes are implemented as character special devices, they do not appear as pipe devices when examined with stat(2) or the equivalent (e.g., ls(1)); i.e. the S_IFIFO indication is not set in the mode - S_IFCHR is set instead, and the actual device number is indicated in the st_rdev field of the stat data structure. Because of the potential use of multiple major numbers, applications should not depend on a fifo or pipe having a specific major device number, nor should an application depend on all fifos and pipes having the same major device number. See Alsoclone(9), connld(9), fifo(4), ls(1), pipe(3), pipemod(9), STREAMS(4), stat(2), strconf(8) AuthorJohn Boyd, protologos LLC. jaboydjr@netwalk.com 3.2.3 loop-aroundDevice Name/dev/loop_clone (clone device) /dev/loop.1 /dev/loop.2 DescriptionThis driver is used by LiS and the strtst(8) utility to assist in the regression testing of LiS. It connects two streams together in a manner similar to that of a pipe. Messages written into one stream can be read back from the other. The driver can be operated as a clone device with the two streams being connected via ioctls. A number of ioctls exist that tailor the operation of the driver. The user codes these ioctls as type I_STR and passes a structure of type struct strioctl to the driver. The ic_cmd field of this structure is decoded according to the following table. the ic_dp and ic_len fields delimit an argument structure which is also passed to the driver. The argument structure differs for each type of ic_cmd.
AuthorDavid Grothe dave@gcom.com plus others originally. 3.2.4 mini-muxDevice Name/dev/mux_clone (clone device) /dev/minimux.1 /dev/minimux.2 DescriptionThis driver is used by LiS in its testing procedures. It is a small multiplexing driver that allows cascaded multiplexors to be built and torn down. The driver uses a pair of ioctls to establish connectivity between upper streams and lower streams. This allows control over how data flows through the multiplexor. Both of these ioctls are coded as type I_STR and pass a structure of type struct strioctl to the driver. The ic_cmd field of this structure is decoded according to the following table. the ic_dp and ic_len fields delimit an argument structure which is also passed to the driver. The argument structure may differ for each type of ic_cmd.
AuthorDavid Grothe dave@gcom.com 3.2.5 printkDevice Name/dev/printk DescriptionThis driver accepts messages written to it and prints them from the kernel using the kernel's printk function. It is used by the LiS test software to keep messages from LiS and messages from the test program in sequence. AuthorDavid Grothe dave@gcom.com 3.2.6 sadDevice Name/dev/sad DescriptionThe STREAMS Administrative Driver manages the autopush function of LiS. Using ioctls the system administrator can provide a list of modules that are to be automatically pushed onto a given device when that device is opened. The controls are specified via the strapush structure which is defined in <sys/sad.h>. The ioctl used by the user is of the form: ioctl(fd, command, arg) Where fd is the file descriptor of the file that is open to the sad driver, command and arg are described in the following table. The strapush structure used by the SAD_SAP and SAD_GAP ioctls contains the following fields.
The ioctl function call returns zero upon success or -1 on failure. Upon failure errno(3) is set to the error number describing the failure, usually either EFAULT or EINVAL. Note that the sad driver is a standard AT&T STREAMS function. More comprehensive documentation for this driver can be found in the [40]SVR4 Programmer's Guide: STREAMS. AuthorOle Husgaard sparre@login.dknet.dk 3.3 Modules
The LiS package comes with a number of STREAMS drivers and pushable modules in source code form. A number of these drivers and modules are small entities that are used in the testing of LiS. They are included so as to make it easy for any user to run the LiS tests for themselves. A pushable module in STREAMS is an entity that is added to an existing STREAMS file via the I_PUSH ioctl. These modules are known to LiS by mnemonic name, given as an argument to the I_PUSH ioctl. There are no major and minor device numbers or /dev entries associated with pushable modules. 3.3.1 connldModule Nameconnld DescriptionThe connld module provides a means to generate multiple unique STREAMS-based pipes from a single existing pipe end. connld may only be pushed (via the STREAMS I_PUSH ioctl) onto a STREAMS-based pipe. When first pushed, connld does nothing; on each subsequent open(2), connld will generate a unique STREAMS-based pipe. One end of each new pipe replaces the original pipe end from the perspective of the open call. The other end of each new pipe is sent, effectively as if by the I_SENDFD ioctl, to the other end of the original pipe, ostensibly to be received by a subsequent I_RECVFD ioctl operation. Application UsageThe intent of connld is to provide a means to generate unique pipes which separately and independently connect client processes to a server process. The point of access for such clients is expected to be a path name known to all such clients and to which a pipe end may be connected (via fattach(3)) by the server process. The server establishes the original pipe, pushes connld onto the client end, and then listens via I_RECVFD for new connections on the server end. A client wishing to connect to the server will open(2) the path name representing the client end, and can determine via isastream(3) whether or not the server process is active and attached. If it is, the open() call returns one end of a unique new pipe that thus connects the client to the server. Such a server is responsible both for accepting new connections via I_RECVFD on the original pipe, and for communicating with clients so connected via the received pipe ends. It would also be reasonable for such a server process to invalidate the point of access by calling fdetach(3) before terminating. It should be noted that the poll(2) primitive may be used to indicate when an
Even so, it should be reasonable to expect only The use of connld can be made entirely free-standing by attaching well-known paths to both ends of the original pipe. The relevant capabilities are implemented in LiS so that the original creator of the pipe can close both ends after attaching paths to them, and the process of passing file descriptors can still be carried out via new open()'s as long as both ends remain attached. See Alsofattach(3), fattach(8), fdetach(3), fifo(4), fifo(9), pipe(3), STREAMS(4) HistoryUnix System V Release 4 (SVR4) AuthorJohn Boyd, protologos LLC. jaboydjr@netwalk.com 3.3.2 pipemodModule Namepipemod DescriptionThe pipemod module has the relatively simple task of reversing the sense of
the FLUSH flag bits in To be used appropriately, then, pipemod must be the first module pushed onto a pipe end or a fifo, but it is only necessary on one end of a pipe. pipemod is not needed if flush handling need not be supported, or if its function is supported by other means. See Alsofifo(9), pipe(3), fifo(4), STREAMS(4) HistoryUnix System V Release 4 (SVR4) AuthorJohn Boyd, protologos LLC. jaboydjr@netwalk.com 3.3.3 relay, relay2Module Namerelay relay2 DescriptionThese are two names for the same module. All the module does is forward STREAMS messages along on the stream using putnext(9). These modules are used in the testing of LiS but are not otherwise useful. One could use the source code as a starting point for coding a pushable STREAMS module. AuthorDavid Grothe dave@gcom.com 3.4 LibrariesDuring the installation process of Linux STREAMS (LiS) a subroutine library is built and installed on your system. Three versions of the library are built and installed. They are as follows.
These three libraries are copied to the directory /usr/lib when LiS is installed. In addition, the utility program ldconfig is run during the LiS make install. This causes this library to be linked, or searched, ahead of the standard C library. This is necessary because the standard C library contains dummy routines for the STREAMS interface functions, or most of them in the best case. If these dummy routines preempt the LiS versions then STREAMS applications will always perceive error returns from such routines as see getmsg(2) and see putmsg(2). 3.4.1 Library RoutinesThe following routines are present in the libraries libLiS.a and libLiS.so. The library libpLiS.so omits the "pipe" routine. The routines in these libraries are standard STREAMS interface routines. As such we do not offer detailed descriptions of the functions of these routines. Instead we refer the reader to the AT&T SVR4 STREAMS documentation. int fattach(int fd, const char *path); int fdetach(const char *path); int getmsg(int fd, void *ctlptr, void *dataptr, int *flagsp); int getpmsg(int fd, void *ctlptr, void *dataptr, int *bandp, int *flagsp); int isastream(int fd); int pipe(int *fd); int poll(void *pollfds, long nfds, int timeout); int putmsg(int fd, void *ctlptr, void *dataptr, int flags); int putpmsg(int fd, void *ctlptr, void *dataptr, int *bandp, int *flagsp);
These routines are all very small pieces of code. Most of them simply pass their parameters to LiS via a system call. The see fattach(3) and fdetach see fdetach(3) routines use ioctls to LiS if there is no system call available to call directly. The poll see poll(2s) routine simply executes the poll system call. It is present for backward compatibility to 2.0 kernels, in which LiS provided the poll system call. The see pipe(2s) routine has the same semantics as the standard C library routine. It uses STREAMS FIFOs to implement the pipe instead of the standard Linux pipes. The libpLiS.so library, the one that preempts the standard C library, omits the STREAMS pipe routine so that standard Linux pipes are used unless the user explicitly links in libLiS. 3.4.2 Using the LibraryTo use one of the LiS libraries you can include the file <sys/stropts.h> in your program source code. On your compiler command line you can add the option `-I/usr/include/LiS' to include the version of stropts.h that is distributed with LiS, or omit the option to include the system standard header file. The two header files are believed to be compatible enough that it does not matter which one you include in your program. When linking your program, or performing a final cc to build your executable, include one of the following options on your command line.
Omit any options As of libc-2.2.1 the LiS STREAMS interface routines will be used automatically via libpLiS.so. 3.5 UtilitiesThe Linux STREAMS (LiS) package contains some user level commands that are used to manage the package and assist the user with STREAMS functions. These commands are installed in /usr/bin or /usr/sbin. They are referred to a "global commands." A second group is built in the LiS installation directory and left there. This second group is oriented more toward testing of LiS than toward its operation. These commands remain undocumented since they are primarily intended for the use of the authors of the modules that they test. These are the commands that are installed in /usr/bin or /usr/sbin, and are thus globally accessible to any user with those directories in his/her path. 3.5.1 fattach/usr/sbin/fattach [-v] [-m|-u|-M mode] [-p|STREAMS-path] path ... /usr/sbin/fattach -? DescriptionThe fattach program provides a command-line interface to the underlying fattach(3) function. If the -p and/or the -c option is specified, a STREAMS-based pipe is created and its two ends are alternately attached to the path names given. In this mode of usage, at least two path names are required, but there need not be an even number of path names (i.e., the pipe ends need not be attached to the same number of paths). If the -p and -c options are not specified, the first path name given must identify a STREAMS-based file. That file will be opened, and it will be attached to each of the path names subsequently specified (of which there must be at least one). Options
Return ValueUpon successful completion, i.e., if all given path names are attached to, fattach returns 0. Upon failure, fattach returns 1. However, the failure of one more attachments does not otherwise affect those that succeed, and the user is responsible for detaching any that may have succeeded if that is the desired behaviour in the event of any failures. Application UsageThe -p and -c options provide a convenient means for creating free-standing mounted pipes. The openers of the paths attached via -p will share a single pipe, while the openers of the paths attached via -c will have access to a pipe-serving pipe. I.e., each open of the first end (e.g., the client end) will generate a new pipe, one end of which will be given to the opener, and the other end of which will be passed as if by the I_SENDFD ioctl to the path attached to the other end (e.g., the server end). Each opener of the server path could poll(2) for input, receive a new pipe end using the I_RECVFD ioctl, and then close the server path, thereafter using the new pipe end to communicate with the corresponding opener of the client path (note that the sense of client and server will in fact depend on the application - users of the two paths need only be aware of whether or not an I_RECVFD ioctl must be performed). See Alsoconnld(9), fattach(3), fdetach(3), fdetach(8), STREAMS(4), umask(2) HistoryAn fattach function has been provided for various STREAMS implementations based on SVR4 STREAMS. Not all of these have provided a corresponding utility program of this sort. AuthorJohn Boyd, protologos LLC jaboydjr@netwalk.com 3.5.2 fdetach/usr/sbin/fdetach [-v] path ... /usr/sbin/fdetach -a /usr/sbin/fdetach -? DescriptionThe fdetach program provides a command-line interface to the underlying fdetach(3) function. It is thus intended to provide a convenient means to dismantle so-called mounted STREAMS. If the -a option is specified, all currently attached STREAMS-based files are detached. If the -a option is not specified, the path names given are taken to identify paths to which STREAMS-based files are currently attached. Those files will be detached from these paths. Options
Return ValueUpon successful completion, i.e., if all given path names identify mounted STREAMS and these are all successfully detached, fdetach returns 0. Upon failure, fdetach returns 1. Note, however, that a failure indication does not mean that no action is taken; i.e., those detachments that succeed are not affected by those that fail. WarningsIt should be noted that although the fdetach program implements the -a option, by passing "*" to the fdetach function, this is not at all equivalent to specifying "*" on the command line when executing the program. Normally, "*" specified on the command line will be converted by a shell into a list of all files in the current working directory. By contrast, the -a option causes the fdetach operation to operate not with respect to path names at all, but with respect to STREAMS devices currently active within the STREAMS subsystem. I.e., each active stream head is examined for attachments, and any attachments found are dismantled. The intended use for the -a option is thus to undo all attachments, e.g., in preparation for unloading the STREAMS subsystem. See Alsofdetach(3), fattach(8), STREAMS(4) HistoryAn fdetach function has been provided for various STREAMS implementations based on SVR4 STREAMS. Not all of these have provided a corresponding utility program of this sort. AuthorJohn Boyd, protologos LLC jaboydjr@netwalk.com 3.5.3 polltst/usr/bin/polltst Descriptionpolltst is a simple test program for the poll system call. Using poll, it reads keystrokes from stdin, writes them to one end of the LiS loopback driver, reads them from the other end and then writes them back to stdout. While performing this operation it configures stdin for "no echo" mode, so the appearance of "echoed" characters is evidence of the operation of poll involving both a STREAMS and a non-STREAMS file. AuthorDavid Grothe dave@gcom.com 3.5.4 streams/usr/sbin/streams Options DescriptionThe streams program is used to perform several different management functions for the LiS package, including starting and stopping the LiS subsystem. Options
Debug OptionsThe value that is used with the -d option consists of the logical "or" of the following single bit options.
Most of these options are intuitive as to their operation from the mnemonics. The The The The The options The The AuthorDavid Grothe dave@gcom.com 3.5.5 strmakenodes/usr/sbin/strmakenodes Descriptionstrmakenodes makes all of the /dev entries that are associated with LiS as a result of the LiS build process. All of the Config files that contributed to the LiS build are scanned for their "node" declarations. strmakenodes performs a mknod system call for each specified "node". This command must be run before LiS can operate correctly after it is installed. This command is run automatically as a result of the "make install" operation of LiS. This command accepts the option "-r" to mean remove nodes instead of making them. The command is run with this option as a result of the "make uninstall" operation. The source code for this command is generated automatically as a side-effect of running the strconf utility. 3.5.6 strtst/usr/bin/strtst Descriptionstrtst is a test program which tests the core functionality of LiS. It is a user level program which uses the built-in drivers that are installed by default with LiS. It performs numerous STREAMS operations and checks the results for correctness. It prints out a voluminous log file whose output is routed to the "messages" file (kernel informational messages). The output of strtst can be compared to earlier "reference" outputs to see if the behaviour of LiS has changed as a result of modifications to the code. AuthorDavid Grothe dave@gcom.com 3.5.7 timetst/usr/bin/timetst [Iterations] Descriptiontimetst peforms a timing test using the LiS loopback driver. It writes short messages downstream under several different LiS options and measures the round trip time for the messages. The Iterations parameter specified the number of iterations that timetst uses in its timing loop, the default being 100,000. AuthorDavid Grothe dave@gcom.com 3.6 DevelopmentLinux STREAMS (LiS) provides for an interface between STREAMS drivers and the surrounding kernel environment. This interface has grown over time and is likely to expand in the future. In the Linux kernel, much of the interface between drivers and other kernel modules and the core kernel services, such as memory allocation and synchronization primitives, is implemented in macros and inline functions declared in kernel header files. This technique was used (probably) out of considerations of efficiency (defined as execution speed) and a consideration that there were no version problems with such constructs because one could always recompile one's drivers in the context of the new kernel. The only "kernel primitives" compatibility that has been attempted from one kernel release to the next is source code compatibility. The real world of paying customers is quite different. And, as it happens, the world of paying customers seems to impinge upon LiS considerably. In this world, the customers do not want to rebuild the kernel. They don't want to build the kernel at all. They want to install a distribution with a binary kernel that was configured only at install time. They then want to install add-on binary packages, and they expect these packages to operate correctly with their kernel. When these add-on packages consist of STREAMS based protocol drivers, LiS is usually the only piece of code that is recompiled from source upon installation into the customer's environment. The STREAMS drivers themselves are typically distributed in binary and linked in with LiS. The resulting module is then typically loaded using "modprobe" or some equivalent command. In these circumstances it is highly desirable for LiS to "buffer" the interface between the STREAMS drivers and the kernel environment. This allows the STREAMS driver writers to deliver smaller binary packages to their customers and minimizes the number of different versions of those packages that must be maintained by the STREAMS driver writers. Ideally, LiS would be able to present a uniform DKI that would support one version of a user's STREAMS driver across all versions of the Linux kernel. This ultimate goal is probably not achievable, but it is possible to insulate STREAMS drivers from the Linux kernel to a considerable extent. This is possible in part due to the implied DKI of a STREAMS driver. A STREAMS driver most likely will confine itself to the SVR4 types of DKI calls which have syntax and semantics that do not change over time. The main challenges come from the use of constructs, such as PCI configuration and interrupt service routines, that go outside the SVR4 DKI and must use services of the Linux kernel more-or-less directly. In general, LiS attempts to replace inline functions and macros with actual subroutine calls to perform kernel operations. This allows the STREAMS driver to be compiled once with references to these routines, with the routines themselves being compiled in the context of the specific kernel version at package installation time. Thus, the STREAMS drivers do not have to be sensitive to differences in kernel versions. 3.6.1 Coding STREAMS ApplicationsThis manual is concerned with the include files and compilation techniques for STREAMS application programs. It is not intended to be a tutorial on the subject of writing STREAMS applications. Additional resources are available [17]here for reference material. 3.6.1.1 Header FilesIn your STREAMS application program C language source, use the following line to include LiS header files. #include <sys/stropts.h> This will include all of the STREAMS related information that you need for a user level program. If your application program uses the poll system call then you need to include one or the other of the following lines depending upon the kernel version that the application is intended to run on. For kernel versions in the 2.0 group, use the following in order to include the poll.h from LiS. #include <sys/poll.h> For kernel versions in the 2.2 group, use the following in order to include poll.h from the kernel's source tree. #include <linux/poll.h> 3.6.1.2 Compilation OptionsWhen you compile your STREAMS application, put the following compiler option on the gcc (cc) command line for each C language file that contains any of the above include lines. -I/usr/include/LiS 3.6.1.3 Linking OptionsWhen you perform the final link of your application using cc or gcc, add the following to the end of your list of files and libraries to be linked. This links in the system call interface routines for LiS. -lLiS This library includes the STREAMS based version of the pipe system call. If you want to use the standard STREAMS library routines, such as getmsg and putmsg, but you want to use the standard Linux pipe system call, use the following instead. -lpLiS 3.6.1.4 Other STREAMS ResourcesClick [18]here for a list of other locations that you can consult for general information concerning writing STREAMS applications. 3.6.2 LiS SMP ImplementationBeginning with LiS-2.12, LiS makes aggressive use of multiple CPUs in SMP kernels. It is useful for the STREAMS programmer to have some insight into this design in order to know whether, or which, locking techniques must be used in driver code. 3.6.2.1 CPU SchedulingLiS starts up a kernel thread for each CPU on the system. In the output of a ps display each thread will show as a process with a name such as "LiS-2.12:0". This notation means that an LiS kernel thread is running and is bound to CPU 0 (":0"). LiS maintains a single global list of queues whose service procedures need to be run. A queue is place into this list by calling the function qenable, whether directly or indirectly. A given queue can only be in this list once. The read queue and write queue of a queue-pair are considered two different queues for scheduling purposes and both can be scheduled simultaneously. At "certain points in time" LiS performs an operation that makes a decision concerning the manner in which service procedures are to be invoked via the list of scheduled queues. There are several factors which influence this decision.
In the case that the queue processing routine does not get called directly, LiS needs to decide whether to wake up a kernel thread process or whether to defer queue processing until an LiS system call is about to exit. LiS tries to enlist one CPU for every four queues that are scheduled. This number is based on considerations of CPU loading and average queue lengths from queueing theory. If the number of CPUs currently processing queues is not enough to meet this target then the scheduling process seeks to enlist more CPUs until the number of CPUs is sufficient to meet this target value. Of course, sometimes there are simply too may queues schedule for processing for the number of available CPUs. In that case, all available CPUs run their queue processing threads. When making the decision as to whether or not to wake up a kernel thread, LiS gives precedence to the CPU that it is running on. If the scheduling algorithm is called from a point just prior to executing back to the user, and if the kernel thread for the active CPU is sleeping, then LiS will simply call the queue processing routine without waking up the kernel thread. This saves the wakeup and context switch overhead. The routine that actually runs the queues removes one element at a time from the list of scheduled queues and calls the service procedure pointed to by the queue. The routine continues until the list of scheduled queues is empty. Thus, when a kernel thread is actively processing queues, and if the number of scheduled queues does not exceed the estimated capacity of the running threads, it is quite efficient to simply add a queue to the list and let the already running threads process them in due course. 3.6.2.2 Queue LockingThe queue_t structure in LiS contains a spin lock that is used by LiS to ensure that service procedures are not reentered for the same queue. This lock is not to be used by driver code. When the LiS queue running routine removes a queue from the list of scheduled queues it acquires this lock prior to calling the service procedure. LiS also acquires this lock when calling the put procedure associated with a queue. Thus, execution of the put and service procedure are excluded for the same queue. In a multi-CPU environment, it can happen that one CPU is calling the put procedure while a second CPU is calling the service procedure for the same queue. In this case, one or the other spins until the first CPU finishes the operation and releases the spin lock. When LiS is about to call the put procedure of a queue from the put or service procedure of a neighbouring queue (because the driver called the putnext function), it continues to hold the lock for the calling queue while acquiring the lock for the destination queue. The locks are acquired sequentially as the chain of putnext calls traverse the stream. The locks are released in reverse order as the put procedures return. This has the effect of incrementally locking the entire stream as messages are passed from one module to another. This behaviour is only of interest when modules are I_PUSHed on top of a driver. Otherwise, it is just the stream head write queue and the driver write queue that need to be locked (or other pairwise combinations such as the driver read queue and stream head read queue, or queues involving multiplexers). The lock that LiS uses has the effect of excluding multiple entries from different threads into the put or service procedure for a given queue. The other queue in the queue pair is unaffected by this locking. Therefore, if there are data structures shared between the read and write put and service procedures of a driver or module, it is up to the driver writer to protect these structures with spin locks. 3.6.2.3 Service Procedure ContextDue to the manner in which service procedures are called, sometimes from the LiS queue runner threads and sometimes from a "borrowed" system call, service procedures may or may not have some user context present when they run. Service procedures should always assume that there is no user context. Even in the cases where there is some user context, the identity of the user process is unpredictable. LiS does, however, maintain a copy of the credentials of the process that opened the stream when it calls service procedures on the stream. LiS saves the user and group identifiers plus the capability masks (credentials) of the running process in the stream head structure at the time that the STREAMS file is opened. These identifiers are restored to the task structure before calling a service procedure on that stream. When calling put procedures, however, no such identity restoration occurs. So the credentials in place when a driver or module put procedure is invoked are those of the invoking entity. Because the queue runner threads always begin driver entry with a call to the service procedure, entries into the put procedures of subsequent drivers will have the credentials of the stream whose service procedure was called in the first instance. When a driver's put procedure is entered from a system call the credentials will be that of the user process which issued the system call. 3.6.2.4 Scheduling StatisticsLiS gathers statistics on its queue scheduling algorithm. They can be printed out with the command streams -S. The output looks like the following. N-CPUs N-Qrunners N-Running N-Requested 2 2 0 0 CPU Qsched-Cnts Qsched-ISR Svc-Q-Cnts Qrun-Cnts Active Thread-PID 0 540752204 175753842 459587537 239611835 0 857 1 540683832 175833424 459150290 239672683 0 858 The fields have the following meanings.
3.6.3 Operating System Interface RoutinesIn the file <sys/osif.h>, LiS provides insulation routines for a number of commonly used kernel functions. These functions are used with their Linux kernel names, but those names are redefined in <sys/osif.h> to be subroutine calls on functions that are actually defined in the file osif.c within LiS. The osif.c file is compiled at LiS installation time and is sensitive to kernel version information. To use this interface, you include the header files that you would normally include to use the kernel functions, and then include <sys/osif.h> after all of the kernel include files. This allows for the redefinition of the names. The kernel functions provided via <sys/osif.h> are as follows, grouped by type of function. 3.6.4 PCI BIOS InterfaceThese are routines that utilize or simulate the original PCI BIOS interface of the 2.0 series of kernels. The names of these routines are changed via defines. Use them as if the prototypes were as follows. You can use these routines on 2.2 kernels even though they represent the 2.0 style of interface. #if LINUX_VERSION_CODE < 0x020100 /* 2.0 kernel */ unsigned long pcibios_init(unsigned long memory_start, unsigned long memory_end); #else /* 2.1 or 2.2 kernel * / void pcibios_init(void) ; #endif int pcibios_find_class(unsigned int class_code, unsigned short index, unsigned char *bus, unsigned char *dev_fn); int pcibios_find_device(unsigned short vendor, unsigned short dev_id, unsigned short index, unsigned char *bus, unsigned char *dev_fn); int pcibios_read_config_byte(unsigned char bus, unsigned char dev_fn, unsigned char where, unsigned char *val); int pcibios_read_config_word(unsigned char bus, unsigned char dev_fn, unsigned char where, unsigned short *val); int pcibios_read_config_dword(unsigned char bus, unsigned char dev_fn, unsigned char where, unsigned int *val); int pcibios_write_config_byte(unsigned char bus, unsigned char dev_fn, unsigned char where, unsigned char val); int pcibios_write_config_word(unsigned char bus, unsigned char dev_fn, unsigned char where, unsigned short val); int pcibios_write_config_dword(unsigned char bus, unsigned char dev_fn, unsigned char where, unsigned int val); const char *pcibios_strerror(int error) ; 3.6.5 PCI InterfaceThese routines constitute the PCI interface as implemented in the 2.2 series of kernels. Please note that these are filtered calls to the operating system and still depend directly upon the kernel structure "struct pci_dev". LiS provides a more abstract interface to PCI that does not depend upon the direct definition kernel structures. The [61]LiS PCI interface is to be preferred since it provides more insulation against changes in the kernel. struct pci_dev *pci_find_device(unsigned int vendor, unsigned int device, struct pci_dev *from); struct pci_dev *pci_find_class(unsigned int class, struct pci_dev *from); struct pci_dev *pci_find_slot(unsigned int bus, unsigned int devfn); int pci_read_config_byte(struct pci_dev *dev, u8 where, u8 * val); int pci_read_config_word(struct pci_dev *dev, u8 where, u16 * val); int pci_read_config_dword(struct pci_dev *dev, u8 where, u32 * val); int pci_write_config_byte(struct pci_dev *dev, u8 where, u8 val); int pci_write_config_word(struct pci_dev *dev, u8 where, u16 val); int pci_write_config_dword(struct pci_dev *dev, u8 where, u32 val); void pci_set_master(struct pci_dev *dev); 3.6.6 IRQ InterfaceThese are the routines that are used to attach and detach interrupt service routines to hardware interrupts. int request_irq(unsigned int irq, void (*handler) ((int, void *, void *), unsigned long flags, const char *device, void *dev_id); void free_irq(unsigned int irq, void *dev_id); void disable_irq(unsigned int irq); void enable_irq(unsigned int irq); 3.6.7 I/O Memory MappingThese are the routines that are typically used to map PCI bus or physical addresses to CPU virtual addresses. LiS includes some backward compatibility here to older kernel versions. void *ioremap_nocache(unsigned long offset, unsigned long size); void iounmap(void *addr); void *vremap(unsigned long offset, unsigned long size); unsigned long virt_to_phys(volatile void *addr); void *phys_to_virt(unsigned long addr); 3.6.8 I/O Port AccessThese are the routines that allow a driver to register I/O ports. int check_region(unsigned int from, unsigned int extent); void request_region(unsigned int from, unsigned int extent, const char *name); void release_region(unsigned int from, unsigned int extent); 3.6.9 Memory AllocationThese are the kernel routines that can be used to allocate memory. LiS also has a more insulated abstraction for kernel memory allocation. It is recommended that you use the [66]LiS memory allocator versions rather than the direct kernel versions. void *kmalloc(size_t nbytes, int type); void kfree(const void *ptr); void *vmalloc(unsigned long size); void vfree(void *ptr); 3.6.10 DMA RoutinesThese are the routines that are used to allocate a main-board old-style DMA channel for use by your driver. These are not much used anymore. See below for a more elaborate abstraction of DMA routines. int request_dma(unsigned int dma_nr, const char *device_id); void free_dma(unsigned int dma_nr); 3.6.11 Delay RoutinesThis is the routine that simply spins the CPU for a given number of microseconds. LiS also redefines the symbol "jiffies" to a subroutine call to help insulate STREAMS drivers from changes in the way the kernel keeps track of time. Remember, the redefinition is accomplished using C language defines, so the following declarations describe the effective usage of these symbols, not their literal definition. void udelay(long micro_secs); unsigned long jiffies; 3.6.12 Printing RoutinesThese are the most commonly used printf-like routines in the kernel. STREAMS drivers would be more portable if they used the cmn_err routine instead of printk. int printk(const char *fmt, ...); int sprintf(char *bfr, const char *fmt, ...); int vsprintf(char *bfr, const char *fmt, va_list args); 3.6.13 Timer RoutinesThese are the the routines that start and stop kernel timers. STREAMS drivers would be more portable if they used the standard "[71]timeout" routine. void add_timer(struct timer_list *timer); int del_timer(struct timer_list *timer); The following routine converts time in micro seconds to system "ticks". The "ticks" value is suitable for use with the timeout routine. Note that if the micro_sec parameter is less than the number of micro seconds in a system tick then the routine returns zero. unsigned lis_usectohz(unsigned micro_sec); The following routine is an LiS abstraction of the C library routine gettimeofday. Note the absence of the time zone parameter. void lis_gettimeofday(struct timeval *tv); The following two kernel routines are called via the LiS osif.c code. void do_gettimeofday(struct timeval *tp); void do_settimeofday(struct timeval *tp); 3.6.14 Sleep and Wakeup RoutinesThese are the kernel routines for sleeping using wait queues. STREAMS drivers should not be using these since only "open" and "close" routines are allowed to sleep, and for those cases, [73]LiS semaphores would provide better insulation from the kernel. STREAMS "put" and "service" routines should use [74]LiS spin locks for mutual exclusion. void sleep_on(OSIF_WAIT_Q_ARG); void interruptible_sleep_on(OSIF_WAIT_Q_ARG); void wake_up(OSIF_WAIT_Q_ARG); void wake_up_interruptible(OSIF_WAIT_Q_ARG); 3.6.15 Thread CreationA STREAMS driver in LiS can create kernel threads if it so chooses. The following routine simplifies this task. It consolidates all of the kernel manipulations involved with the creation of a kernel thread into one place, thus removing references to these kernel functions from STREAMS driver code. 3.6.15.1 Prototypepid_t lis_thread_start(int (*fcn) (void *), void *arg, const char *name); int lis_thread_stop(pid_t pid); Arguments fcn The function that is to be used as the entry point for the thread. arg The argument passed to the function. name An ASCII name associated with the thread. This name should be less than 16 characters in length. It will be the name of the thread that displays in a ps listing. 3.6.15.2 Operationlis_thread_start creates a new thread, performs some operations prior to entering the fcn, and then calls fcn which acts as the "main" routine for the thread. The arg parameter is passed to fcn. Before fcn is entered, the newly created thread will have shed all user space files and mapped memory. Thus, it is a kernel-only thread. All signals are still enabled. Note that when the kernel goes down for reboot all processes are first sent a SIGTERM. Once those have been processed, all processes are then sent a SIGKILL. It is the implementor's choice which of these it pays attention to in order to exit prior to a reboot. The fcn is entered with the "big kernel lock" NOT held, just as it would be for calling the "kernel_thread" function directly. On 2.2 kernels, the fcn should get this lock so that it can utilize kernel services safely. The user's fcn returns a value when it exits and that value is returned to the kernel. It is not clear that anything actually pays any attention to this returned value. It particular, it is not visible to the thread that started the new thread. lis_thread_start itself returns the process id of the new thread, or a negative error number. This value can be used to kill the thread. lis_thread_stop kills a thread started by lis_thread_start. It returns 0 for success or a negative error number for failure. 3.6.16 Major/Minor Device NumberingPlease note that LiS-2.17 changed the internal representation of the major and
minor device numbers within the 32 bit LiS provides a typedef for STREAMS drivers include the file <sys/stream.h> that causes the view of
The sample drivers that come with LiS now use these constructs to manipulate device structures and can serve as examples for their usage. Within a STREAMS driver it is occasionally necessary to make a 3.6.17 LiS Memory AllocationLiS provides for several different styles of memory allocation, all of them insulated from the Linux kernel. These routines allow your driver to allocate memory in several different ways while still maintaining compatibility with different versions of the Linux kernel, with no driver recompilation required. To use the LiS memory allocation routines include the file <sys/lismem.h> in your STREAMS driver source code. 3.6.18 LiS malloc and free EquivalentsThe first group of memory allocation routines are the routines that play the role of "malloc" and "free." These routines keep a master linked list of all allocated memory areas. This list can be printed out via an ioctl to LiS. Each allocated area is tagged with the file name and line number of the code that caused it to be allocated. Each area contains a guard word at the front and back to enable the allocator to detect "off by one" accesses outside the allocated area. LiS uses this allocator internally for allocating queues, messages and other internal data structures. This would be the allocator of choice for STREAMS drivers to use to allocate instance structures. Memory allocated in this manner is ultimately allocated by the kernel routine "kmalloc". As such, it is not guaranteed to be DMA-able (in the old style), or to occupy physically contiguous memory locations. [78]See below for routines that can be used to allocate these types of memory areas. The routines are as follows: void *ALLOC(int nbytes); void *ALLOCF(int nbytes, char *tag); void FREE(void *ptr); The ALLOC and FREE routines are analogous to "malloc" and "free". The ALLOCF routine includes a character string which is prepended to the file name stored as the location from which the allocation occurred. It can serve as a tag for the type of memory being allocated. Usage examples: ptr = ALLOC(456); FREE(ptr); ptr = ALLOCF(578, "Instance: "); FREE(ptr); 3.6.19 LiS Kernel Memory AllocatorsThese routines use the LiS malloc/free internal routines to allow for more flexibility in the options used when calling the kernel allocator. These routines all lead to a call on "kmalloc" with appropriate options. It is worth noting that the numerical value of the constants used in calling the kernel's "kmalloc" routine changed between the 2.2 and 2.4 versions of the kernel. Thus, drivers which called the kernel's "kmalloc" directly have to be recompiled to run in a 2.4 kernel. STREAMS drivers using the memory allocation interface defined here could run without modification and without a recompilation on both kernels, assuming that the drivers otherwise did not use any direct kernel functions. void *lis_alloc_atomic(int nbytes); void *lis_alloc_kernel(int nbytes); void *lis_alloc_dma(int nbytes); void *lis_free_mem(void *mem_area); These routines pass the allocation options GFP_ATOMIC, GFP_KERNEL, and GFP_DMA, respectively, to "kmalloc" when allocating the memory. LiS takes care of passing the proper values to the kernel routine so that driver code can remain portable. The routine lis_free_mem returns a NULL pointer for the convenience of the caller. The kernel's kmalloc is restricted as to the number of bytes that it will allocate. The LiS routines do not have this restriction. If the number of requested bytes is larger than 16K the LiS allocation routines will call the page allocator to allocate the memory. The lis_free_mem routine knows whether to free pages or to use the kernel's kfree routine. Usage Examples: ptr = lis_alloc_kernel(sizeof(structure)); ptr = lis_free_mem(ptr); /* returns NULL pointer */ 3.6.20 LiS Page AllocatorThese routines allow a STREAMS driver to allocate memory directly from the kernel's page allocator. Memory allocated in this manner occupies physically contiguous locations and is suitable for use with bus master DMA PCI devices. Unlike the kernel's page allocator, the size that is specified when calling the LiS page allocator is in bytes, not "order", or other encoding of page size. LiS calculates the number of pages based upon the requested size. Also, LiS does not require you to pass the size of the area when freeing the page. The routines are as follows: void *lis_get_free_pages(int nbytes); void *lis_free_pages(void *ptr); The lis_free_pages routine returns a NULL pointer for the convenience of the caller. Usage Examples: ptr = lis_get_free_pages(1024 * kbytes); ptr = lis_free_pages(ptr); 3.6.21 LiS PCI InterfaceTo assist in the portability of STREAMS drivers across different versions of the Linux kernel, LiS provides an abstraction of the PCI configuration interface. It defines a data structure that is used to describe a PCI device and a set of routines that perform operations on PCI configuration space. Using these abstractions, a STREAMS driver can be portable from the 2.2 kernel to the 2.4 kernel with no recompilation required. The LiS structures completely hide the kernel data structures and PCI configuration space operations from the STREAMS driver. To use this interface include the file <sys/lispci.h> in your STREAMS driver source code. 3.6.22 The LiS PCI Device StructureThis structure is distinct from a similar structure which is defined by the Linux kernel, but which differs significantly between the 2.2 and 2.4 kernels. The LiS version of this structure is oriented toward providing just enough information to allow a driver to operate the PCI device, without being concerned about the details of PCI bus topology. This structure is used to return information to the STREAMS driver concerning devices that meet certain criteria, such as device class or manufacturer device identification. #define LIS_PCI_MEM_CNT 12 /* # mem addrs */ typedef struct lis_pci_dev { unsigned bus; /* bus number */ unsigned dev_fcn; /* device/function code */ unsigned vendor; /* vendor id */ unsigned device; /* device id */ unsigned class; /* class type */ unsigned hdr_type; /* PCI header type */ unsigned irq; /* IRQ number */ unsigned long mem_addrs[LIS_PCI_MEM_CNT]; void *user_ptr; /* private for user */ } lis_pci_dev_t; The bus field contains the bus number on which the device is located. LiS obtains this information from the kernel. The dev_fcn field contains an encoding of the device number on the bus and the function number within the device that this particular structure pertains to. The pair bus and dev_fcn uniquely identifies a device in the PCI subsystem. Devices can be searched for on the PCI bus by bus number and dev_fcn value (see below). Given a dev_fcn value, a pair of macros will extract the "device" portion and the "function number" portion from it.
The vendor and device fields contain the vendor id (manufacturer code) and the vendor's device identifier for the device. Devices can be searched for on the PCI bus by vendor and device identifier (see below). The class field contains the class code associated with the device. Devices can be searched for on the PCI bus by class code (see below). The hdr_type field gives the type information for the PCI configuration space header. The irq field gives the IRQ number that is assigned to this device. This is the number that is used to attach an interrupt service routine to the device. The mem_addrs field contains a list of addresses associated with the device. These are raw PCI bus addresses and are not mapped into the address space of the processor. Empty slots contain the value zero. 3.6.23 LiS PCI Search RoutinesThese routines allow the STREAMS driver to find devices on the PCI bus and obtain a pointer to the lis_pci_dev_t structure for the device. 3.6.23.1
|
−
A fairly LSB compliant GNU/Linux distribution.6
| |
−
Linux 2.4 kernel (2.4.10 - 2.4.27), or
| |
−
Linux 2.6 kernel (2.6.3 - 2.6.21);
| |
−
glibc2 or better.
| |
−
GNU info (for info files).
| |
−
GNU groff (for man pages).7
|
If you need to rebuild the package from sources with modifications, you will need a larger GNU toolchain as described in See Downloading from CVS.
This section discusses compatibility with major prerequisites.
Linux STREAMS (LiS) is compatible with the following Linux distributions:8
When installing from the tarball (see Installing the Tar Ball), this distribution is probably compatible with a much broader array of distributions than those listed above. These are the distributions against which the current maintainer creates and tests builds.
The Linux STREAMS (LiS) package compiles as a Linux kernel module. It is not necessary to patch the Linux kernel to build or use the package.9 Nor do you have to recompile your kernel to build or use the package. OpenSS7 packages use autoconf scripts to adapt the package source to your existing kernel. The package builds and runs nicely against production kernels from the distributions listed above. Rather than relying on kernel versions, the autoconf scripts interrogate the kernel for specific features and variants to better adapt to distribution production kernels that have had patches applied over the official kernel.org sources.
The Linux STREAMS (LiS) package is compatible with 2.4 kernel series after 2.4.10 and has been tested up to and including 2.4.27. It has been tested from 2.6.3 up to and including 2.6.21 (with Fedora 7 patchsets). Please note that your mileage may vary if you use a kernel more recent than 2.6.21: it is difficult to anticipate changes that kernel developers will make in the future. Many kernels in the 2.6 series now vary widely by release version and if you encounter problems, try a kernel within the supported series.
UP validation testing for kernels is performed on all supported architectures. SMP validation testing is performed on UP machines, as well as on an Intel 3.0GHz Pentium IV 630 with HyperThreading enabled. Because HyperThreading is not as independent as multiple CPUs, SMP validation testing is limited.
The Linux STREAMS (LiS) package compiles and installs on a wide range of architectures. Although it is believed that the package will work on all architectures supported by the Linux kernel being used, validation testing has only been performed with the following architectures:
32-bit compatibility validation testing is performed on all 64-bit architectures supporting 32-bit compatibility. If you would like to validate an OpenSS7 package on a specific machine architecture, you are welcome to sponsor the project with a test machine.
For LiS version 2.7 and later and for kernel version 2.3.x there are some significant compatibility issues. Version 2.3 of the Linux kernel brings with it some compatibility issues that need to be addressed by the LiS user. The two most important ones concern the file <sys/stropts.h> and the major device numbers used by LiS.
There are no more compatibility problems with <sys/stropts.h> with glibc-2.1 and LiS-2.10. The following is more for historical purposes than practical necessity.
Beginning at least with egcs-2.91.66 (egcs-1.1.2 release), which comes with Red Hat 6.0, there is a file in the standard include directory named <sys/stropts.h>. This file has constant definitions that are incompatible with those used in LiS/include/sys/stropts.h. If you compile an application against the glibc version of stropts.h, and compile LiS using its own version then certain ioctls may not work correctly. You should be aware of this problem and be sure to include "-I/usr/src/LiS/include" in the compiler options that you use in compiling your STREAMS based applications.
In this version of LiS, some of the constants in stropts.h have been changed to conform to the values used by UnixWare and Solaris. These are different values than previously used in LiS. When you install LiS the installation procedure will ask you whether you want LiS compiled with the backward-compatible LiS constants, or the UnixWare/Solaris compatible constants. Logically speaking, it does not matter which set you use as long as LiS and your application code are both compiled with the same values.
I highly recommend that you use the UnixWare/Solaris compatible version, however. A future release of egcs, utilizing glibc 2.2, will contain an updated version of its stropts.h which has constants that are compatible with UnixWare, Solaris and LiS. So by selecting the UnixWare/Solaris compatible version at this time you can ensure that your applications will be fully compatible with these values in the future.
With any luck, these constants will never have to change again.
The second major compatibility issue concerns the major device numbers that LiS assigns to STREAMS devices. In the past LiS based these device numbers at 50, since the Linux kernel did not pre-define many major device numbers. As of kernel version 2.3.x there are major device numbers defined up to 220 and beyond! So starting with LiS-2.12, we have used the major number of 240 as the base for STREAMS device files. This range is supposed to be reserved for "experimental drivers" which should make it safe to use.
What this means is that you must be sure to run the strmakenodes program before running any STREAMS applications after installing LiS-2.12. This need not concern you overly, since doing a "make install" in the /usr/src/LiS directory causes strmakenodes to be run anyway. This is more a concern if you are compiling LiS on one machine and then loading it onto another for execution. In such cases you may need to load the new strmakenodes program and run it. I am hoping that the kernel developers will expand the major and minor device number spaces for 2.6. If they do that then LiS should be able to get a block of majors allocated to it.
For LiS version 2.5 and later and for kernel version 2.2.x there are no compatibility issues; there are no kernel patches whatsoever required to install LiS. You will need LiS-2.4 at minimum to run in a 2.2.x kernel.
The latest version of LiS has not been tested on 2.0 kernels. Therefore, do not be surprised if it does not install or execute correctly in these kernels. If you are using an old kernel, you must also use an older version of LiS, perhaps LiS-2.5.
For LiS version 2.5 and later and for kernel version 2.0.36 there are no kernel patches required to run LiS as a "bottom half" process. A one-line patch is required to run LiS as a kernel daemon process. The installation default is to run as a bottom half process in 2.0.36. LiS-1.25 or later should install properly with 2.0.36. The more recent the version of LiS, the less kernel patching is required.
Linux Fast-STREAMS provides a suitable replacement for the (now deprecated) Linux STREAMS (LiS) 2.18.0 package formerly maintained by Dave Goethe of GCOM.
There are several issues that needed to be addressed for compatibility with the 2.6 Linux kernel. You are encouraged to follow the links in the paragraphs below to see more detailed information on each of these topics.
LiS-2.16 is a small change from LiS-2.15. The change is that it no longer uses Linux system calls to implement getpmsg and putpmsg. Instead it overloads the read and write file system functions with particular values for the count parameter, values that are otherwise invalid.10
LiS-2.15 continues to insulate STREAMS drivers from the Linux kernel. It works with 2.2, 2.4, and 2.5 versions of the kernel. Support for 2.0 kernels has been dropped.
Driver writers will need to recompile their drivers against LiS-2.15 include files. You will see the following major changes.
There is one known bug in LiS-2.15 relative to 2.5 kernels. It has to do with a memory leak involving timer structures, and may prove to be a kernel bug rather than an LiS bug. Since the 2.5 kernel is not suitable for general use I am saving the investigation of this bug for later.
LiS-2.13 was a series of beta releases. LiS-2.14 represents the culmination of this series. There should be enough distribution and kernel compatibility that LiS-2.14 will hold up for some time.
The known fattach and FIFO bugs have still not been fixed. The author of those subsystems has not found the time to put in the fixes, nor have I.
This version of LiS has been tested with 2.4 kernels up to 2.4.16. LiS does not yet support the fattach/fdetach functions on kernel versions 2.4.7 and beyond. There are also known bugs in the LiS pipe/FIFO code. All of these problems are scheduled to be fixed in early 2002.
LiS-2.13 adds the ability for drivers to make their own "/dev" nodes via the lis_mknod function (see System Calls from within the Kernel). Also provided is an lis_unlink function that allows drivers to remove their device files.
There is almost no new functionality added by LiS-2.13. The differences between LiS-2.13 and LiS-2.12 are almost entirely kernel compatibility issues and bug fixes.
This version of LiS is compatible with all 2.2.x versions of the kernel and with early versions of the 2.4.x kernel, at least up to 2.4.2 and perhaps later versions as well.
If you have drivers that have worked with LiS-2.10 or LiS-2.11 (or earlier) please recompile them using the header files from LiS-2.12. This may be the last recompile in quite some time that you will need for your driver code.
LiS-2.12 contains a sufficient Driver/Kernel Interface (DKI), (see Development), that it is straightforward to write a STREAMS driver that can be compiled against LiS-2.12 and the resulting object modules used either on a 2.2 or 2.4 kernel, with only LiS needing recompilation on the target machine.
When run on 2.4 kernels, LiS makes full use of multiple CPUs (see LiS SMP Implementation). It forks a queue runner task for each CPU and locks each task onto its CPU. Queue runner tasks are awakened to assist with service procedure processing as the number of scheduled queues increases.
Because of this aggressive use of processors, you may find that your drivers do not function properly when run with LiS-2.12 in a multi-CPU SMP environment. You should expect that drivers that worked in single-CPU environments will continue to work as before.
Making your drivers MP safe involves the use of spin locks. The DKI documentation contains advice on the use of these locks. See LiS Spin Locks.
This version of LiS also contains a rewrite of the flushing code and tests added to strtst for flushing. In particular the details of the rules for flushing queue bands are now adhered to. See Flushing Queue Bands. Be advised, however, that Solaris STREAMS does not adhere strictly to these rules so there may be some subtle differences in behaviour between LiS and Solaris when flushing queue bands.
Speaking of queue bands, the queue band handling code has been debugged a bit more and a test added to strtst to illustrate its correct behaviour.
This version of LiS is compatible with all 2.2.x versions of the Linux kernel. It may work with 2.4.x kernels, but you should probably wait for LiS-2.11 for that.
If you have drivers that worked with LiS-2.8 or earlier, you must recompile your drivers in the context of the LiS-2.10 header files. The queue_t structure has changed in size since LiS-2.8 which means that the old RD and WR macros will not compute the correct addresses.
LiS-2.10 contains features that are intended to greatly reduce the necessity of recompiling STREAMS driver code in future versions of LiS or future versions of the kernel. The goal is to be able to compile STREAMS drivers against LiS-2.10 header files and use the resulting object code on both 2.2.x kernels and 2.4.x kernels.
For more details about the interface between STREAMS drivers and the kernel, see the Driver/Kernel Interface documentation, (see Development).
The Linux STREAMS (LiS) package is no longer receiving active development or support. The Linux STREAMS (LiS) package is so fraught with bugs that it is unusable as far as The OpenSS7 Project is concerned. Linux Fast-STREAMS is the preferred replacement for Linux STREAMS (LiS).
The sections that follow provide information on OpenSS7 releases of the
Linux STREAMS (LiS) package.
This is an internal release of LiS. It is only available for download by subscribers and sponsors of the OpenSS7 Project. There are too many packages that cannot build against LiS due to its implementation deficiencies.
Do not use this release (even if you are a subscriber or sponsor). Port to Linux Fast-STREAMS. Do not report bugs on this release. The OpenSS7 Project no longer actively maintains LiS.
Major features since the last public release are as follows:
This is an internal release of LiS. There are too many packages now that cannot build against LiS because it is lacking fundamental capabilities in the Stream head.
Do not use this release. Port to Linux Fast-STREAMS. Do not report bugs on this release. (Yup, there are lots of 'em, but that's LiS.)
Major features since the last public release are as follows:
This is the final release of LiS. There are too many packages now that cannot build against LiS because it is lacking fundamental capabilities in the Stream head.
This release builds both 32-bit compatibility and 64-bit native libraries and functions on 64-bit architectures. One of the major reasons for doing this for LiS was to demonstrate its sad lack of ability to sustain any form of 32-bit compatibility on most 64-bit architectures. Test suites now run first 64-bit native and then 32-bit compatibility tests to demonstrate LiS' dismal failure in this regard.
Do not use this release. Port to Linux Fast-STREAMS. Do not report bugs on this release. (Yup, there are lots of 'em, but that's LiS.)
Major features since the last public release are as follows:
ix86
as well as x86_64
. Added distribution support includes SLES 9,
SLES 9 SP2, SLES 9 SP3, SLES 10, SuSE 10.1.
LiS is really not supported any longer. Use Linux Fast-STREAMS instead. The purpose of this release is to demonstrate the inability of the LiS package to properly support 32-bit compatibility on 64-bit architectures.
ix86
as well as x86_64
. Added distribution
support includes SLES 9, SLES 9 SP2, SLES 9 SP3,
SLES 10, SuSE 10.1.
− | Remove -fno-reorder-blocks and
-fno-reorder-functions options added by some recent 2.6
Makefiles for `x86_64' architecture: it impedes performance
optimizations.
|
− | Remove -ffunction-sections option added by some
recent 2.6 Makefiles for `x86_64' architecture: this is an
insane option and should never have been used.
|
− | Add -ffreestanding that some older 2.6
Makefiles (such as that with SLES 9 2.6.5 kernel) neglect to add
to the gcc command line.
|
− | SLES 10 expands the directory before
autoconf.h on the gcc command line for some reason.
configure script watches out for this now.
|
This was an internal alpha test release candidate and was not released publicly. This release was only available to subscribers to and sponsors of the OpenSS7 Project.
This was an internal alpha test release candidate and was not released publicly. This release was only available to subscribers to and sponsors of the OpenSS7 Project.
This was an internal alpha test release candidate and was not released publicly. This release was only available to subscribers to and sponsors of the OpenSS7 Project.
Corrections for and testing of 64-bit clean compile and test runs on x86_64 architecture. Some bug corrections resulting from gcc 4.0.2 compiler warnings.
Corrected build flags for Gentoo and 2.6.15 kernels as reported on mailing list. Builds on FC4 2.6.15 kernel and with gcc 4.0.2.
Added in many of Paul's 64-bit corrections.
The Linux STREAMS (LiS) 2.18.3 is still largely unusable on 64-bit or SMP kernels. Linux STREAMS (LiS) package is deprecated. Do not use it. The package contains many unresovled bugs. Use Linux Fast-STREAMS instead.
Cross-build support for newer NexusWare releases. Build support for (recent FC4) 2.6.14 kernel. Corrected installation support (init scripts) for SuSE 9.2.
Binary compatibility backward compatible to GCOM 2.18.0 included. This
includes exported symbols changed to not generate version symbols on 2.4
kernels. Also, exported symbols are always compiled
attribute((regparm(0)))
on regparm capable architectures, regardless of
the kernel version or compile options.11 For actual binary compatibility packaging, see the strcompat
package.
A major change for 2.18.2 is the port-back of POSIX/SUSv3 XSR/XSI conformance test suites and performance programs from Linux Fast-STREAMS. The purpose of porting back theses tests suites and supporting modules and drivers is to provide the ability to do comparison tests between LiS and Linux Fast-STREAMS.
Another change is a module unloading safe vstrlog hook register and unregister functions register_strlog() and unregister_strlog().
Some bug corrections and fixes for glaring SMP errors reported by Kutluck.
This might be the last OpenSS7 release of Linux STREAMS (LiS). You should seriously consider using the Linux Fast-STREAMS package (streams-0.7a.4 or later) instead. If you need compatibility to LiS (or other STREAMS implementation), investigate the strcompat package, which provides some binary compatibility to LiS under Linux Fast STREAMS.
Initial autoconf/RPM packaging of the LiS release.
This is a port forward of most of the build and patches from 2.16.19 forward and applied over 2.18.0. This is our first LiS-2.18 release. All further development on 2.16.19 will now cease. 2.18.1 is maintained on both 2.4 and 2.6 kernels. No active development will be performed on 2.18.1, only maintenance. For an active development release, see the Linux Fast-STREAMS releases.
Major changes from LiS-2.18.0 include all of the autoconf build system, manual pages and texi/pdf manual for LiS that were applied on the 2.16.19 release. This includes a number of 64 bit, HPPA, PARISC, printf, atomic stats, HZ calculations for 64bit machines, DMA patch for mblk buffer alignment, flush handling patch, panic patch, smp patch, parisc syscall patch, appq patch, and multi-threaded test program patches, POSIX threads compliant library functions.
Additional changes made to support later 2.6 kernels and distributions. Switched putpmsg()/getpmsg() to use ioctl for system call emulation instead of read()/write(), primarily because 2.6.11 kernels check for a valid count before calling the driver's read()/write() file operations. Updates to the build system to support a wider range of kernels and distributions. See the installation and reference manual for a complete list of supported kernels and distributions.
Please note that the entire package is released under GPL.
Replaced m4 and automake files with common equivalents. This allows the same set of m4 macros and automake fragments to be used with all of the OpenSS7 release packages. Maintenance is easier as one correction will propagate across all items. Performed similar function with texinfo documentation pieces.
Removed all XTI/TLI and Linux networking code, headers and documentation from LiS distribution and bumped epoch to 2. Linux networking code has been migrated to the strxns, strxnet, strinet and strsctp packages. The purpose for doing this was to allow the Linux networking to build against Linux Fast-STREAMS as well as Linux STREAMS (LiS) and is a preparation for phasing out LiS and phasing in LfS.
Added missing configure.nexusware to distribution. LiS cache options now default to 'no' because of instabilities with timers.
Not publicly released.
Minor corrections: made conflicting manpage xti_sctp.3 dependent on OpenSS7 SCTP kernel.
Not publicly released.
Changes to compile, install and builds rpms for Fedora Core 1 (FC1), Whitebox Enterprise Linux (WBEL) and RedHat Enterprise Linux 3 (EL3). Included explicit epoch in internal dependencies in spec file for RPM versions 4.2.1, 4.2.2 and higher. Added hugemem kernel detection and moved getpmsg and putpmsg manual pages.
Correction to symbolic linking and system map file location during non-rpm autoconf installation.
Correction to zero maxlen
behaviour in t_rcvconnect()
.
Added check for CONFIG_REGPARM
, addition of -mregparm=3
CFLAGS
, addition of regparm_
prefix for exported ksyms.
Minor corrections to separate build directory install of devices and caching of detected ksyms.
Added option --disable-k-modversions
to suppress versions for LiS
exported symbols.
A couple of corrections to the build process reported by Gurol. Changed order of build in `make rebuild' target to build tools last so that the rpm debug package is built correctly on RH9.
Change MODULE_PARM
to static so that make install-strip
does not
strip module parameter symbols.
Added lis_check_mem_region()
, lis_release_mem_region()
and
lis_request_mem_region()
for memory mapped io instead of just io.
Added printk
patches discussed on linux-stream mailing list. Added
gcc printf
checking and corrected errors in LiS debugging printk
statements.
Added HP patches. There are a couple of questionable components in the HP patches that I reversed. They include;
lis_msgsize
to lis_msgdsize
. This would change
the calculation of queue counts. Queue counts aren't M_DATA
counts,
they are "data" message counts. LiS probably doesn't have this the right way,
but lis_msgdsize
is not correct either.
qi_mstat->ms_pcnt
increment on lis_safe_putmsg
.
Same for ms_scnt
, ms_ocnt
, ms_ccnt
. STREAMS is not
supposed to increment counts. It is the module writer's responsibility to
increment counts in their own queue procedures.
Added HP ldl
patches.
Made modifications to putq()
, putbq()
, insq()
and
appq()
discussed on linux-streams mailing list. These do not free
messages on failure. Modified all occurrences internal to LiS to free the
message on error to ensure old behaviour.
Added HP dejagnu patches to strtst
and added dejagnu testsuite
directory and file. Added the make check
target. Use DEJATOOLS
on the make command line to invoke the tests, such as `make
DEJATOOLS=strtst check
' to invoke the tests. Because a patched
netperf
is not commonly available and netperf
will not be
distributed with the package, GNU autotest
might be a better choice.
But that's for a later release.
General updates to the build process, optimization options, build options. Corrected library linkage. Synced TLI modules and INET driver to Linux Fast-STREAMS. Removed deadlock from INET driver and loosened locking. Unfortunately suitable libraries must be installed before distcheck will clear.
Smoother and more reliable stripping of kernel symbols, starts with /proc/ksyms if applicable then System.map then modversions.h to attempt to choose symbols most closely synced with an installed or running kernel.
Improvements to autoconf installation of manpages (autocompressed now) and info and pdf manuals are distributed. install-strip target will actually properly strip kernel modules.
Included an option to build and install only kernel or user parts of package to speed rpm rebuild process for multiple kernel. Added `rebuild' target to rebuild the rpms from srpm for multiple kernel and architectures. Added a `sign' and `resign' target to sign srpm and rebuilt rpms respectively.
Greatly enhanced cross-build and cross-compile support, primarily in support of the NexusWare embedded target. Added NexusWare helper script and documentation. DESTDIR is now a blessed environment variable used by configure to set the cross-build root as well as the install root. Try adding –with-k-optimize='size' to configure to optimize for size for embedded targets. Builds clean against NexusWare24 (810p0674.10-rc4).
Added start of an option to build as linkable object for embedded targets rather than loadable kernel module.
Fixed several symbol errors that made -13 and -14 unusable. Corrected error in calculation of kernel debug flags.
A few more enhancements to the build process to work with autoconf 2.59.
Enhanced build process for autoconf-2.59, automake-1.8.3, gettext-0.14.1, and libtool-1.5.6.
Added defaults for SK_WMEM_MAX and SK_RMEM_MAX for lastest 2.4.25 and 2.4.26 kernel builds.
Enhanced build process.
All kernel symbols exported by LiS have versions on kernels that have versions on symbols. This makes it safer to compile kernel modules against kernel/LiS combinations. This is in preparation for splitting off the strxnet package, and the technique was imported from the Linux Fast-STREAMS build.
Ripped three additional kernel symbols in support of INET driver that were missing in -10 release.
Added support for cooked manpages both for non-rpm systems and for rpm systems. It is still better to leave manpages uncooked for rpm releases because they are much smaller that way. Give the –with-cooked-manpages flag to configure if you want cooked manpages. You still need grefer on the build system.
Updates to all manual pages in man7, and some others (xti) in man3. Removed unused .macros and .refs files.
Moved automake fragments into separate directory. Cleaned up automake fragments.
Rearranged header files in the xti subdirectory to install in LiS package include directory instead. Reworked xti, tihdr and tiuser file groups to include properly from kernel or user space independent of order. tiuser and xti still cannot be included together. Added older TLI interface <tiuser.h> that is still consistent with newer XTI interface. Changed references in man pages to XTI/TLI instead of just XTI.
Added ticlts.h, ticots.h and ticotsord.h header files. Updated dlpi.h and npi.h header files. Removed sys/LiS/tpicommon.h because it is largely replaced by sys/tli.h and sys/tpi.h. Removed the, now redundant, xti header file subdirectory.
A series of bug fixes to xnet.c (libxnet) that resulted from discussions with Gurol Akman on openss7-develop mailing list. Mostly surrounding t_alloc and t_getinfo behaviour and the behaviour when NULL pointers are passed to various XTI/TLI library calls. Updated xti documentation as well.
Many changes to the inet.c INET driver. Wildcard IP addresses can now be bound and wildcard addresses will be assigned with no address is passed to most providers. (/dev/rawip still requires an address or TNOADDR is returned.) Option management has been extensively rewritten to closer conform to XNS documentation. Test programs test-inet_raw, test-inet_udp, test-inet_tcp have been upgraded and converted to multiple child processes. A number of fixes to SMP lock behaviour and M_FLUSH have been added as reported by Dave Grothe. Corrected all level and TBADOPT behaviour on negotiation.
Although this driver is now closer to expected behaviour, it has not been tested for XNS 5.2 compliance, nor will it be until someone has the time to extend the test programs to handle all test cases in a similar manner as was done for the library. Your mileage many vary. Remember, there is no warranty.
Changes primarily in support of builds on HPPA (PARISC) architectures. LiS doesn't build too well on PARISC so some modifications where used from the Linux Fast-STREAMS package to correct deficiencies. Better building on recent 2.4 kernels (2.4.23, 2.4.24, 2.4.25) is also provided.
Changes to permit better builds on recent RedHat kernels, and especially kernel-2.4.20-30.9.
Fixed a module loading bug in LiS. Previously modules would not demand load.
Fixed a possible null pointer dereference in libxnet. Corrected t_bind to return TNOADDR instead of TBADADDR on wildcard bind attempt. Module loading bug patched.
Fixes a t_open and t_bind problem in libxnet. Fixes alignment of data portion of mblks. Adds (untested) ticots_ord, ticots and ticlts devices over UNIX domain sockets.
Adds back in missing strms_up/down/status scripts to distribution and install.
This OpenSS7 release of LiS-2.16.18 updates the previous LiS-2.16.16 rpm release to the latest LiS-2.16 release level.
This OpenSS7 release of LiS-2.16.16 includes autoconf for configuration, complete manual pages and documentation, and packaging in source and binary RPMs for ease and repeatability of installation. The package also builds and installs properly versions LiS shared object libraries.
Before the OpenSS7 release of LiS, it was necessary to have a significant working knowledge of the Linux kernel, kernel source, headers and other intricacies. This made it difficult to distribute software based on LiS to users not proficient in those areas. The OpenSS7 release removes the configuration and installation tasks from the user and permits distribution of applications, modules and driver software based on LiS to users without sufficient kernel expertise to install the package.
This OpenSS7 release fixes few of the outstanding bugs and deficiencies of the LiS software. This release is intended to package and distribute LiS in an efficient manner and, for the most part, does not address LiS deficiencies or errors.
This OpenSS7 release is compatible with Linux 2.4 kernels only and will refuse to configure for older or newer kernels.
Following are the new features of the OpenSS7 release of LiS:
These tools greatly enhance the ability to maintain a repeatable and testable release cycle as well as being compatible with most major package managers such as Redhat's RPM.
This change was necessitated because we use GNITS (the strictest level) of configuration with autoconf that requires for distribution checking that all utility programs support the `--help' and `--version' long options without side-effects.
Use of the RPM mechanism for release permits add-on packages to ensure that they have sufficient level of support and versions for the LiS load during their build and installation process. It is now also possible to ensure that add on binaries are compatible with a loaded LiS during installation.
tirdwr
and timod
modules for use with the
included XTI/TLI library.12
The next release may include some strss7 software.
The OpenSS7 Project adheres to the following release philosophy:
Pre-alpha releases are releases that have received no testing whatsoever. Code in the release is not even known to configure or compile. The purpose of a pre-alpha release is to make code and documentation available for inspection only, and to solicit comments on the design approach or other characteristics of the software package.
Pre-alpha release packages ship containing warnings recommending that the user not even execute the contained code.
Alpha release are releases that have received little to no testing, or that have been tested and contains known bugs or defects that make the package unsuitable even for testing. The purpose for an alpha release are the same as for the pre-alpha release, with the additional purpose that it is an early release of partially functional code that has problems that an external developer might be willing to fix themselves and contribute back to the project.
Alpha release packages ship containing warnings that executing the code can crash machines and might possibly do damage to systems upon which it is executed.
Beta releases are releases that have received some testing, but the testing to date is not exhaustive. Beta release packages do not ship with known defects. All known defects are resolved before distribution; however, as exhaustive testing has not been performed, unknown defects may exist. The purpose for a beta release is to provide a baseline for other organizations to participate in the rigorous testing of the package.
Beta release packages ship containing warnings that the package has not been exhaustively tested and that the package may cause systems to crash. Suitability of software in this category for production use is not advised by the project; however, as always, is at the discretion of the user of the software.
Gamma release are releases that have received exhaustive testing within the project, but external testing has been minimal. Gamma release packages do not ship with known defects. As exhaustive internal testing has been performed, unknown defects should be few. Please remember that there is NO WARRANTY on public release packages.
Gamma release packages typically resolve problems in previous beta releases, and might not have had full regression testing performed. Suitability of software in this category for production use is at the discretion of the user of the software. The OpenSS7 Project recommends that the complete validation test suites provided with the package be performed and pass on target systems before considering production use.
Production releases are releases that have received exhaustive testing within the project and validated on specific distributions and architectures. Production release packages do not ship with known defects. Please remember that there is NO WARRANTY on public release packages.
Production packages ship containing a list of validated distributions and architectures. Full regression testing of any maintenance changes is performed. Suitability of software in this category for production use on the specified target distributions and architectures is at the discretion of the user. It should not be necessary to preform validation tests on the set of supported target systems before considering production use.
Unstable releases are releases that have received extensive testing within the project and validated on a a wide range of distributions and architectures; however, is has tested unstable and found to be suffering from critical problems and issues that cannot be resolved. Maintenance of the package has proved impossible. Unstable release packages ship with known defects (and loud warnings). Suitability of software in this category for production use is at the discretion of the user of the software. The OpenSS7 Project recommends that the problems and issues be closely examined before this software is used even in a non-production environment. Each failing test scenario should be completely avoided by the application. OpenSS7 beta software is more stable that software in this category.
Linux STREAMS (LiS) has many and critical known defects. This is an unstable release. Some defects could be harmful. Validation testing has been performed by the OpenSS7 Project on this software and it has revealed itself to be unstable and irreparable. The software might not even configure or compile. The OpenSS7 Project recommends that you do not use this software. Use at your own risk. Remember that there is NO WARRANTY.13
Linux STREAMS (LiS), both releases from OpenSS7 and GCOM, contain many known bugs. These are unstable releases. Although there are no bugs known directly to be harmful, the OpenSS7 Project has tested the release and found defects that cause the kernel to lock or crash. Use at your own risk. Remember that there is NO WARRANTY14 and that the package is no longer actively maintained.
This software is unstable software. As such, it will lock or crash your kernel. Installation of the software will irreparably mangle your header files or Linux distribution in such a way as to make it unusable. Crashes will lock your system and rebooting the system will not repair the problem. You will loose all the data on your system. Because this software has tested unstable in a number of test cases, simply running the validation test cases can cause locks or crashes. Because this software will lock or crash your kernel, the resulting unstable system can destroy computer hardware or You will void the warranty on any system on which you run this software. YOU HAVE BEEN WARNED.
With the exception of packages not originally created by the OpenSS7 Project, the OpenSS7 Project software does not ship with known bugs in any release stage except pre-alpha. Linux STREAMS (LiS) had many known bugs at the time of release.
Linux STREAMS (LiS) has many known bugs. Under some architectures, the test cases in the conformance test suite cause the kernel to lock or crash. Linux STREAMS (LiS) contains many races and defects and is unsuitable for production environments. This section provides a summary of some (but not all) known defects.
As a result, any test case that pushes a number of modules, and the performance tests (that push modules for measurement) will cause the kernel to lock.
The work-around for these defects is to not use LiS at all: use the OpenSS7 Linux Fast-STREAMS release instead. The OpenSS7 Linux Fast-STREAMS, being a completely independent implementation, does not suffer from this extensive set of LiS defects.
This section contains historical bugs that were encountered during development and their resolutions. This list serves two purposes:
LiS contains way too many bugs to be useful. This list only represents those bugs that were discovered in the development of Linux Fast-STREAMS that were easy enough to fix in LiS.
Do not use LiS. Use Linux Fast-STREAMS instead.
001. 2006-09-24T20:02:00+0000
*fixed* in LiS-2.18.4.rc3
The OpenSS7 release of Linux STREAMS (LiS) was in maintenance mode for over a year and the latest `2.18' releases are quite stable. However, LiS is fraught with bugs and suffers from a poor design approach making it unsuitable for production use. It fails many of the conformance test cases in the test suite and even locks the kernel on a number of cases on `SMP' kernels regardless of their being run on a `UP' machine.
The OpenSS7 Project wrote a new STREAMS package for Linux called Linux Fast-STREAMS. Linux Fast-STREAMS is now far more stable than LiS, and The OpenSS7 Project will no longer perform development on the LiS package, unless at the bequest of a project sponsor. As such, LiS is deprecated. Use the latest streams-0.9.2.3 package from the OpenSS7 download site instead.
Things to do:
*done*
For the latest developments with regard to history of changes, please see the ChangeLog file in the release package.
The Linux STREAMS (LiS) package releases can be downloaded from the downloads page of The OpenSS7 Project. The package is available as a binary RPM (for popular architectures) a source RPM, Debian binary DEB and source DSC, or as a tar ball. If you are using a browsable viewer, you can obtain the OpenSS7 release of LiS from the links in the sections that follow.
By far the easiest (most repeatable and manageable) form for installing and using OpenSS7
packages is to download and install individual packages from binary RPM or DEB. If binary RPMs or
DEBs are not available for your distribution, but your distribution supports rpm(1)
or
dpkg(1)
, the next best method for installing and using OpenSS7 packages is to
download and rebuild the source RPMs or DSCs.
If your architecture does not support rpm(1) or dpkg(1) at all, or you have special needs (such as cross-compiling for embedded targets), the final resort method is to download, configure, build and install from tarball. In this later case, the easiest way to build and install OpenSS7 packages from tarball is to use the tarball for the OpenSS7 Master Package, openss7-0.9.2.F.
To install from binary RPM, you will need several of the RPM for a complete installation. Binary RPM fall into several categories. To download and install a complete package requires the appropriate RPM from each of the several categories below, as applicable. Some release packages do not provide RPMs in each of the several categories.
To install from Binary RPM, you will need all of the following kernel independent packages for your architecture, and one of the kernel-dependent packages from the next section.
Independent RPM are not dependent on the Linux kernel version. For example, the source package `LiS-source-2.18.6-1.7.2.noarch.rpm', is not dependent on kernel.
All of the following kernel independent RPM are required for your architecture. Binary RPMs listed here are for example only: additional binary RPMs are available from the downloads site. If your architecture is not available, you can build binary RPM from the source RPM (see see Building from the Source RPM).
Kernel-Dependent RPM are dependent on specific Linux Kernel Binary RPM releases. Packages are provided for popular released RedHat kernels. Packages dependent upon RedHat or other kernel RPM will have the `_kversion' kernel package version in the package name.
One of the following Kernel-Dependent packages is required for your architecture and kernel version. If your architecture or kernel version is not on the list, you can build binary RPM from the source RPM (see see Building from the Source RPM).16
To configure, build and install the binary RPM, See Configuring the Binary RPM.
To install from binary DEB, you will need several of the DEB for a complete installation. Binary DEB fall into several categories. To download and install a complete package requires the appropriate DEB from each of the several categories below, as applicable. Some release packages do not provide DEBs in each of the several categories.
To install from Binary DEB, you will need all of the following kernel independent packages for your architecture, and one of the kernel-dependent packages from the next section.
Independent DEB are not dependent on the Linux kernel version. For example, the source package `LiS-source_2.18.6-0_i386.deb', is not dependent on kernel.
All of the following kernel independent DEB are required for your architecture. Binary DEBs listed here are for example only: additional binary DEBs are available from the downloads site. If your architecture is not available, you can build binary DEB from the Debian DSC (see see Building from the Debian DSC).
Kernel-Dependent DEB are dependent on specific Linux Kernel Binary DEB releases. Packages are provided for popular released Debian kernels. Packages dependent upon Debian or other kernel DEB will have the `_kversion' kernel package version in the package name.
One of the following Kernel-Dependent packages is required for your architecture and kernel version. If your architecture or kernel version is not on the list, you can build binary DEB from the source DEB (see see Building from the Debian DSC).22
To configure, build and install the Debian DEB, See Configuring the Debian DEB.
If you cannot obtain a binary RPM for your architecture, or would like to roll you own binary RPM, download the following source RPM.
To configure the source RPM, See Configuring the Source RPM.
If you cannot obtain a binary DEB for your architecture, or would like to roll your own DEB, download the following Debian DSC.
To configure the source RPM, See Configuring the Debian DSC.
For non-rpm(1) architectures, such as NexusWare embedded target, download the tarball as follows:
The tar ball may be downloaded easily with wget(1) as follows:
% wget http://www.openss7.org/LiS-2.18.6.tar.bz2 |
or
% wget http://www.openss7.org/LiS-2.18.6.tar.gz |
Note that you will need an OpenSS7 Project user name and password to download release candidates (which are only available to subscribers and sponsors of the OpenSS7 Project).
After downloading one of the tar balls, unpack the archive using one of the following commands:
% wget http://www.openss7.org/LiS-2.18.6.tar.gz % tar -xzvf LiS-2.18.6.tar.gz |
or
% wget http://www.openss7.org/LiS-2.18.6.tar.bz2 % tar -xjvf LiS-2.18.6.tar.bz2 |
Either will create a subdirectory name LiS-2.18.6 containing all of the files and subdirectories for the LiS package.
To configure and install the tar ball, See Configuring the Tar Ball.
If you are a subscriber or sponsor of The OpenSS7 Project with CVS archive access privileges then you can download release, mid-release or release candidate versions of the LiS package from the project CVS archive.
The Linux STREAMS (LiS) package is located in the LiS module of /var/cvs. For release tag information, see Releases.
To access the archive from the project CVS pserver, use the following commands to check out a version from the archive:
% export CVSROOT='-d:pserver:username@cvs.openss7.com:2401/var/cvs' % cvs login Password: ********* % cvs co -r LiS_2.18.6 LiS % cvs logout |
It is, of course, possible to check out by date or by other criteria. For more information, see
cvs(1)
.
Although public releases of the LiS package do not require reconfiguration, creating a configurable directory from the CVS archive requires tools not normally distributed with the other releases.
The build host requires the following GNU tools:
These tools can be acquired from the FSF website in the free software directory, and also at the following locations:
It should be stressed that, in particular, the autoconf(1), and automake(1), must be at version releases 2.61 and 1.10. The versions normally distributed in some mainstream GNU/Linux distributions are, in fact, much older than these versions.26 GNU version of these packages configured and installed to default directories will install in /usr/local/ allowing them to coexist with distribution installed versions.
For building documentation, the build host also requires the following documentation tools:
Most desktop GNU/Linux distributions will have these tools; however, some server-style installations (e.g. Ubuntu-server or SLES 9) will not and they must be installed separately.
For uncooked manual pages, the entire groff(1) package is required on Debian and Ubuntu systems (the base package does not include grefer(1) which is used extensively by uncooked manual pages). The following will get what you need:
Debian: % apt-get install groff_ext Ubuntu: % apt-get install groff |
In addition, the build host requires a complete tool chain for compiling for the target host,
including kernel tools such as genksyms(8)
and others.
If you wish to package rpms on an rpm(1) system, or debs on a dpkg(1) system, you will need the appropriate tool chain. Systems based on rpm(1) typically have the necessary tool chain available, however, dpkg(1) systems do not. The following on a Debian or Ubuntu system will get what you need:
% apt-get install debhelper % apt-get install fakeroot |
To generate a configuration script and the necessary scriptlets required by the GNU autoconf(1) system, execute the following commands on the working directory:
% autoreconf -fiv LiS |
where, LiS is the name of the directory to where the working copy was checked out under the previous step. This command generates the configure script and other missing pieces that are normally distributed with the release Tar Balls, SRPMs and DSCs.
Make sure that `autoreconf --version' returns `2.61'. Otherwise, you may need to perform something like the following:
% PATH="/usr/local/bin:$PATH" % autoreconf -fiv LiS |
After reconfiguring the directory, the package can then be configured and built using the same instructions as are used for the Tar Ball, see Configuring the Tar Ball, and Building from the Tar Ball.
Do note, however, that make(1) will rebuild the documentation that is normally released with the package. Additional tools may be necessary for building the documentation. To avoid building and installing the documentation, use the --disable-devel option to configure described in Configuring the Tar Ball.
When configuring the package in a working directory and while working a change-compile-test cycle that involves configuration macros or documentation, I find it of great advantage to invoke the GNU configure options --enable-maintainer-mode, --enable-dependency-tracking and --disable-devel. The first of these three options will add maintainer-specific targets to any generated Makefile, the second option will invoke automatic dependency tracking within the Makefile so rebuilds after changes to macro, source or documentation files will be automatically rebuilt; and the last option will suppress rebuilding and reinstalling documentation manual pages and header files. Header files will still be available under the /usr/src directory.
In general the binary RPM do not require any configuration, however, during installation it is possible to relocate some of the installation directories. This allows some degree of customization. Relocations that are available on the binary RPM are as follows:
To install the binary RPM, See Installing the Binary RPM.
In general the binary DEB do not require any configuration.
To install the Debian DEB, See Installing the Debian DEB.
When building from the source RPM (see Building from the Source RPM), the rebuild process uses a
number of macros from the user's .rpmmacros file as described in rpm(8)
.
Following is an example of the ~/.rpmmacros file that I use for rebuilding RPMS:
# # RPM macros for building rpms # %_topdir /usr/src/openss7.rpms %vendor OpenSS7 Corporation %distribution OpenSS7 %disturl http://www.openss7.org/ %packager Brian Bidulock <bidulock@openss7.org> %url http://www.openss7.org/ %_signature gpg %_gpg_path /home/brian/.gnupg %_gpg_name openss7@openss7.org %_gpgbin /usr/bin/gpg %_source_payload w9.bzdio %_binary_payload w9.bzdio %_unpackaged_files_terminate_build 1 %_missing_doc_files_terminate_build 1 %_enable_debug_packages 1 # # Template for debug information sub-package. # with our little addition of release # %debug_package \ %ifnarch noarch\ %global __debug_package 1\ %package debug\ Summary: Debug information for package %{name}\ Group: Development/Debug\ AutoReqProv: 0\ %{?fullrelease:Release: %{fullrelease}}\ %description debug\ This package provides debug information for package %{name}.\ Debug information is useful when developing applications that use this\ package or when debugging this package.\ %files debug -f debugfiles.list\ %defattr(-,root,root)\ %endif\ %{nil} |
When building from the source RPM (see Building from the Source RPM), it is possible to pass a number of additional configuration options to the rpmbuild(1) process.
The additional configuration options are described below.
Note that distributions that use older versions of rpm do not have the --with or --without options defined. To achieve the same effect as:
--with someparm=somearg
do:
--define "_with_someparm --with-someparm=somearg"
--define "_kversion $PACKAGE_KVERSION"
--with checks
--without checks
--with k-optimize=HOW
--without k-optimize
-Os
, speed compiles kernel modules -O3
, and quick
compiles kernel modules -O0
. The default is normal. Use with care.
--with cooked-manpages
--without cooked-manpages
--with public
--without public
--with k-debug
--without k-debug
test
and safe
below. This has the effect of removing static and inline
attributes from functions and invoking all debugging macros in the code. The default is to not
perform kernel debugging.
--with k-test
--without k-test
debug
above and
safe
below. This has the effect of removing static and inline attributes from functions and
invoking most debugging macros in the code. The default is to not perform kernel testing.
--with k-safe
--without k-safe
debug
and
test
above. This has the effect of invoking some more pedantic assertion macros in the code.
The default is not to apply kernel safety.
--with k-inline
--without k-inline
inline
functions are to be placed inline. This has the effect of
adding the -finline-functions flag to CFLAGS for compiling kernel modules. Linux 2.4
kernels are normally compiled -O2 which does not respect the inline
directive. This
compiles kernel modules with -finline-functions to get closer to -O3 optimization.
For better optimization controls, See Configuring the Tar Ball.
--with k-modversions
--without k-modversions
--with devfs
--without devfs
--with devel
--without devel
--with tools
--without tools
--with modules
--without modules
In addition, the following rpm options, specific to the Linux STREAMS (LiS) package are available:
int
instead of long
interrupt flags. Linux uses long
interrupt flags
exclusively. The default is to use long
interrupt flags. This option defaults to
`disabled'.
atomic_t
element types for elements of the module_stat
structure instead of
int
element types. The default is to use int
elements types for the
module_stat
structure. This option defaults to `disabled'.
cmn_err
is used. The Solaris style prints a newline at the
end of each statement. The SVR 4.2 style prints a newline at the beginning of each statement unless
CE_CONT
is specified. Linux kernel logs use the former, so this defaults to Solaris-style.
This option defaults to `enabled'.
In general, the default values of these options are sufficient for most purposes and no options need be provided when rebuilding the Source RPMs.
To build from the source RPM, See Building from the Source RPM.
The Debian DSC can be configured by passing options in the environment variable BUILD_DEBOPTIONS. The options placed in this variable take the same form as those passed to the configure script, See Configuring the Tar Ball. For an example, See Building from the Debian DSC.
To build from the Debian DSC, See Building from the Debian DSC.
All of the normal GNU autoconf(1) configuration options and environment variables apply. Additional options and environment variables are provided to tailor or customize the build and are described below.
Following are the additional configure options, their meaning and use:
Although the default is to install init scripts, installation attempts to detect a System V init script configuration, and if one is not found, the init scripts are installed into the appropriate directories, but the symbolic links to the run level script directories are not generated and the script is not invoked. Therefore, it is safe to leave this option unchanged, even on distributions that do not support System V init script layout (such as NexusWare).
static
and inline
attributes from functions and
invoking most non-performance affecting debugging macros in the code. The default is not to perform
kernel testing.
static
and inline
attributes from functions and
invoking all debugging macros in the code (including performance-affecting debug macros). The
default is to not perform kernel debugging.
gpg(1)
`GNUPGUSER' for signing RPMs and tarballs. The default is the
content of the environment variable GNUPGUSER. If unspecified, the gpg(1) program
will normally use the user name of the account invoking the gpg(1) program. For building
source RPMs, the RPM macro `_gpg_name' will override this setting.
-Os
, speed compiles kernel modules -O3
, and quick
compiles kernel modules -O0
. The default is normal. Use with care. The most common
use of this option is to specify --with-k-optimize=speed --disable-k-safe to compile for
maximum performance. Nevertheless, even these setting are ricing and the resulting kernel
modules will only be about 5% faster.
In addition, the following configure options, specific to the Linux STREAMS (LiS) package are available:
int
instead of long
interrupt flags. Linux uses long
interrupt flags
exclusively. The default is to use long
interrupt flags.
This option defaults to `disabled'.
int
to atomic_t
to permit atomic increment of statistics structures.
This is not recommended and the default is to not use atomic_t
for statistics
structures. This option defaults to `disabled'.
cmn_err
is used. The Solaris style prints a newline at the
end of each statement. The SVR 4.2 style prints a newline at the beginning of each statement unless
CE_CONT
is specified. Linux kernel logs use the former, so this defaults to Solaris-style.
This option defaults to `enabled'.
Following are additional environment variables to configure, their meaning and use:
soelim(1)
. This is only necessary when the option
--with-cooked-manpages has been specified and configure cannot find the proper
soelim(1) command. By default, configure will search for this tool.
refer(1)
. This is only necessary when the option
--with-cooked-manpages has been specified and configure cannot find the proper
refer(1) command. By default, configure will search for this tool.
tbl(1)
. This is only necessary when the option
--with-cooked-manpages has been specified and configure cannot find the proper
tbl(1) command. By default, configure will search for this tool.
pic(1)
. This is only necessary when the option
--with-cooked-manpages has been specified and configure cannot find the proper
pic(1) command. By default, configure will search for this tool.
gzip(1)
. This is only necessary when
the option --without-compressed-manpages has not been specified and
configure cannot find the proper gzip(1) command. By default,
configure will search for this tool.
bzip2(1)
. This is only necessary when the option
--without-compressed-manpages has not been specified and configure cannot
find the proper bzip2(1) command. By default, configure will search for this
tool.
makewhatis(8)
. By default, configure
will search for this tool. By default, configure will search for this tool.
chkconfig(8)
. This was used for installation of init scripts. All
packages now come with init_install(8) and init_remove(8) scripts used to install and
remove init scripts on both RPM and Debian systems.
rpm(1)
. This is only necessary for RPM builds. By default,
configure will search for this tool.
rpmbuild(1)
. This is only necessary for RPM builds. By default,
configure will search for this tool. rpm(1) will be used instead of
rpmbuild(1) only if rpmbuild(1) cannot be found.
dpkg(1)
. This command is used for building Debian packages. By default,
configure will search for this tool.
dpkg-source(1)
. This command is used for building Debian dsc
packages. By default, configure will search for this tool.
dpkg-buildpackage(1)
. This command is used for building Debian
deb packages. By default, configure will search for this tool.
ldconfig(8)
. Command used to configure the loader when libraries
are installed. By default, configure will search for this tool.
depmod(8)
. This is used during installation of
kernel modules to a running kernel to rebuild the modules dependency database. By default,
configure will search for this tool.
modprobe(8)
. This is used during installation of
kernel modules to a running kernel to remove old modules. By default, configure will
search for this tool.
lsmod(8)
. This is used during installation of kernel modules
to a running kernel to detect old modules for removal. By default, configure will search
for this tool.
lsof(1)
. This is used during installation of kernel modules to a
running kernel to detect old modules for removal. Processes owning the old kernel modules will be
killed and the module removed. If the process restarts, the new module will be demand loaded. By
default, configure will search for this tool.
genksyms(8)
. This is used for generating module symbol
versions during build. By default, configure will search for this tool.
genksyms(8)
. This is used for generating module
symbol version during build. By default, configure will search for this tool.
objdump(1)
. This is used for listing information about object
files. By default, configure will search for this tool.
nm(1)
. This is used for listing information about object
files. By default, configure will search for this tool.
autom4te(1)
. This is the executable used by autotest for pre- and
post-installation checks. By default, configure will search for this tool.
To build from the tar ball, See Building from the Tar Ball.
If you have downloaded the necessary source RPM (see Downloading the Source RPM), then the following instructions will rebuild the binary RPMs on your system. Once the binary RPMs are rebuilt, you may install them as described above (see Installing the Binary RPM).
The source RPM is rebuilt to binary RPMs as follows:
% wget http://www.openss7.org/rpms/SRPMS/LiS-2.18.6-1.src.rpm % rpmbuild --rebuild -vv LiS-2.18.6-1.src.rpm |
The rebuild process can also recognize a number of options that can be used to tweak the resulting binaries, See Configuring the Source RPM. These options are provided on the rpm(1) command line. For example:
% rpmbuild --rebuild -vv --target athlon-redhat-linux \ --define "_kversion 2.4.20-28.7" \ -- LiS-2.18.6-1.src.rpm |
will rebuild binary RPM for the `2.4.20-28.7' kernel for the `athlon' architecture against the LiS STREAMS package. 31
To install the resulting binary RPM, See Installing the Binary RPM.
If you have downloaded the necessary Debian DSC (see Downloading the Debian DSC), then the following instructions will rebuild the binary DEBs on your system. Once the binary DEBs are rebuilt, you may install them as described above (see Installing the Debian DEB).
The Debian DSC is rebuilt to binary DEBs as follows:
% wget http://www.openss7.org/debian/LiS_2.18.6-0.dsc % wget http://www.openss7.org/debian/LiS_2.18.6-0.tar.gz % dpkg-buildpackage -v LiS_2.18.6-0.dsc |
The rebuild process can also recognize a number of options that can be used to tweak the resulting binaries, See Configuring the Debian DSC. These options are provided in the environment variable BUILD_DPKGOPTIONS and have the same form as the options to configure, See Configuring the Tar Ball. For example:
% BUILD_DEBOPTIONS=' --with-k-release=2.4.20-28.7 --host=athlon-debian-linux-gnu' dpkg-buildpackage -v \ LiS_2.18.6-0.dsc |
will rebuild binary DEB for the `2.4.20-28.7' kernel for the `athlon' architecture against the LiS STREAMS package. 32
To install the resulting binary DEB, See Installing the Debian DEB.
If you have downloaded the tar ball (see Downloading the Tar Ball), then the following instructions will rebuild the package on your system. (Note that the build process does not required root privilege.)
Following is an example of a native build against the running kernel:
% wget http://www.openss7.org/LiS-2.18.6.tar.bz2 % tar -xjvf LiS-2.18.6.tar.bz2 % pushd LiS-2.18.6 % ./configure % make % popd |
Following is an example for a cross-build. The kernel release version must always be specified for a cross-build.33 If you are cross-building, specify the root for the build with environment variable DESTDIR. The cross-compile host must also be specified if different from the build host. Either the compiler and other tools must be in the usual places where GNU autoconf(1) can find them, or they must be specified with declarations such as `CC=/u5/NexusWare24/ppc-linux/gcc' on the configure command line. Look in the file configure.nexusware in the release package for an example.
% wget http://www.openss7.org/LiS-2.18.6.tar.bz2 % tar -xjvf LiS-2.18.6.tar.bz2 % pushd LiS-2.18.6 % ./configure DESTDIR="/some/other/root" \ --with-k-release=2.4.18 --host sparc-linux % make % popd |
Additional support is provided for cross-building for the Performance Technologies Inc. NexusWare embedded target for the CPC-384, CPC-388 and CPC-396 cards. A configuration script wrapper (configure.nexusware) is provided to simplify the cross-build operation for these targets. The following steps describe the process:
% pushd /u5/NexusWare24 % source SETUP.sh % make % popd |
For more recent NexusWare releases, the method for rebuilding a kernel is a little different as follows:
% pushd /u5/NexusWare80 % ./nexus 2.4 % ./nexus 8260 % ./nexus quick % . SETUP.sh % popd |
Any of the normal configure script options (see Configuring the Tar Ball) can be used on the same line as `./configure.nexusware'. One of particular interest to embedded targets is --with-k-optimize=size to attempt to reduce the size of the kernel modules.
You must specify the kernel version of the kernel for which you are configuring. Add the --with-k-release=2.4.18 option for older NexusWare releases, --with-k-release=2.4.25 or --with-k-release=2.6.12 for more current NexusWare releases.
Following is what I use for configuration and installation: (My NexusWare tree is rooted at /u5/NexusWare.)
% pushd /u5/NexusWare80 % ./nexus 2.4 % ./nexus 8260 % ./nexus quick % . SETUP.sh % popd % wget http://www.openss7.org/LiS-2.18.6.tar.bz2 % tar -xjvf LiS-2.18.6.tar.bz2 % pushd LiS-2.18.6 % ./configure.nexusware --with-k-release=2.4.25 --with-k-optimize=size % make % make DESTDIR="$NEXUSWARE_PREFIX" install-strip % popd |
Once built and installed in the NexusWare directory, you will have to (currently) hand edit a .spec file to include the components you want in the NexusWare root file system. If you are cross-building for NexusWare you should already know what that means. Objects that you might be interested in copying to the root file system are kernel modules that were installed in $NEXUSWARE_PREFIX/lib/modules/2.4.18/lis, libraries installed in $NEXUSWARE_PREFIX/usr/lib and utility functions installed in $NEXUSWARE_PREFIX/usr/bin and $NEXUSWARE_PREFIX/usr/sbin and test programs in $NEXUSWARE_PREFIX/usr/libexec. If you would prefer that these programs be installed in $NEXUSWARE_PREFIX/lib, $NEXUSWARE_PREFIX/bin, $NEXUSWARE_PREFIX/sbin and $NEXUSWARE_PREFIX/libexec, (say because you want to remote mount the /usr directory after boot), then specify the --exec-prefix=/ option to `./configure.nexusware'.
Because NexusWare does not include an /etc/modules.conf file by default, it will be necessary to add one or edit your rc.4 file to insmod(8) the necessary LiS modules at boot time.
NexusWare does not configure its kernels for CONFIG_KMOD, so any kernel modules must be loaded by the rc.4 init script at boot. On more recent NexusWare releases, the init scripts will be installed in $NEXUSWARE_PREFIX/etc/rc.d/init.d/ but you must manually edit your rc.4 script to invoke these scripts.
Once you have completed the necessary .spec and rc.4 file entries, you need to rebuild the `generic' kernel flash image once more for these objects to be included in the flash file system. It is important that this second build of the kernel image be the same as the first.
When modifying and rebuilding a NexusWare kernel, it will be necessary to rebuild and install LiS. Simply perform the last `make install-strip' stage or start again with `./configure.nexusware'. You can place the unpacked tarball in $NEXUSWARE_PREFIX/usr/src/LiS, and add the following to the top-level NexusWare Makefile to make the build process a single step process instead of dual pass:
all: ... (cd kernels/generic; $(MAKE) depend) (cd usr/src/pcmcia-cs-3.2.1; $(MAKE) config) (cd kernels/generic; $(MAKE)) (cd usr/src/pcmcia-cs-3.2.1; $(MAKE) pti) (cd usr/src/pti; $(MAKE)) (cd drivers; $(MAKE)) (cd utility; $(MAKE)) # uncomment for LiS build # (cd usr/src/LiS; ./configure.nexusware; $(MAKE) install-strip) (cd build/generic; $(MAKE)) ... |
Another, perhaps simpler approach, is to make the necessary edits to the NexusWare top-level Makefile and .spec and rc.4 files, download and unpack the tar ball into the NexusWare directory, and build the NexusWare flash image as normal:
% wget http://www.openss7.org/LiS-2.18.6.tar.bz2 % pushd /u5/NexusWare24 % source SETUP.sh % pushd usr/src % tar -xjvf ${DIRSTACK[2]}/LiS-2.18.6.tar.bz2 % ln -sf LiS-2.18.6 LiS % popd % make % popd |
The situation is a little more complex for recent NexusWare releases.
If you have downloaded the necessary binary RPMs (see Downloading the Binary RPM), or have
rebuilt binary RPMs using the source RPM (see Building from the Source RPM), then the following
instructions will install the RPMs on your system. For additional information on rpm(1), see
rpm(8)
.
% pushd RPMS/i686 % rpm -ihv LiS-*-2.18.6-1.7.2.i686.rpm |
You must have the correct binary RPMs downloaded or built for this to be successful.
Some of the packages are relocatable and can have final installation directories altered with the
--relocate option to rpm(1), see rpm(8)
.
For example, the following will relocate the documentation and info directories:
% pushd RPMS/i686 % rpm -ihv \ --relocate '/usr/share/doc=/usr/local/share/doc' \ --relocate '/usr/share/info=/usr/local/share/info' \ -- LiS-doc-2.18.6-1.7.2.i686.rpm |
The previous example will install the LiS-doc package by will relocate the documentation an info directory contents to the /usr/local version.
If you have downloaded the necessary Debian DEBs (see Downloading the Debian DEB), or have
rebuild binary DEBs using the Debian DSC (see Building from the Debian DSC), then the following
instructions will install the DEBs on your system. For additional information see dpkg(8)
.
% pushd debian % dpkg -iv LiS-*_2.18.6-0_*.deb |
You must have the correct .deb files downloaded or build for this to be successful.
After the build process (see Building from the Tar Ball), installation only requires execution of one of two automake(1) targets:
To remove an installed version of the binary RPMs (whether obtained from the OpenSS7 binary RPM releases, or whether created by the source RPM), execute the following command:
% rpm -evv `rpm -qa | grep '^LiS-'` |
For more information see rpm(1)
.
To remove and installed version of the Debian DEB (whether obtained from the OpenSS7 binary DEB releases, or whether created by the Debian DSC), execute the following command:
% dpkg -ev `dpkg -l | grep '^LiS-'` |
For more information see dpkg(8)
.
To remove all the installed binary RPM build from the source RPM, see Removing the Binary RPM. Then simply remove the binary RPM package files and source RPM file. A command such as:
% find / -name 'LiS-*.rpm' -type f -print0 | xargs --null rm -f |
should remove all LiS RPMs from your system.
To remove all the installed binary DEB build from the Debian DSC, see Removing the Debian DEB. Then simply remove the binary DEB package files and Debian DSC file. A command such as:
% find / \( -name 'LiS-*.deb' \ -o -name 'LiS-*.dsc' \ -o -name 'LiS-*.tar.* \ \) -type f -print0 | xargs --null rm -f |
should remove all LiS DEBs, DSCs and TARs from your system.
To remove a version installed from tar ball, change to the build directory where the package was built and use the `uninstall' automake(1) target as follows:
% cd /usr/src/LiS % make uninstall % cd .. % rm -fr LiS-2.18.6 % rm -f LiS-2.18.6.tar.gz % rm -f LiS-2.18.6.tar.bz2 |
If you have inadvertently removed the build directory and, therefore, no longer have a configured directory from which to execute `make uninstall', then perform all of the steps for configuration and installation (see Installing the Tar Ball) except the final installation and then perform the steps above.
When Linux STREAMS (LiS) installs, modules and drivers belonging to release packages are normally configured for demand loading. The `install' and `install-strip' automake(1) targets will make the necessary changes to the /etc/modules.conf file and place the modules in an appropriate place in /lib/modules/2.4.20-28.7/lis. The `make install' process should have copied the kernel module files streams-*.o to the directory /lib/modules/2.4.20-28.7/lis. This means that to load any of these modules, you can simply execute, for example, `modprobe stream-somedriver'.35
The LiS demand load system supports both the old kerneld and the new kmod mechanisms for demand loading kernel modules.
The convention for LiS kernel loadable object files is:
If your kernel has been built using the kerneld daemon, then LiS kernel modules will automatically load as soon as the STREAMS module is pushed or the driver is opened. The `make install' process makes the necessary changes to the /etc/modules.conf file. After the install, you will see lines like the following added to your /etc/modules.conf file:
prune modules.lis if -f /lib/modules/`uname -r`/modules.lis include /lib/modules/`uname -r`/modules.lis endif |
which will provide for demand loading of the modules if they have been built and installed for the running kernel. The /lib/modules/`uname -r`/modules.lis file looks like this:
alias char-major-245 streams-some_driver alias char-major-246 streams-other_driver |
Note that STREAMS modules are not listed in this file, but will be loaded by name using kerneld if available.
Linux Fast-STREAMS has a wider range of kernel module loading mechanisms than is provided by the deprecated LiS. For mechanisms used for kernel module loading under Linux Fast-STREAMS, See About This Manual.
Under exceptional circumstances, such as a NexusWare build, it is necessary to hand-edit a .spec and rc.4 file to load the modules at boot time.36
LiS is deprecated and this section has been deleted.
automake(1) has many targets, not all of which are obvious to the casual user. In addition, OpenSS7 automake(1) files have additional rules added to make maintaining and releasing a package somewhat easier. This list of targets provides some help with what targets can be invoked, what they do, and what they hope to achieve. The available targets are as follows:
The following are normal targets intended to be invoked by installers of the package. They are concerned with compiling, checking the compile, installing, checking the installation, and removing the package.
All OpenSS7 Project packages are configured without maintainer mode and without dependency tracking by default. This speeds compilation of the package for one-time builds. This also means that if you are developing using the source package (edit-compile-test cycle), changes made to source files will not cause the automatic rebuilding due to dependencies. There are two ways to enable dependency tracking: specify --enable-maintainer-mode to configure; or, specify --enable-dependency-tracking to configure. I use the former during my edit-compile-test cycle.
This is a standard GNU automake(1) makefile target. This target does not require root privilege.
Another way to enable the greater set of checks, without invoking maintainer mode, is to specify --enable-checks to configure. For more information, see Pre-installation Checks.
This is a standard GNU automake(1) makefile target, although the functions performed are customized for the OpenSS7 Project. This target does not require root privilege.
This is a standard GNU automake(1) makefile target. This target requires root privilege.
This is a standard GNU automake(1) makefile target. This target might require root privilege. Tests requiring root privilege will be skipped when run as a regular user. Tests requiring regular account privileges will be skipped when run as root.
This is an OpenSS7 Project specific makefile target. As with `installcheck', this target might require root privilege. Tests requiring root privilege will be skipped when run as a regular user. Tests requiring regular account privileges will be skipped when run as root.
The `uninstall' target unfortunately removes add-on packages in the same order in which they were installed. This is not good for the OpenSS7 Master Package, where the `remove' target should be used instead.
This is a standard GNU automake(1) makefile target. This target requires root privilege.
This is an OpenSS7 Project specific makefile target. This target requires root privilege.
The following targets are targets intended for use by maintainers of the package, or those responsible for release and packaging of a derivative work of the package. Some of these targets are only effective when maintainer mode has been invoked (--enable-maintainer-mode specified to configure.)
This is a standard GNU automake(1) makefile target. This target does not require root privilege.
This is a standard GNU automake(1) makefile target. This target does not require root privilege.
This is a standard GNU automake(1) makefile target. This target does not require root privilege.
This is a standard GNU automake(1) makefile target. This target might require root privilege if the `installcheck' target or the testsuite was invoked with root privilege (leaving files belonging to root).
This is a standard GNU automake(1) makefile target. This target might require root privilege if the `installcheck' target or the testsuite was invoked with root privilege (leaving files belonging to root).
This is a standard GNU automake(1) makefile target. This target might require root privilege if the `installcheck' target or the testsuite was invoked with root privilege (leaving files belonging to root).
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
The following are targets used to generate complete releases into the package distribution directory. These are good for unattended and NFS builds, which is what I use them for. Also, when building from atop multiple packages, these targets also recurse down through each package.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
For convenience, to log the output of a number of targets to a file, log targets are defined. The log file itself is used as the target to make, but make invokes the target minus a .log suffix. So, for example, to log the results of target `foo', invoke the target `foo.log'. The only target that this does not apply to is `compile.log'. When you invoke the target `compile.log' a simple automake(1) is invoked and logged to the file compile.log. The `foo.log' rule applies to all other targets. This does not work for all targets, just a selected few.41 Following are the logging targets:
Common logging targets correspond to normal user automake(1) makefile targets as follows:
Maintainer logging targets correspond to maintainer mode automake(1) makefile targets as follows:
If you want to add one, simply add it to LOGGING_TARGETS in Makefile.am.
To ease problem report generation, all logging targets will automatically generate a problem report suitable for mailing in the file target.pr for target `target.log'. This problem report file is in the form of an email and can be sent using the included send-pr script or by invoking the `send-pr' makefile target.
There are two additional problem report targets:
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege (unless the problem report file was generated as root).
The following targets are used to generate and clean distribution archive and signature files. Whereas the `dist' target affects archives in the top build directory, the `release-archive' targets affects archives in the package distribution directory (either the top build directory or that specified with --with-pkg-distdir=DIR to configure).
You can change the directory to which packages are distributed by using the --with-pkg-distdir=DIR option to configure. The default directory is the top build directory.
The files generated are named:
LiS-2.18.6.tar.gz and LiS-2.18.6.tar.bz2
You can change this distribution directory with the --with-pkg-distdir option to configure. See `./configure --help' for more details on options.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
`make GNUPGPASS=mypasswd release-sign-archives'
Signature files will be named:
LiS-2.18.6.tar.gz.asc and LiS-2.18.6.tar.bz2.asc
These files will be moved to the package distribution directory with the plain text archives.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
On rpm(1) systems, or systems sporting rpm packaging tools, the following targets are used to generate rpm(1) release packages. The epoch and release number can be controlled by the contents of the .rpmepoch and .rpmrelease files, or with the --with-rpm-epoch=EPOCH and --with-rpm-release=RELEASE options to configure. See `configure --help' for more information on options. We always use release number `1'. You can use release numbers above `1'.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
LiS-*-2.18.6-1.*.rpm
where the stars indicate the subpackage and the architecture. Both the architecture specific subpackages (binary objects) and the architecture independent (.noarch) subpackages will be built unless the the former was disabled with the option --disable-arch, or the later with the option --disable-indep, passed to configure.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
On Debian systems, or systems sporting Debian packaging tools, the following targets are used to generate Debian release packages. The release number can be controlled by the contents of the .debrelease file, or with the --with-debrelease=RELEASENUMBER option to configure. See `configure --help' for more information on options.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
This is an OpenSS7 Project specific makefile target. This target does not require root privilege.
Most OpenSS7 packages, including the Linux STREAMS (LiS) package, ship with pre-installation checks integral to the build system. Pre-installation checks include check scripts that are shipped in the scripts subdirectory as well as specialized make targets that perform the checks.
When building and installing the package from RPM or DEB source packages (see Building from the Source RPM; and Building from the Debian DSC), a fundamental set of post-compile, pre-installation checks are performed prior to building binary packages. This is performed automatically and does not require any special actions on the part of the user creating binary packages from source packages.
When building and installing the package from tarball (see Building from the Tar Ball; and Installing the Tar Ball), however, pre-installation checks are only performed if specifically invoked by the builder of the package. Pre-installation checks are invoked after building the package and before installing the package. Pre-installation checks are performed by invoking the `check' or `check.log' target to make when building the package, as shown in testsuite:ex0.
Pre-installation checks fall into two categories: System Checks and Maintenance Checks.
System Checks are post-compilation checks that can be performed before installing the package that check to ensure that the compiled objects function and will be successfully installed. When the --enable-maintainer-mode option has not been passed to configure, only System Checks will be performed.
For example, the steps shown in testsuite:ex1 will perform System checks.
Maintenance Checks include all System Checks, but also checks to ensure that the kernel modules, applications programs, header files, development tools, test programs, documentation, and manual pages conform to OpenSS7 standards. When the --enable-maintainer-mode option has been passed to configure, Maintenance Checks will be performed.
For example, the steps shown in testsuite:ex2 will perform Maintenance checks.
A number of check scripts are provided in the scripts subdirectory of the distribution that perform both System and Maintenance checks. These are as follows:
When performing System tests, the following tests are performed:
Unless cross-compiling, or unless a program is included in AM_INSTALLCHECK_STD_OPTIONS_EXEMPT
every program in bin_PROGRAMS
, sbin_PROGRAMS
, and libexec_PROGRAMS
is tested to
ensure that the --help, --version, and --copying options are accepted.
When cross-compiling is is not possible to execute cross-compiled binaries, and these checks are
skipped in that case.
Script executables, on the other hand, can be executed on the build host, so, unless listed in
AM_INSTALLCHECK_STD_OPTIONS_EXEMPT
, every program in dist_bit_SCRIPTS
,
dist_sbin_SCRIPTS
, and pkglibexec_SCRIPTS
are tested to ensure that the
--help, --version, and --copying options are accepted.
When performing Maintenance tests, check_commands also checks to ensure that a
manual page exists in section 1 for every executable binary or script that will be installed from
bin_PROGRAMS
and dist_bin_SCRIPTS
. It also checks to ensure that a manual page exists
in section 8 for every executable binary or script that will be installed from sbin_PROGRAMS
,
dist_sbin_SCRIPTS
, libexec_PROGRAMS
, and pkglibexec_SCRIPTS
.
It collects the results from the check_libs
, check_modules
and check_headers
check scripts and tests to ensure every declaration of a function prototype or external variable
contained in installed header files has a corresponding exported symbol from either a to be
installed shared object library or a to be installed kernel module. Declarations are exempted from
this requirement if their identifiers have been explicitly added to the EXPOSED_SYMBOL
variable. If WARN_EXCESS
is set to `yes', then the check script will only warn when
excess declarations exist (without a corresponding exported symbol); otherwise, the check script
will generate an error and the check will fail.
When performing Maintenance tests, it identifies all of the declarations included in to be installed header files. It then checks to ensure that a manual page exists in sections 2, 3, 7 or 9, as appropriate, for the type of declaration. It also checks to see if a manual page source file exists in the source directory for a declaration that has not been included in the distribution. Function or prototype declarations that do not have a manual page in sections 2, 3, or 9 will cause the check to fail. Other declarations (`variable', `externvar', `macro', `enumerate', `enum', `struct', `union', `typedef', `member', etc.) will only warn if a manual page does not exist, but will not fail the check.
When performing Maintenance tests, it checks that each exported symbol in each to be installed shared object library has a manual page in section 3. It also checks that each exported symbol has a `function', `prototype' or `externvar' declaration in the to be installed header files. A missing declaration or manual page will cause this check to fail.
When performing Maintenance tests, it checks that to be install manual pages can be formatted for display without any errors or warnings from the build host man program. It also checks that required headings exist for manual pages according to the section in which the manual page will be installed. It warns if recommended headings are not included in the manual pages. Because some RPM distributions have manual pages that might conflict with the package manual pages, this check script also checks for conflicts with installed manual pages on the build host. This check script also checks to ensure that all to be installed manual pages are used in some fashion, that is, they have a declaration, or exported symbol, or are the name of a kernel module or STREAMS module or driver, possibly capitalized.
Note that checking for conflicts with the build host should probably be included in the System
checks (because System checks are performed before the source RPM %install
scriptlet).
When performing System tests, it checks each to be installed kernel module to ensure that all undefined symbols can be resolved to either the kernel or another module. It also checks whether an exported or externally declared symbol conflicts with an exported or externally declared symbol present in the kernel or another module.42
When performing Maintenance tests, this check script tests that each to be installed kernel module has a manual page in section 9 and that each exported symbol that does not begin with an underscore, and that belongs to an exported function or exported variable, has a manual page in section 9. It also checks to ensure that each exported symbol that does not begin with an underscore, and that belongs to an exported function or exported variable, has a `function', `prototype' or `externvar' declaration in the to be installed header files.
When performing Maintenance tests, it checks that for each configured STREAMS module or driver, or device node, that a manual page exists in section 4 or section 7 as appropriate.
The output of the pre-installation tests are fairly self explanatory. Each check script saves some output to name.log, where name is the name of the check script as listed above. A summary of the results of the test are display to standard output and can also be captured to the check.log file if the `check.log' target is used instead of the `check' target to make.
Because the check scripts proliferate name.log files throughout the build directory, a `make check-clean' make target has be provided to clean them out. `make check-clean' should be run before each successive run of `make check'.
Most OpenSS7 packages ship with a compatibility and conformance test suite built using the `autotest' capabilities of `autoconf'. These test suites act as a wrapper for the compatibility and conformance test programs that are shipped with the package.
Unlike the pre-installation checks, the post-installation checks are always run complete. The only check that post-installation test scripts perform is to test whether they have been invoked with root privileges or not. When invoked as root, or as a plain user, some tests might be skipped that require root privileges, or that require plain user privileges, to complete successfully.
There are several ways of invoking the conformance test suites:
Typical steps for invoking the test suites directly from make are shown in testsuite:ex3.
When performing post-installation checks for the purposes of generating a problem report, the checks should always be performed from the build directory, either with `make installcheck' or by invoking testsuite directly from the tests subdirectory of the build directory. This ensures that all of the information known to configure and pertinent to the configuration of the system for which a test case failed, will be collected in the resulting testsuite.log file deposited upon test suite failure in the tests directory. This testsuite.log file can then be attached as part of the problem report and provides rich details to maintainers of the package. See also See Problem Reports, below.
Typical steps for invoking and installed testsuite standalone are shown in testsuite:ex4.
When invoked directly, testsuite will generate a testsuite.log file in the current directory, and a testsuite.dir directory of failed tests cases and debugging scripts. For generating a problem report for failed test cases, see Stand Alone Problem Reports.
Problem reports in the following categories should include a log file as indicated in the table below:
For other problems that occur during the use of the Linux STREAMS (LiS) package, please
write a test case for the test suite that recreates the problem if one does not yet exist and
provide a test program patch with the problem report. Also include whatever log files are generated
by the kernel (cmn_err(9)
) or by the strerr(8) or strace(1) facilities
(strlog(9)
).
The OpenSS7 Project uses the GNU GNATS system for problem reporting. Although the `send-pr' tool from the GNU GNATS package can be used for bug reporting to the project's GNATS database using electronic mail, it is not always convenient to download and install the GNATS system to gain access to the `send-pr' tool.
Therefore, the Linux STREAMS (LiS) package provides the `send-pr' shell script that can be used for problem reporting. The `send-pr' shell script can invoked directly and is a work-alike for the GNU `send-pr' tool.
The `send-pr' tool takes the same flags and can be used in the same fashion, however, whereas `send-pr' is an interactive tool43, `send-pr' is also able to perform batch processing. Whereas `send-pr' takes its field information from local databases or from using the `query-pr' C-language program to query a remote database, the `send-pr' tool has the field database internal to the tool.
Problem reports can be generate using make, See Problem Report Targets. An example of how simple it is to generate a problem report is illustrated in autopr:ex0.
Using the `make pr' target to generate a problem report has the advantages that it will assemble any available *.log files in the build directory and attach them to the problem report.
The Linux STREAMS (LiS) package also provides a feature for automatic problem report generation that meets the problem report submission guidelines detailed in the preceding sections.
Whenever a logging makefile target (see Logging Targets) is invoked, if the primary target fails, the send-pr shell script is invoked to automatically generate a problem report file suitable for the corresponding target (as described above under see Problem Report Guidelines). An example is shown in autopr:ex1.
The Linux STREAMS (LiS) package installs the send-pr script and its configuration file send-pr.config in ${libexecdir}/LiS along with the validation testsuite, see See Test Suites. As with the testsuite, this allows the send-pr script to be used for problem report generation on an installed system that does not have a build directory.
An example of invoking the package testsuite and then generating a problem report for failed cases is shown in autopr:ex2.
The advantage of the approach shown in the example is that the send-pr script is capable of collecting the testsuite.log file and the failed test cases and debugging scripts from the testsuite.dir directory and including them in the problem report, as well as all package pertinent information from the installed send-pr.config.
The OpenSS7 Project does not ship software with known bugs. All bugs are unknown.
Verified behaviour is that behaviour that has been verified by conformance test suites that are shipped with the Linux STREAMS (LiS) package.
Unverified behaviour may contain unknown bugs.
Please remember that there is NO WARRANTY.
See also Bugs, or file BUGS in the release directory.
Copyright © 1989, 1991 Free Software Foundation, Inc. 675 Mass Ave, Cambridge, MA 02139, USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.
The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software—to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Library General Public License instead.) You can apply it to your programs, too.
When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it.
For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights.
We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations.
Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and modification follow.
Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does.
You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee.
These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program.
In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License.
The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable.
If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code.
If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances.
It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice.
This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License.
Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and “any later version”, you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation.
If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the “copyright” line and a pointer to where the full notice is found.
one line to give the program's name and an idea of what it does. Copyright (C) 19yy name of author This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this when it starts in an interactive mode:
Gnomovision version 69, Copyright (C) 19yy name of author Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, the commands you use may be called something other than `show w' and `show c'; they could even be mouse-clicks or menu items—whatever suits your program.
You should also get your employer (if you work as a programmer) or your school, if any, to sign a “copyright disclaimer” for the program, if necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program `Gnomovision' (which makes passes at compilers) written by James Hacker. signature of Ty Coon, 1 April 1989 Ty Coon, President of Vice
This General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Library General Public License instead of this License.
Copyright © 1991, 1999 Free Software Foundation, Inc. 59 Temple Place – Suite 330, Boston, MA 02111-1307, USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. [This is the first released version of the Lesser GPL. It also counts as the successor of the GNU Library Public License, version 2, hence the version number 2.1.]
The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public Licenses are intended to guarantee your freedom to share and change free software—to make sure the software is free for all its users.
This license, the Lesser General Public License, applies to some specially designated software—typically libraries—of the Free Software Foundation and other authors who decide to use it. You can use it too, but we suggest you first think carefully about whether this license or the ordinary General Public License is the better strategy to use in any particular case, based on the explanations below.
When we speak of free software, we are referring to freedom of use, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish); that you receive source code or can get it if you want it; that you can change the software and use pieces of it in new free programs; and that you are informed that you can do these things.
To protect your rights, we need to make restrictions that forbid distributors to deny you these rights or to ask you to surrender these rights. These restrictions translate to certain responsibilities for you if you distribute copies of the library or if you modify it.
For example, if you distribute copies of the library, whether gratis or for a fee, you must give the recipients all the rights that we gave you. You must make sure that they, too, receive or can get the source code. If you link other code with the library, you must provide complete object files to the recipients, so that they can relink them with the library after making changes to the library and recompiling it. And you must show them these terms so they know their rights.
We protect your rights with a two-step method: (1) we copyright the library, and (2) we offer you this license, which gives you legal permission to copy, distribute and/or modify the library.
To protect each distributor, we want to make it very clear that there is no warranty for the free library. Also, if the library is modified by someone else and passed on, the recipients should know that what they have is not the original version, so that the original author's reputation will not be affected by problems that might be introduced by others.
Finally, software patents pose a constant threat to the existence of any free program. We wish to make sure that a company cannot effectively restrict the users of a free program by obtaining a restrictive license from a patent holder. Therefore, we insist that any patent license obtained for a version of the library must be consistent with the full freedom of use specified in this license.
Most GNU software, including some libraries, is covered by the ordinary GNU General Public License. This license, the GNU Lesser General Public License, applies to certain designated libraries, and is quite different from the ordinary General Public License. We use this license for certain libraries in order to permit linking those libraries into non-free programs.
When a program is linked with a library, whether statically or using a shared library, the combination of the two is legally speaking a combined work, a derivative of the original library. The ordinary General Public License therefore permits such linking only if the entire combination fits its criteria of freedom. The Lesser General Public License permits more lax criteria for linking other code with the library.
We call this license the Lesser General Public License because it does Less to protect the user's freedom than the ordinary General Public License. It also provides other free software developers Less of an advantage over competing non-free programs. These disadvantages are the reason we use the ordinary General Public License for many libraries. However, the Lesser license provides advantages in certain special circumstances.
For example, on rare occasions, there may be a special need to encourage the widest possible use of a certain library, so that it becomes a de-facto standard. To achieve this, non-free programs must be allowed to use the library. A more frequent case is that a free library does the same job as widely used non-free libraries. In this case, there is little to gain by limiting the free library to free software only, so we use the Lesser General Public License.
In other cases, permission to use a particular library in non-free programs enables a greater number of people to use a large body of free software. For example, permission to use the GNU C Library in non-free programs enables many more people to use the whole GNU operating system, as well as its variant, the GNU/Linux operating system.
Although the Lesser General Public License is Less protective of the users' freedom, it does ensure that the user of a program that is linked with the Library has the freedom and the wherewithal to run that program using a modified version of the Library.
The precise terms and conditions for copying, distribution and modification follow. Pay close attention to the difference between a “work based on the library” and a “work that uses the library”. The former contains code derived from the library, whereas the latter must be combined with the library in order to run.
A “library” means a collection of software functions and/or data prepared so as to be conveniently linked with application programs (which use some of those functions and data) to form executables.
The “Library”, below, refers to any such software library or work which has been distributed under these terms. A “work based on the Library” means either the Library or any derivative work under copyright law: that is to say, a work containing the Library or a portion of it, either verbatim or with modifications and/or translated straightforwardly into another language. (Hereinafter, translation is included without limitation in the term “modification”.)
“Source code” for a work means the preferred form of the work for making modifications to it. For a library, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the library.
Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running a program using the Library is not restricted, and output from such a program is covered only if its contents constitute a work based on the Library (independent of the use of the Library in a tool for writing it). Whether that is true depends on what the Library does and what the program that uses the Library does.
You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee.
(For example, a function in a library to compute square roots has a purpose that is entirely well-defined independent of the application. Therefore, Subsection 2d requires that any application-supplied function or table used by this function must be optional: if the application does not supply it, the square root function must still compute square roots.)
These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Library, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Library, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Library.
In addition, mere aggregation of another work not based on the Library with the Library (or with a work based on the Library) on a volume of a storage or distribution medium does not bring the other work under the scope of this License.
Once this change is made in a given copy, it is irreversible for that copy, so the ordinary GNU General Public License applies to all subsequent copies and derivative works made from that copy.
This option is useful when you wish to copy part of the code of the Library into a program that is not a library.
If distribution of object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place satisfies the requirement to distribute the source code, even though third parties are not compelled to copy the source along with the object code.
However, linking a “work that uses the Library” with the Library creates an executable that is a derivative of the Library (because it contains portions of the Library), rather than a “work that uses the library”. The executable is therefore covered by this License. Section 6 states terms for distribution of such executables.
When a “work that uses the Library” uses material from a header file that is part of the Library, the object code for the work may be a derivative work of the Library even though the source code is not. Whether this is true is especially significant if the work can be linked without the Library, or if the work is itself a library. The threshold for this to be true is not precisely defined by law.
If such an object file uses only numerical parameters, data structure layouts and accessors, and small macros and small inline functions (ten lines or less in length), then the use of the object file is unrestricted, regardless of whether it is legally a derivative work. (Executables containing this object code plus portions of the Library will still fall under Section 6.)
Otherwise, if the work is a derivative of the Library, you may distribute the object code for the work under the terms of Section 6. Any executables containing that work also fall under Section 6, whether or not they are linked directly with the Library itself.
You must give prominent notice with each copy of the work that the Library is used in it and that the Library and its use are covered by this License. You must supply a copy of this License. If the work during execution displays copyright notices, you must include the copyright notice for the Library among them, as well as a reference directing the user to the copy of this License. Also, you must do one of these things:
For an executable, the required form of the “work that uses the Library” must include any data and utility programs needed for reproducing the executable from it. However, as a special exception, the materials to be distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable.
It may happen that this requirement contradicts the license restrictions of other proprietary libraries that do not normally accompany the operating system. Such a contradiction means you cannot use both them and the Library together in an executable that you distribute.
If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply, and the section as a whole is intended to apply in other circumstances.
It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice.
This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License.
Each version is given a distinguishing version number. If the Library specifies a version number of this License which applies to it and “any later version”, you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Library does not specify a license version number, you may choose any version ever published by the Free Software Foundation.
If you develop a new library, and you want it to be of the greatest possible use to the public, we recommend making it free software that everyone can redistribute and change. You can do so by permitting redistribution under these terms (or, alternatively, under the terms of the ordinary General Public License).
To apply these terms, attach the following notices to the library. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the “copyright” line and a pointer to where the full notice is found.
one line to give the library's name and an idea of what it does. Copyright (C) year name of author This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
Also add information on how to contact you by electronic and paper mail.
You should also get your employer (if you work as a programmer) or your school, if any, to sign a “copyright disclaimer” for the library, if necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the library `Frob' (a library for tweaking knobs) written by James Random Hacker. signature of Ty Coon, 1 April 1990 Ty Coon, President of Vice
That's all there is to it!
Copyright © 2000 Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.
The purpose of this License is to make a manual, textbook, or other written document free in the sense of freedom: to assure everyone the effective freedom to copy and redistribute it, with or without modifying it, either commercially or noncommercially. Secondarily, this License preserves for the author and publisher a way to get credit for their work, while not being considered responsible for modifications made by others.
This License is a kind of “copyleft”, which means that derivative works of the document must themselves be free in the same sense. It complements the GNU General Public License, which is a copyleft license designed for free software.
We have designed this License in order to use it for manuals for free software, because free software needs free documentation: a free program should come with manuals providing the same freedoms that the software does. But this License is not limited to software manuals; it can be used for any textual work, regardless of subject matter or whether it is published as a printed book. We recommend this License principally for works whose purpose is instruction or reference.
This License applies to any manual or other work that contains a notice placed by the copyright holder saying it can be distributed under the terms of this License. The “Document”, below, refers to any such manual or work. Any member of the public is a licensee, and is addressed as “you”.
A “Modified Version” of the Document means any work containing the Document or a portion of it, either copied verbatim, or with modifications and/or translated into another language.
A “Secondary Section” is a named appendix or a front-matter section of the Document that deals exclusively with the relationship of the publishers or authors of the Document to the Document's overall subject (or to related matters) and contains nothing that could fall directly within that overall subject. (For example, if the Document is in part a textbook of mathematics, a Secondary Section may not explain any mathematics.) The relationship could be a matter of historical connection with the subject or with related matters, or of legal, commercial, philosophical, ethical or political position regarding them.
The “Invariant Sections” are certain Secondary Sections whose titles are designated, as being those of Invariant Sections, in the notice that says that the Document is released under this License.
The “Cover Texts” are certain short passages of text that are listed, as Front-Cover Texts or Back-Cover Texts, in the notice that says that the Document is released under this License.
A “Transparent” copy of the Document means a machine-readable copy, represented in a format whose specification is available to the general public, whose contents can be viewed and edited directly and straightforwardly with generic text editors or (for images composed of pixels) generic paint programs or (for drawings) some widely available drawing editor, and that is suitable for input to text formatters or for automatic translation to a variety of formats suitable for input to text formatters. A copy made in an otherwise Transparent file format whose markup has been designed to thwart or discourage subsequent modification by readers is not Transparent. A copy that is not “Transparent” is called “Opaque”.
Examples of suitable formats for Transparent copies include plain ascii without markup, Texinfo input format, LaTeX input format, SGML or XML using a publicly available DTD, and standard-conforming simple HTML designed for human modification. Opaque formats include PostScript, PDF, proprietary formats that can be read and edited only by proprietary word processors, SGML or XML for which the DTD and/or processing tools are not generally available, and the machine-generated HTML produced by some word processors for output purposes only.
The “Title Page” means, for a printed book, the title page itself, plus such following pages as are needed to hold, legibly, the material this License requires to appear in the title page. For works in formats which do not have any title page as such, “Title Page” means the text near the most prominent appearance of the work's title, preceding the beginning of the body of the text.
You may copy and distribute the Document in any medium, either commercially or noncommercially, provided that this License, the copyright notices, and the license notice saying this License applies to the Document are reproduced in all copies, and that you add no other conditions whatsoever to those of this License. You may not use technical measures to obstruct or control the reading or further copying of the copies you make or distribute. However, you may accept compensation in exchange for copies. If you distribute a large enough number of copies you must also follow the conditions in section 3.
You may also lend copies, under the same conditions stated above, and you may publicly display copies.
If you publish printed copies of the Document numbering more than 100, and the Document's license notice requires Cover Texts, you must enclose the copies in covers that carry, clearly and legibly, all these Cover Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on the back cover. Both covers must also clearly and legibly identify you as the publisher of these copies. The front cover must present the full title with all words of the title equally prominent and visible. You may add other material on the covers in addition. Copying with changes limited to the covers, as long as they preserve the title of the Document and satisfy these conditions, can be treated as verbatim copying in other respects.
If the required texts for either cover are too voluminous to fit legibly, you should put the first ones listed (as many as fit reasonably) on the actual cover, and continue the rest onto adjacent pages.
If you publish or distribute Opaque copies of the Document numbering more than 100, you must either include a machine-readable Transparent copy along with each Opaque copy, or state in or with each Opaque copy a publicly-accessible computer-network location containing a complete Transparent copy of the Document, free of added material, which the general network-using public has access to download anonymously at no charge using public-standard network protocols. If you use the latter option, you must take reasonably prudent steps, when you begin distribution of Opaque copies in quantity, to ensure that this Transparent copy will remain thus accessible at the stated location until at least one year after the last time you distribute an Opaque copy (directly or through your agents or retailers) of that edition to the public.
It is requested, but not required, that you contact the authors of the Document well before redistributing any large number of copies, to give them a chance to provide you with an updated version of the Document.
You may copy and distribute a Modified Version of the Document under the conditions of sections 2 and 3 above, provided that you release the Modified Version under precisely this License, with the Modified Version filling the role of the Document, thus licensing distribution and modification of the Modified Version to whoever possesses a copy of it. In addition, you must do these things in the Modified Version:
If the Modified Version includes new front-matter sections or appendices that qualify as Secondary Sections and contain no material copied from the Document, you may at your option designate some or all of these sections as invariant. To do this, add their titles to the list of Invariant Sections in the Modified Version's license notice. These titles must be distinct from any other section titles.
You may add a section entitled “Endorsements”, provided it contains nothing but endorsements of your Modified Version by various parties—for example, statements of peer review or that the text has been approved by an organization as the authoritative definition of a standard.
You may add a passage of up to five words as a Front-Cover Text, and a passage of up to 25 words as a Back-Cover Text, to the end of the list of Cover Texts in the Modified Version. Only one passage of Front-Cover Text and one of Back-Cover Text may be added by (or through arrangements made by) any one entity. If the Document already includes a cover text for the same cover, previously added by you or by arrangement made by the same entity you are acting on behalf of, you may not add another; but you may replace the old one, on explicit permission from the previous publisher that added the old one.
The author(s) and publisher(s) of the Document do not by this License give permission to use their names for publicity for or to assert or imply endorsement of any Modified Version.
You may combine the Document with other documents released under this License, under the terms defined in section 4 above for modified versions, provided that you include in the combination all of the Invariant Sections of all of the original documents, unmodified, and list them all as Invariant Sections of your combined work in its license notice.
The combined work need only contain one copy of this License, and multiple identical Invariant Sections may be replaced with a single copy. If there are multiple Invariant Sections with the same name but different contents, make the title of each such section unique by adding at the end of it, in parentheses, the name of the original author or publisher of that section if known, or else a unique number. Make the same adjustment to the section titles in the list of Invariant Sections in the license notice of the combined work.
In the combination, you must combine any sections entitled “History” in the various original documents, forming one section entitled “History”; likewise combine any sections entitled “Acknowledgments”, and any sections entitled “Dedications”. You must delete all sections entitled “Endorsements.”
You may make a collection consisting of the Document and other documents released under this License, and replace the individual copies of this License in the various documents with a single copy that is included in the collection, provided that you follow the rules of this License for verbatim copying of each of the documents in all other respects.
You may extract a single document from such a collection, and distribute it individually under this License, provided you insert a copy of this License into the extracted document, and follow this License in all other respects regarding verbatim copying of that document.
A compilation of the Document or its derivatives with other separate and independent documents or works, in or on a volume of a storage or distribution medium, does not as a whole count as a Modified Version of the Document, provided no compilation copyright is claimed for the compilation. Such a compilation is called an “aggregate”, and this License does not apply to the other self-contained works thus compiled with the Document, on account of their being thus compiled, if they are not themselves derivative works of the Document.
If the Cover Text requirement of section 3 is applicable to these copies of the Document, then if the Document is less than one quarter of the entire aggregate, the Document's Cover Texts may be placed on covers that surround only the Document within the aggregate. Otherwise they must appear on covers around the whole aggregate.
Translation is considered a kind of modification, so you may distribute translations of the Document under the terms of section 4. Replacing Invariant Sections with translations requires special permission from their copyright holders, but you may include translations of some or all Invariant Sections in addition to the original versions of these Invariant Sections. You may include a translation of this License provided that you also include the original English version of this License. In case of a disagreement between the translation and the original English version of this License, the original English version will prevail.
You may not copy, modify, sublicense, or distribute the Document except as expressly provided for under this License. Any other attempt to copy, modify, sublicense or distribute the Document is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance.
The Free Software Foundation may publish new, revised versions of the GNU Free Documentation License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. See http://www.gnu.org/copyleft/.
Each version of the License is given a distinguishing version number. If the Document specifies that a particular numbered version of this License “or any later version” applies to it, you have the option of following the terms and conditions either of that specified version or of any later version that has been published (not as a draft) by the Free Software Foundation. If the Document does not specify a version number of this License, you may choose any version ever published (not as a draft) by the Free Software Foundation.
To use this License in a document you have written, include a copy of the License in the document and put the following copyright and license notices just after the title page:
Copyright (C) year your name. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with the Invariant Sections being list their titles, with the Front-Cover Texts being list, and with the Back-Cover Texts being list. A copy of the license is included in the section entitled ``GNU Free Documentation License''.
If you have no Invariant Sections, write “with no Invariant Sections” instead of saying which ones are invariant. If you have no Front-Cover Texts, write “no Front-Cover Texts” instead of “Front-Cover Texts being list”; likewise for Back-Cover Texts.
If your document contains nontrivial examples of program code, we recommend releasing these examples in parallel under your choice of free software license, such as the GNU General Public License, to permit their use in free software.
dev_t
: Major/Minor Device Numberinglis_spin_lock_t
: LiS Spin Locksstrapush
: sadstruct lis_pci_dev
: The LiS PCI Device Structurestruct msgb
: Utility Prototypesstruct pci_dev
: PCI Interfacestruct str_list
: sadstruct strapush
: sadstruct strioctl
: mini-muxstruct strioctl
: loop-aroundstruct task_struct
: Debugging Semaphoresstruct task_struct
: Debugging Spin Locksstruct timer_list
: Timer Routinesstruct timeval
: Timer Routinestimeo_fcn_t
: Utility PrototypesDEV_SAME
: Major/Minor Device NumberingDEV_TO_INT
: Major/Minor Device Numberingfreezestr
: Freezing Streamsgetmajor
: Major/Minor Device Numberinggetminor
: Major/Minor Device Numberinglis_down
: LiS Semaphoreslis_down_nosig
: LiS SemaphoresLIS_MK_PCI_DEV_FCN
: The LiS PCI Device Structurelis_mknode
: Major/Minor Device NumberingLIS_PCI_DEV
: The LiS PCI Device StructureLIS_PCI_FCN
: The LiS PCI Device Structuremakedevice
: Major/Minor Device Numberingputnext
: Freezing Streamsqprocesoff
: Freezing Streamsqprocson
: Freezing StreamsUMKDEV
: Major/Minor Device Numberingunfreezestr
: Freezing StreamsAUTOM4TE
: Environment VariablesAUTOTEST
: Environment VariablesBZIP2
: Environment VariablesBZIP2_CMD
: Environment VariablesCHKCONFIG
: Environment VariablesDEB_BUILD_ARCH
: Environment VariablesDEB_BUILD_GNU_CPU
: Environment VariablesDEB_BUILD_GNU_SYSTEM
: Environment VariablesDEB_BUILD_GNU_TYPE
: Environment VariablesDEB_HOST_ARCH
: Environment VariablesDEB_HOST_GNU_CPU
: Environment VariablesDEB_HOST_GNU_SYSTEM
: Environment VariablesDEB_HOST_GNU_TYPE
: Environment VariablesDEPMOD
: Environment VariablesDESTDIR
: Environment VariablesDPKG
: Environment VariablesDPKG_BUILDPACKAGE
: Environment VariablesDPKG_SOURCE
: Environment VariablesGENKSYMS
: Environment VariablesGNUPGHOME
: Environment VariablesGNUPGUSER
: Environment VariablesGPG
: Environment VariablesGPGPASSWD
: Environment VariablesGZIP
: Environment VariablesGZIP_CMD
: Environment VariablesKGENKSYMS
: Environment VariablesLDCONFIG
: Environment VariablesLSMOD
: Environment VariablesLSOF
: Environment VariablesM_BREAK
: Flushing Queue BandsM_CTL
: Flushing Queue BandsM_DATA
: Flushing Queue BandsM_DELAY
: Flushing Queue BandsM_FLUSH
: pipemodM_IOCTL
: Flushing Queue BandsM_PASSFP
: Flushing Queue BandsM_PASSFP
: connldM_PCPROTO
: Flushing Queue BandsM_PROTO
: Flushing Queue BandsM_RSE
: Flushing Queue BandsM_SETOPTS
: Flushing Queue BandsM_SIG
: Flushing Queue BandsMAKEWHATIS
: Environment VariablesMODPOST_CACHE
: Environment VariablesMODPROBE
: Environment VariablesNM
: Environment VariablesOBJDUMP
: Environment VariablesPACKAGE_KVERSION
: Configuring the Source RPMPIC
: Environment VariablesREFER
: Environment VariablesRPM
: Environment VariablesRPMBUILD
: Environment VariablesSOELIM
: Environment VariablesTBL
: Environment Variables/dev
: strmakenodes/dev
: Modules/dev
: clone-drvr/dev
: Drivers/dev/clone
: clone-drvr/dev/clone_drvr
: clone-drvr/dev/fifo
: fifo/dev/fifo.0
: fifo/dev/loop.1
: loop-around/dev/loop.2
: loop-around/dev/loop_clone
: loop-around/dev/minimux.1
: mini-mux/dev/minimux.2
: mini-mux/dev/mux_clone
: mini-mux/dev/printk
: printk/dev/sad
: sad/lib/modules/2.4.20-28.7/streams/
: Loading/usr/bin
: Utilities/usr/bin/polltst
: polltst/usr/bin/strtst
: strtst/usr/bin/timetst
: timetst/usr/include
: Using the Library/usr/include/LiS/stropts.h
: Using the Library/usr/include/stropts.h
: Using the Library/usr/lib
: Using the Library/usr/lib
: Libraries/usr/lib/libLiS.a
: Using the Library/usr/lib/libLiS.so
: Using the Library/usr/lib/libpLiS.so
: Using the Library/usr/sbin
: Utilities/usr/sbin/fattach
: fattach/usr/sbin/fdetach
: fdetach/usr/sbin/streams
: streams/usr/sbin/strmakenodes
: strmakenodes/usr/src/linux/Documentation/DMA-mapping.txt
: LiS PCI DMA Routines/usr/src/LiS
: Kernel Version 2.3.x/var/log/messages
: Debugging Spin LocksConfig
: strmakenodesConfig
: fifoConfig
: DriverslibLiS.a
: Using the LibrarylibLiS.so
: Using the LibrarylibpLiS.so
: Using the Libraryspecfs.o
: Filesstreams-aixcompat.o
: Filesstreams-connld.o
: Modulesstreams-hpuxcompat.o
: Filesstreams-liscompat.o
: Filesstreams-osfcompat.o
: Filesstreams-pipemod.o
: Modulesstreams-sc.o
: Modulesstreams-sth.o
: Modulesstreams-suncompat.o
: Filesstreams-svr4compat.o
: Filesstreams-uw7compat.o
: Filesstreams.o
: Filesstropts.h
: Kernel Version 2.3.xstropts.h
: Coding STREAMS Applicationsstropts.h
: Using the Librarystropts.h
: sadarch
: Configure Optionsatomic-stats
: Configure Optionsatomic-stats
: Configuring the Source RPMbase-major
: Configure Optionsbroken-cpu-flags
: Configure Optionsbroken-cpu-flags
: Configuring the Source RPMchecks
: Configure Optionschecks
: Configuring the Source RPMcompress-manpages
: Configure Optionscooked-manpages
: Configure Optionscooked-manpages
: Configuring the Source RPMdeb-epoch
: Configure Optionsdeb-release
: Configure Optionsdeb-topdir
: Configure Optionsdevel
: Configure Optionsdevel
: Configuring the Source RPMdevfs
: Configure Optionsgpg-home
: Configure Optionsgpg-user
: Configure Optionsindep
: Configure Optionsinitscripts
: Configure Optionsk-archdir
: Configure Optionsk-build
: Configure Optionsk-cache
: Configure Optionsk-cache
: Configuring the Source RPMk-config
: Configure Optionsk-debug
: Configure Optionsk-debug
: Configuring the Source RPMk-inline
: Configure Optionsk-inline
: Configuring the Source RPMk-linkage
: Configure Optionsk-machdir
: Configure Optionsk-modules
: Configure Optionsk-modversions
: Configuring the Source RPMk-optimize
: Configure Optionsk-optimize
: Configuring the Source RPMk-release
: Configure Optionsk-release
: Configuring the Source RPMk-safe
: Configure Optionsk-safe
: Configuring the Source RPMk-sysmap
: Configure Optionsk-test
: Configure Optionsk-test
: Configuring the Source RPMk-timers
: Configure Optionsk-timers
: Configuring the Source RPMlis-development
: Configure Optionslis-development
: Configuring the Source RPMlis-regparms
: Configure Optionslis-regparms
: Configuring the Source RPMmodules
: Configure Optionsmodules
: Configuring the Source RPMpkg-distdir
: Configure Optionspkg-epoch
: Configure Optionspkg-release
: Configure Optionspublic
: Configure Optionspublic
: Configuring the Source RPMrpm-epoch
: Configure Optionsrpm-extra
: Configure Optionsrpm-release
: Configure Optionsrpm-topdir
: Configure Optionssolaris-cmn_err
: Configure Optionssolaris-cmn_err
: Configuring the Source RPMsolaris-consts
: Configure Optionssolaris-consts
: Configuring the Source RPMstrconf-master
: Configure Optionstools
: Configure Optionstools
: Configuring the Source RPMuser-mode
: Configure Optionsall
: User Targetsall
: Loadingcheck
: User Targetscheck-clean
: Clean Targetscheck.log
: Logging Targetsclean
: Clean Targetscompile.log
: Logging Targetscsig
: Debian Build Targetsdebs
: Debian Build Targetsdist
: Maintainer Targetsdist.log
: Logging Targetsdistcheck
: Maintainer Targetsdistcheck.log
: Logging Targetsdistclean
: Clean Targetsdsc
: Debian Build Targetsforced-release
: Release Targetsforced-release-sign
: Release Targetsinstall
: User Targetsinstall
: Loadinginstall-strip
: User Targetsinstall-strip
: Loadinginstall.log
: Logging Targetsinstallcheck
: User Targetsinstallcheck.log
: Logging Targetsmaintainer-clean
: Clean Targetsmostlyclean
: Clean Targetspr
: Generating Problem Reportspr
: Problem Report Targetsrebuild
: RPM Build Targetsrebuild.log
: Logging Targetsrelease
: Release Targetsrelease-archives
: Release Archive Targetsrelease-clean
: Release Targetsrelease-clean-archives
: Release Archive Targetsrelease-sign
: Release Targetsrelease-sign-archives
: Release Archive Targetsrelease-sign.log
: Logging Targetsrelease.log
: Logging Targetsremove
: User Targetsremove.log
: Logging Targetsresign
: RPM Build Targetsresign.log
: Logging Targetsretest
: User Targetsrpms
: RPM Build Targetssend-pr
: Problem Report Targetssign
: RPM Build Targetssigs
: Debian Build Targetssrpm
: RPM Build Targetssrpm-sign
: RPM Build Targetssrpm.log
: Logging Targetsuninstall
: User Targetsuninstall.log
: Logging Targetsautoconf(1)
: Footnotesautoconf(1)
: User Targetsautoconf(1)
: Building from the Tar Ballautoconf(1)
: Configuring the Tar Ballautoconf(1)
: Downloading from CVSautoconf(1)
: Downloading the Tar Ballautoconf(1)
: Downloading the Debian DEBautoconf(1)
: Downloading the Binary RPMautoconf(1)
: Quick Start Guideautom4te(1)
: Environment Variablesautomake(1)
: Footnotesautomake(1)
: Footnotesautomake(1)
: Logging Targetsautomake(1)
: Clean Targetsautomake(1)
: Maintainer Targetsautomake(1)
: User Targetsautomake(1)
: Makefile Targetsautomake(1)
: Loadingautomake(1)
: Removing the Tar Ballautomake(1)
: Installing the Tar Ballautomake(1)
: Building from the Tar Ballautomake(1)
: Configure Optionsautomake(1)
: Configuring the Source RPMautomake(1)
: Downloading from CVSautoreconf(1)
: User Targetsbufcall(9)
: loop-aroundbzip2(1)
: Environment Variableschkconfig(8)
: Environment Variablescvs(1)
: Downloading from CVScvs(1)
: Quick Start Guidedepmod(8)
: Environment Variablesdevfsd(1)
: Configuring the Source RPMdevfsd(8)
: Configure Optionsdpkg(1)
: User Targetsdpkg(1)
: Environment Variablesdpkg(1)
: Configure Optionsdpkg(1)
: Downloading from CVSdpkg(1)
: Downloading the Tar Balldpkg(1)
: Downloadingdpkg(8)
: Removing the Debian DEBdpkg(8)
: Installing the Debian DEBdpkg-buildpackage(1)
: Environment Variablesdpkg-source(1)
: Environment Variableserrno(3)
: sadfattach(3)
: fattachgcc(1)
: Quick Start Guidegenksyms(8)
: Environment Variablesgenksyms(8)
: Downloading from CVSgit(1)
: Quick Start Guidegpg(1)
: Configure Optionsgrefer(1)
: Footnotesgrefer(1)
: Footnotesgrefer(1)
: Configure Optionsgrefer(1)
: Configuring the Source RPMgrefer(1)
: Downloading from CVSgroff(1)
: Footnotesgroff(1)
: Footnotesgroff(1)
: Configure Optionsgroff(1)
: Configuring the Source RPMgroff(1)
: Downloading from CVSgzip(1)
: Environment Variablesinit_install(8)
: Environment Variablesinit_remove(8)
: Environment Variablesinsmod(8)
: Building from the Tar Ballldconfig(8)
: Environment Variableslsmod(8)
: Environment Variableslsof(1)
: Environment Variablesmake(1)
: Configure Optionsmake(1)
: Downloading from CVSmakewhatis(8)
: Environment Variablesmodpost(1)
: Environment Variablesmodprobe(8)
: Environment Variablesnm(1)
: Environment Variablesobjdump(1)
: Environment Variablespic(1)
: Environment Variablespic(1)
: Configure Optionspic(1)
: Configuring the Source RPMputnext(9)
: streamsputnext(9)
: relay relay2putnext(9)
: loop-aroundputq(9)
: streamsqenable(9)
: CPU Schedulingrefer(1)
: Environment Variablesrefer(1)
: Configure Optionsrefer(1)
: Configuring the Source RPMrpm(1)
: Footnotesrpm(1)
: RPM Build Targetsrpm(1)
: Release Targetsrpm(1)
: User Targetsrpm(1)
: Removing the Binary RPMrpm(1)
: Installing the Binary RPMrpm(1)
: Building from the Source RPMrpm(1)
: Environment Variablesrpm(1)
: Configure Optionsrpm(1)
: Downloading from CVSrpm(1)
: Downloading the Tar Ballrpm(1)
: Downloadingrpm(8)
: Installing the Binary RPMrpm(8)
: Configuring the Source RPMrpmbuild(1)
: Environment Variablesrpmbuild(1)
: Configuring the Source RPMsoelim(1)
: Environment Variablessoelim(1)
: Configure Optionssoelim(1)
: Configuring the Source RPMSTREAMS(9)
: Abstractstrlog(9)
: Quick Start Guidestrtst(8)
: loop-aroundtar(1)
: Maintainer Targetstar(1)
: Downloading the Tar Balltbl(1)
: Environment Variablestbl(1)
: Configure Optionstbl(1)
: Configuring the Source RPMtee(1)
: Footnotestexinfo(1)
: Configure Optionstexinfo(1)
: Configuring the Source RPMwget(1)
: Downloading the Tar Ball[1] Formerly X/Open and UNIX International.
[2] David Grothe was the previous maintainer of the LiS-2.18 releases; however, David is no longer maintaining any version of LiS. Please do not direct maintenance requests at David.
[3] See GNU/Linux Distributions, for more information.
[4] If you are using a Debian release, please make sure to install the groff extension package (`groff_ext'), as it contains the refer or grefer commands necessary for including references in the manual pages.
[5] Please see Problem Reports, or the file PROBLEMS in the release directory for more information on filing a proper Problem Report.
[6] See GNU/Linux Distributions, for more information.
[7] If you are using a Debian release, please make sure to install the groff extension package (`groff_ext'), as it contains the refer or grefer commands necessary for including references in the manual pages.
[8] Items marked as `TBD' are scheduled to have support deprecated. That is, in a future release, the distributions marked `TBD' will not longer be validated before release.
[9] At a later date, it is possible to move this package into the kernel, however, with continued resistance to STREAMS from within the Linux developer community, this is currently unlikely.
[10] This change is far from small because it outdates libLiS.a and libLiS.so. A libLiS.a or libLiS.so from a previous version will not work correctly. All applications statically linking libLiS.a must be recompiled to use a libLiS.a from the more recent version. Unfortunately, LiS did not include versioning on its libraries. This has been corrected with the OpenSS7 release of LiS.
[11] Regparm capable architectures
are really just __i386__
and similar such as __x86_64__
and
k8
.
[12] The tirdwr
module included with the
Gcom LiS-2.16.18 (and even more current) releases is almost
completely disfunctional and has been replaced in entirety.
[13] See section NO WARRANTY under GNU General Public License.
[14] See section NO WARRANTY under GNU General Public License.
[15] Not all distributions support the `%dev' RPM macro: a case in point is the SuSE 8.0 distribution which uses an older version of rpm(1). Distributions that do not support the `%dev' macro will build devices as a `%post' operation. Note also that not all release packages contain devices. Only packages that provide STREAMS character device drivers need devices, and then only when the `specfs' or `devfsd' is not being used.
[16] Note that on Mandrakelinux, unlike other RPM kernel distributions, kernel packages for the ix86 architectures are always placed in i586 architecture packages regardless of the true processor architecture of the kernel package. configure detects this and builds the appropriate packages.
[17] Note that the `_kversion' of `2.4.20-28.7' is only an example. Note also that only release packages that contain kernel modules will contain a core subpackage.
[18] Note that only release packages that contain kernel modules and that export versioned symbols will contain a info subpackage. Also, this subpackage is only applicable to 2.4 series kernels and is not necessary and not built for 2.6 series kernels.
[19] Note that the `_kversion' of `2.4.20-28.7' is only an example.
[20] Note that not all release packages contain devices. Only packages that provide STREAMS character device drivers need devices, and then only when the `specfs' or `devfsd' is not being used.
[21] Note that not all releases have source DEB packages. Release packages that do not contain kernel modules do not generate a source DEB package.
[22] Note that on Mandrakelinux, unlike other DEB kernel distributions, kernel packages for the ix86 architectures are always placed in i586 architecture packages regardless of the true processor architecture of the kernel package. configure detects this and builds the appropriate packages.
[23] Note that the `_kversion' of `2.4.20-28.7' is only an example. Note also that only release packages that contain kernel modules will contain a core subpackage.
[24] Note that only release packages that contain kernel modules and that export versioned symbols will contain a info subpackage. Also, this subpackage is only applicable to 2.4 series kernels and is not necessary and not built for 2.6 series kernels.
[25] Note that the `_kversion' of `2.4.20-28.7' is only an example.
[26] A notable exception is Debian.
[27] Note that the `_kversion' of `2.4.20-28.7' is only an example.
[28] Note that the `_kversion' of `2.4.20-28.7' is only an example. Also, note that the `info' subpackage is only applicable to the 2.4 kernel series.
[29] In particular, some Debian systems do not load the groff(1) extensions package and do not have grefer(1) installed. Although this is an oversight on the configuration of the particular Debian system, we accomodate such misconfiguration with this feature.
[30] In particular, some Debian or Ubuntu systems do not load the groff(1) extensions package and do not have grefer(1) installed. Although this is an oversight on the configuration of the particular Debian or Ubuntu system, we accomodate such misconfiguration with this feature.
[31] Note that the `_kversion' of `2.4.20-28.7' is only an example.
[32] Note that the `_kversion' of `2.4.20-28.7' is only an example.
[33] Because it is a cross-build, the kernel version on the build machine is unlikely to be the kernel version of the target machine, except by coincidence.
[34] Although I have not tried it, because we use GNU autoconf(1) for configuration, these instructions should work equally well for the Solaris NexusWare cross-building environment as it does for the Linux NexusWare cross-building environment.
[35] Note that the `_kversion' of `2.4.20-28.7' is only an example.
[36] At some time I expect to create an `install-nexusware' target that will make the necessary modifications to the .spec and rc.4 files automatically.
[37] /usr/libexec/lis is just an example, the actual location is ${libexecdir}/${PACKAGE}, which varies from distribution to distribution (as some distributions such as Mandriva do not have a libexec directory).
[38] Therefore, it is possible to download the package, configure it, and then uninstall it. This is handy if you do not have the sources used to build and install the package immediately available.
[39] This is useful from the OpenSS7 Master Package.
[40] Theoretically this is true, however, the OpenSS7 Project does not use any maintainer programs that are not generally available (i.e. open source).
[41] Note that because logging targets invoke a pipe, automake(1) does not return the correct return status (always returns success if the tee(1) operation is successful). Therefore, these targets should not be invoked by scripts that need to use the return value from automake(1).
[42] This particular check has caught some name space pollution that has occurred in the 2.6.11 kernel.
[43] `send-pr' launches the user's EDITOR to edit the problem report before submitting it.