Main Page | Data Structures | Directories | File List | Data Fields | Globals | Related Pages

viprecvdone.c File Reference

#include "vipl_priv.h"

Go to the source code of this file.

Functions

VIP_ENTRY_POINT VIP_RETURN VipRecvDone (VIP_VI_HANDLE ViHandle, VIP_DESCRIPTOR **DescriptorPtr)


Detailed Description

The VI-GM function VipRecvDone implementation.

Definition in file viprecvdone.c.


Function Documentation

VIP_ENTRY_POINT VIP_RETURN VipRecvDone VIP_VI_HANDLE  ViHandle,
VIP_DESCRIPTOR **  DescriptorPtr
 

VipRecvDone() checks the Descriptor on the head of the receive queue to see if it has been marked complete. If the receive has completed, the Descriptor is removed from the head of the queue and the address of the Descriptor is returned. A VIP_DESCRIPTOR_ERROR is returned if the operation completed with errors returned in the Descriptor status or the receive queue is empty. If the receive queue is empty, DescriptorPtr is set to NULL. VipRecvDone() is a non-blocking call. In particular, VipRecvDone() is not allowed to block behind a VipRecvWait(), even in a thread-safe implementation.

Return values:
VIP_SUCCESS A completed receive Descriptor was returned with a successful completion status.
VIP_DESCRIPTOR_ERROR If the receive queue is empty, the Descriptor pointer is set to NULL, otherwise a completed Descriptor is returned with an error completion status.
VIP_NOT_DONE No completed Descriptor was found.
VIP_INVALID_PARAMETER The VI handle was invalid.
Parameters:
ViHandle (IN) Instance of a Virtual Interface.
DescriptorPtr (OUT) Address of the Descriptor that has completed, if any.
See also:
VipPostRecv VipRecvWait
Author:
Patrick Geoffray
Version:
1.0

Definition at line 46 of file viprecvdone.c.

References VIP_NIC::lock, VIP_GM::lock, VIP_ASSERT, VIP_DEBUG, VIP_DEBUG_LABEL, VIP_DESCRIPTOR_ERROR, VIP_INVALID_PARAMETER, VIP_INVALID_VI_HANDLE, VIP_MUTEX_LOCK, VIP_MUTEX_UNLOCK, VIP_NOT_DONE, VIP_PROGRESSION, VIP_STATUS_DONE, VIP_STATUS_ERROR_MASK, and VIP_SUCCESS.

VI-GM-1.3 by Myricom © 1997-2006. Documentation generated on 20 May 2006 by doxygen 1.4.4.