Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Enumerations | Functions
vnic_rq.h File Reference
#include <linux/pci.h>
#include "vnic_dev.h"
#include "vnic_cq.h"

Go to the source code of this file.

Data Structures

struct  vnic_rq_ctrl
 
struct  vnic_rq_buf
 
struct  vnic_rq
 

Macros

#define vnic_rq_desc_avail   fnic_rq_desc_avail
 
#define vnic_rq_desc_used   fnic_rq_desc_used
 
#define vnic_rq_next_desc   fnic_rq_next_desc
 
#define vnic_rq_next_index   fnic_rq_next_index
 
#define vnic_rq_next_buf_index   fnic_rq_next_buf_index
 
#define vnic_rq_post   fnic_rq_post
 
#define vnic_rq_posting_soon   fnic_rq_posting_soon
 
#define vnic_rq_return_descs   fnic_rq_return_descs
 
#define vnic_rq_service   fnic_rq_service
 
#define vnic_rq_fill   fnic_rq_fill
 
#define vnic_rq_free   fnic_rq_free
 
#define vnic_rq_alloc   fnic_rq_alloc
 
#define vnic_rq_init   fnic_rq_init
 
#define vnic_rq_error_status   fnic_rq_error_status
 
#define vnic_rq_enable   fnic_rq_enable
 
#define vnic_rq_disable   fnic_rq_disable
 
#define vnic_rq_clean   fnic_rq_clean
 
#define VNIC_RQ_BUF_BLK_ENTRIES   64
 
#define VNIC_RQ_BUF_BLK_SZ   (VNIC_RQ_BUF_BLK_ENTRIES * sizeof(struct vnic_rq_buf))
 
#define VNIC_RQ_BUF_BLKS_NEEDED(entries)   DIV_ROUND_UP(entries, VNIC_RQ_BUF_BLK_ENTRIES)
 
#define VNIC_RQ_BUF_BLKS_MAX   VNIC_RQ_BUF_BLKS_NEEDED(4096)
 
#define VNIC_RQ_RETURN_RATE   0xf /* keep 2^n - 1 */
 

Enumerations

enum  desc_return_options { VNIC_RQ_RETURN_DESC, VNIC_RQ_DEFER_RETURN_DESC, VNIC_RQ_RETURN_DESC, VNIC_RQ_DEFER_RETURN_DESC }
 

Functions

void vnic_rq_free (struct vnic_rq *rq)
 
int vnic_rq_alloc (struct vnic_dev *vdev, struct vnic_rq *rq, unsigned int index, unsigned int desc_count, unsigned int desc_size)
 
void vnic_rq_init (struct vnic_rq *rq, unsigned int cq_index, unsigned int error_interrupt_enable, unsigned int error_interrupt_offset)
 
unsigned int vnic_rq_error_status (struct vnic_rq *rq)
 
void vnic_rq_enable (struct vnic_rq *rq)
 
int vnic_rq_disable (struct vnic_rq *rq)
 
void vnic_rq_clean (struct vnic_rq *rq, void(*buf_clean)(struct vnic_rq *rq, struct vnic_rq_buf *buf))
 

Macro Definition Documentation

#define vnic_rq_alloc   fnic_rq_alloc

Definition at line 40 of file vnic_rq.h.

#define VNIC_RQ_BUF_BLK_ENTRIES   64

Definition at line 75 of file vnic_rq.h.

#define VNIC_RQ_BUF_BLK_SZ   (VNIC_RQ_BUF_BLK_ENTRIES * sizeof(struct vnic_rq_buf))

Definition at line 76 of file vnic_rq.h.

#define VNIC_RQ_BUF_BLKS_MAX   VNIC_RQ_BUF_BLKS_NEEDED(4096)

Definition at line 80 of file vnic_rq.h.

#define VNIC_RQ_BUF_BLKS_NEEDED (   entries)    DIV_ROUND_UP(entries, VNIC_RQ_BUF_BLK_ENTRIES)

Definition at line 78 of file vnic_rq.h.

#define vnic_rq_clean   fnic_rq_clean

Definition at line 45 of file vnic_rq.h.

#define vnic_rq_desc_avail   fnic_rq_desc_avail

Definition at line 29 of file vnic_rq.h.

#define vnic_rq_desc_used   fnic_rq_desc_used

Definition at line 30 of file vnic_rq.h.

#define vnic_rq_disable   fnic_rq_disable

Definition at line 44 of file vnic_rq.h.

#define vnic_rq_enable   fnic_rq_enable

Definition at line 43 of file vnic_rq.h.

#define vnic_rq_error_status   fnic_rq_error_status

Definition at line 42 of file vnic_rq.h.

#define vnic_rq_fill   fnic_rq_fill

Definition at line 38 of file vnic_rq.h.

#define vnic_rq_free   fnic_rq_free

Definition at line 39 of file vnic_rq.h.

#define vnic_rq_init   fnic_rq_init

Definition at line 41 of file vnic_rq.h.

#define vnic_rq_next_buf_index   fnic_rq_next_buf_index

Definition at line 33 of file vnic_rq.h.

#define vnic_rq_next_desc   fnic_rq_next_desc

Definition at line 31 of file vnic_rq.h.

#define vnic_rq_next_index   fnic_rq_next_index

Definition at line 32 of file vnic_rq.h.

#define vnic_rq_post   fnic_rq_post

Definition at line 34 of file vnic_rq.h.

#define vnic_rq_posting_soon   fnic_rq_posting_soon

Definition at line 35 of file vnic_rq.h.

#define vnic_rq_return_descs   fnic_rq_return_descs

Definition at line 36 of file vnic_rq.h.

#define VNIC_RQ_RETURN_RATE   0xf /* keep 2^n - 1 */
#define vnic_rq_service   fnic_rq_service

Definition at line 37 of file vnic_rq.h.

Enumeration Type Documentation

Enumerator:
VNIC_RQ_RETURN_DESC 
VNIC_RQ_DEFER_RETURN_DESC 
VNIC_RQ_RETURN_DESC 
VNIC_RQ_DEFER_RETURN_DESC 

Definition at line 175 of file vnic_rq.h.

Function Documentation

int vnic_rq_alloc ( struct vnic_dev vdev,
struct vnic_rq rq,
unsigned int  index,
unsigned int  desc_count,
unsigned int  desc_size 
)

Definition at line 87 of file vnic_rq.c.

void vnic_rq_clean ( struct vnic_rq rq,
void(*)(struct vnic_rq *rq, struct vnic_rq_buf *buf buf_clean 
)

Definition at line 188 of file vnic_rq.c.

int vnic_rq_disable ( struct vnic_rq rq)

Definition at line 170 of file vnic_rq.c.

void vnic_rq_enable ( struct vnic_rq rq)

Definition at line 165 of file vnic_rq.c.

unsigned int vnic_rq_error_status ( struct vnic_rq rq)

Definition at line 160 of file vnic_rq.c.

void vnic_rq_free ( struct vnic_rq rq)

Definition at line 68 of file vnic_rq.c.

void vnic_rq_init ( struct vnic_rq rq,
unsigned int  cq_index,
unsigned int  error_interrupt_enable,
unsigned int  error_interrupt_offset 
)

Definition at line 140 of file vnic_rq.c.