Linux Kernel
3.7.1
|
#include <vxge-config.h>
Data Fields | |
enum vxge_hw_status(* | callback )(struct __vxge_hw_fifo *fifo_handle, void *txdlh, enum vxge_hw_fifo_tcode t_code, void *userdata, struct sk_buff ***skb_ptr, int nr_skb, int *more) |
void(* | txdl_term )(void *txdlh, enum vxge_hw_txdl_state state, void *userdata) |
void * | userdata |
u32 | per_txdl_space |
function vxge_hw_fifo_callback_f - FIFO callback. : Virtual path whose Fifo "containing" 1 or more completed descriptors. : First completed descriptor. : Pointer to per txdl space allocated : Transfer code, as per Titan User Guide. Returned by HW. : Opaque 64bit data stored by driver inside the Titan descriptor prior to posting the latter on the fifo via vxge_hw_fifo_txdl_post(). The is returned as is to the driver with each completed descriptor. : Opaque per-fifo data specified at fifo open time, via vxge_hw_vpath_open().
Fifo completion callback (type declaration). A single per-fifo callback is specified at fifo open time, via vxge_hw_vpath_open(). Typically gets called as part of the processing of the Interrupt Service Routine.
Fifo callback gets called by HW if, and only if, there is at least one new completion on a given fifo. Upon processing the first driver is supposed to continue consuming completions using:
Note that failure to process new completions in a timely fashion leads to VXGE_HW_INF_OUT_OF_DESCRIPTORS condition.
Non-zero means failure to process transmit descriptor.
In the "transmit" case the failure could happen, for instance, when the link is down, in which case Titan completes the descriptor because it is not able to send the data out.
For details please refer to Titan User Guide.
See also: vxge_hw_fifo_txdl_next_completed(), vxge_hw_fifo_txdl_term_f{}. function vxge_hw_fifo_txdl_term_f - Terminate descriptor callback. : First completed descriptor. : Pointer to per txdl space allocated : One of the enum vxge_hw_txdl_state{} enumerated states. : Per-fifo user data (a.k.a. context) specified at fifo open time, via vxge_hw_vpath_open().
Terminate descriptor callback. Unless NULL is specified in the struct vxge_hw_fifo_attr{} structure passed to vxge_hw_vpath_open()), HW invokes the callback as part of closing fifo, prior to de-allocating the ring and associated data structures (including descriptors). driver should utilize the callback to (for instance) unmap and free DMA data buffers associated with the posted (state = VXGE_HW_TXDL_STATE_POSTED) descriptors, as well as other relevant cleanup functions.
See also: struct vxge_hw_fifo_attr{} struct vxge_hw_fifo_attr - Fifo open "template". : Fifo completion callback. HW invokes the callback when there are new completions on that fifo. In many implementations the executes in the hw interrupt context. : Fifo's descriptor-terminate callback. If not NULL, HW invokes the callback when closing the corresponding fifo. See also vxge_hw_fifo_txdl_term_f{}. : User-defined "context" of that fifo. Passed back to the user as one of the , and arguments. : If specified (i.e., greater than zero): extra space reserved by HW per each transmit descriptor. Can be used to store, and retrieve on completion, information specific to the driver.
Fifo open "template". User fills the structure with fifo attributes and passes it to vxge_hw_vpath_open().
Definition at line 1815 of file vxge-config.h.
enum vxge_hw_status(* callback)(struct __vxge_hw_fifo *fifo_handle, void *txdlh, enum vxge_hw_fifo_tcode t_code, void *userdata, struct sk_buff ***skb_ptr, int nr_skb, int *more) |
Definition at line 1817 of file vxge-config.h.
u32 per_txdl_space |
Definition at line 1831 of file vxge-config.h.
Definition at line 1825 of file vxge-config.h.
void* userdata |
Definition at line 1830 of file vxge-config.h.