Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ tirdwr(HW) — OpenDesktop 2.0.0a

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

getmsg(S)

intro(NSL)

intro(S)

putmsg(S)

read(S)

streamio(HW)

timod(HW)

write(S)


 tirdwr(HW)                      19 June 1992                      tirdwr(HW)


 Name

    tirdwr - Transport Interface read/write interface STREAMS module

 Description

    tirdwr is a STREAMS module that provides an alternate interface to a
    transport provider which supports the Transport Layer Interface (TLI)
    functions of the Network Services library (see Section NSL).  This alter-
    nate interface allows a user to communicate with the transport protocol
    provider using the read(S) and write(S) system calls.  The putmsg(S) and
    getmsg(S) system calls may also be used.  However, putmsg and getmsg can
    only transfer data messages between user and stream.

    The tirdwr module must only be pushed (see IPUSH in streamio(STR)) onto
    a stream terminated by a transport protocol provider which supports the
    TLI.  After the tirdwr module has been pushed onto a stream, none of the
    Transport Layer Interface functions can be used.  Subsequent calls to TLI
    functions will cause an error on the stream.  Once the error is detected,
    subsequent system calls on the stream will return an error with errno set
    to EPROTO.

    The following are the actions taken by the tirdwr module when pushed on
    the stream, popped (see IPOP in streamio(STR)) off the stream, or when
    data passes through it.

    push    When the module is pushed onto a stream, it will check any exist-
            ing data destined for the user to ensure that only regular data
            messages are present.  It will ignore any messages on the stream
            that relate to process management, such as messages that generate
            signals to the user processes associated with the stream.  If any
            other messages are present, the IPUSH will return an error with
            errno set to EPROTO.

    write   The module will take the following actions on data that ori-
            ginated from a write system call:

                All messages with the exception of messages that contain con-
                trol portions (see the putmsg and getmsg system calls) will
                be transparently passed onto the module's downstream neigh-
                bor.

                Any zero length data messages will be freed by the module and
                they will not be passed onto the module's downstream neigh-
                bor.

                Any messages with control portions will generate an error,
                and any further system calls associated with the stream will
                fail with errno set to EPROTO.

    read    The module will take the following actions on data that ori-
            ginated from the transport protocol provider:

                All messages with the exception of those that contain control
                portions (see the putmsg and getmsg system calls) will be
                transparently passed onto the module's upstream neighbor.

                The action taken on messages with control portions will be as
                follows:

                    Messages that represent expedited data will generate an
                    error.  All further system calls associated with the
                    stream will fail with errno set to EPROTO.

                    Any data messages with control portions will have the
                    control portions removed from the message prior to pass-
                    ing the message to the upstream neighbor.

                    Messages that represent an orderly release indication
                    from the transport provider will generate a zero length
                    data message, indicating the end of file, which will be
                    sent to the reader of the stream.  The orderly release
                    message itself will be freed by the module.

                    Messages that represent an abortive disconnect indication
                    from the transport provider will cause all further write
                    and putmsg system calls to fail with errno set to ENXIO.
                    All further read and getmsg system calls will return zero
                    length data (indicating end of file) once all previous
                    data has been read.

                    With the exception of the above rules, all other messages
                    with control portions will generate an error and all
                    further system calls associated with the stream will fail
                    with errno set to EPROTO.

                Any zero length data messages will be freed by the module and
                they will not be passed onto the module's upstream neighbor.

    pop     When the module is popped off the stream or the stream is closed,
            the module will take the following action:

                If an orderly release indication has been previously
                received, then an orderly release request will be sent to the
                remote side of the transport connection.

 See also

    getmsg(S), intro(NSL), intro(S), putmsg(S), read(S), streamio(HW),
    timod(HW), write(S)


Typewritten Software • bear@typewritten.org • Edmonds, WA 98026