Pegasus InfoCorp: Web site design and web software development company

DSEND (2)

Send and receive LAM datalink

messages.

SYNOPSIS

    #include <net.h>
    #include <events.h>
    

    int dsend (struct nmsg *header); int dtry_send (struct nmsg *header); int drecv (struct nmsg *header); int dtry_recv (struct nmsg *header);

DESCRIPTION

    These datalink functions pass a network message from one process to another and are the basis for all forms of LAM network communication. Although they can be invoked directly, they are most often called by the network and transport functions. The datalink functions do not supply message routing, buffering or packetization. The user supplies the event of the forwarding process and the message length is restricted to MAXNMSGLEN, defined in <net.h>.

    dsend() and drecv() are typically used to send messages to, or receive messages from, nearest neighbour nodes (see "Typical Usage"). dtry_send() and dtry_recv() never cause the calling process to block. The message is either immediately transferred, or an error is immediately returned, indicating that the process would have blocked. All of the functions accept a pointer to a message structure which is an extension of the local level message structure used by ksend(2) and krecv(2). The network message structure is defined in <net.h> as: