Direct Access Transport Library Functions dateppostsend(3DAT)
NAME
dateppostsend - transfer data to the remote side
SYNOPSIS
cc [ flag... ] file... -ldat [ library... ]
#include
DATRETURN
dateppostsend (
IN DATEPHANDLE ephandle,
IN DATCOUNT numsegments,
IN DATLMRTRIPLET *localiov,
IN DATDTOCOKIE usercookie,
IN DATCOMPLETIONFLAGS completionflags
)
PARAMETERS
ephandle Handle for an instance of the Endpoint.
numsegments Number of lmrtriplets in localiov. Can
be 0 for 0 size message.
localiov I/O Vector that specifies the local
buffer that contains data to be
transferred. Can be NUL for 0 size mes-
sage.
usercookie: User-provided cookie that is returned to
the Consumer at the completion of the
send. Can be NUL.
completionflags Flags for posted Send. The default
DATCOMPLETIONDEFAULTFLAG is 0x00.
Other values are as follows:
Completion Suppression DATCOMPLETIONSUPRESFLAG
0x01 Suppress
suc-
cess-
ful
Com-
ple-
tion.
SunOS 5.11 Last change: 16 Jul 2004 1
Direct Access Transport Library Functions dateppostsend(3DAT)
Solicited Wait DATCOMPLETIONSOLICITEDWAITFLAG
0x02 Request
for
notif-
i-
ca-
tion
com-
ple-
tion
for
match-
ing
receive
on
the
other
side
of
the
con-
nec-
tion.
Notification of Completion DATCOMPLETIONUNSIGNALEDFLAG
0x04 Non-
notification
com-
ple-
tion.
Local
End-
point
must
be
con-
fig-
ured
for
Notif-
i-
ca-
tion
Suppres-
sion.
SunOS 5.11 Last change: 16 Jul 2004 2
Direct Access Transport Library Functions dateppostsend(3DAT)
Barrier Fence DATCOMPLETIONBARIERFENCEFLAG
0x08 Request
for
Bar-
rier
Fence.
DESCRIPTION
The dateppostsend() function requests a transfer of all
the data from the localiov over the connection of the
ephandle Endpoint to the remote side.
The numsegments parameter specifies the number of segments
in the localiov. The localiov segments are traversed in
the I/O Vector order until all the data is transferred.
A Consumer cannot modify the localiov or its content until
the DTO is completed. When a Consumer does not adhere to
this rule, the behavior of the Provider and the underlying
Transport is not defined. Providers that allow Consumers to
get ownership of the localiov back after the
dateppostsend() returns should document this behavior and
also specify its support in Provider attributes. This
behavior allows Consumers full control of the localiov, but
not the memory it specifies after dateppostsend()
returns. Because this behavior is not guaranteed by all Pro-
viders, portable Consumers should not rely on this behavior.
Consumers should not rely on the Provider copying localiov
information.
The DATSUCES return of the dateppostsend() is at least
the equivalent of posting a Send operation directly by
native Transport. Providers should avoid resource allocation
as part of dateppostsend() to ensure that this operation
is nonblocking and thread safe for an UpCall.
The completion of the posted Send is reported to the Consu-
mer asynchronously through a DTO Completion event based on
the specified completionflags value. The value of
DATCOMPLETION UNSIGNALEDFLAG is only valid if the End-
point Request Completion Flags
DATCOMPLETIONUNSIGNALEDFLAG. Otherwise,
DATINVALIDPARAMETER is returned.
SunOS 5.11 Last change: 16 Jul 2004 3
Direct Access Transport Library Functions dateppostsend(3DAT)
The usercookie allows Consumers to have unique identifiers
for each DTO. These identifiers are completely under user
control and are opaque to the Provider. There is no require-
ment on the Consumer that the value usercookie should be
unique for each DTO. The usercookie is returned to the Con-
sumer in the Completion event for the posted Send.
The operation is valid for the Endpoint in the
DATEPSTATECONECTED and DATEPSTATEDISCONECTED states.
If the operation returns successfully for the Endpoint in
the DATEPSTATEDISCONECTED state, the posted Send is
immediately flushed to requestevdhandle.
RETURN VALUES
DATSUCES The operation was successful.
DATINSUFICIENTRESOURCES The operation failed due to
resource limitations.
DATINVALIDPARAMETER Invalid parameter. For exam-
ple, one of the IOV segments
pointed to a memory outside
its LMR.
DATINVALIDHANDLE The ephandle parameter is
invalid.
DATINVALIDSTATE A parameter is in an invalid
state. Endpoint was not in the
DATEPSTATECONECTED or
DATEPSTATEDISCONECTED
state.
DATPROTECTIONVIOLATION Protection violation for local
or remote memory access. Pro-
tection Zone mismatch between
an LMR of one of the localiov
segments and the local End-
point.
DATPRIVILEGESVIOLATION Privileges violation for local
or remote memory access. One
of the LMRs used in localiov
was either invalid or did not
have the local read
SunOS 5.11 Last change: 16 Jul 2004 4
Direct Access Transport Library Functions dateppostsend(3DAT)
privileges.
USAGE
For best Send operation performance, the Consumer should
align each buffer segment of localiov to the Optimal Buffer
Alignment attribute of the Provider. For portable applica-
tions, the Consumer should align each buffer segment of
localiov to the DATOPTIMALALIGNMENT.
ATRIBUTES
See attributes(5) for descriptions of the following attri-
butes:
ATRIBUTE TYPE ATRIBUTE VALUE
Interface Stability Standard: uDAPL, 1.1, 1.2
MT-Level Unsafe
SEE ALSO
libdat(3LIB), attributes(5)
SunOS 5.11 Last change: 16 Jul 2004 5
|