VOID
TdiBuildSendDatagram (
IN PIRP Irp,
IN PDEVICE_OBJECT DevObj,
IN PFILE_OBJECT FileObj,
IN PVOID CompRoutine,
IN PVOID Contxt,
IN PMDL MdlAddr,
IN ULONG SendLen,
IN PTDI_CONNECTION_INFORMATION SendDatagramInfo
);
TdiBuildSendDatagram sets up an internal device control IRP for a TDI_SEND_DATAGRAM request to the underlying transport in which the local-node client has already opened a file object representing an address.
TdiBuildSendDatagram sets IRP_MJ_INTERNAL_DEVICE_CONTROL as the MajorFunction and TDI_SEND_DATAGRAM as the MinorFunction codes in the transport's I/O stack location of the given IRP.
TDI transports never fragment datagrams. Consequently, their clients make one send-datagram request to transmit each datagram, which is associated only with the particular request for a connectionless data transfer to the given destination address. To determine the maximum possible value for SendLen, the client usually issued a preceding query-information request, set up with TdiBuildQueryInformation for any of the QType values TDI_QUERY_PROVIDER_INFO, TDI_QUERY_DATAGRAM_INFO, or TDI_QUERY_MAX_DATAGRAM_INFO.
Certain transports support broadcast and/or multicast datagram transmissions. The client of such a transport can send a datagram to a multicast or broadcast address on the remote node. However, the syntax of the multicast or broadcast address is driver-specific. The client can obtain such a transport's broadcast address by issuing a query-information request with the QType value TDI_QUERY_BROADCAST_ADDRESS.
Any connectionless transfer is inherently unreliable. The underlying transport can lose or duplicate any given datagram at the discretion of the driver writer.
When a client issues send-datagram request, the transport usually queues the request internally. Transports process send-datagram requests in FIFO order. They queue send-datagram requests separately from endpoint-to-endpoint send requests from the same client.
ClientEventChainedReceiveDatagram, ClientEventReceiveDatagram, TdiBuildInternalDeviceControlIrp, TdiBuildQueryInformation, TdiBuildReceiveDatagram, TdiBuildSend, TDI_CONNECTION_INFORMATION, TDI_SEND_DATAGRAM