/* RX descriptor control thresholds. * PTHRESH - MAC will consider prefetch if it has fewer than this number of * descriptors available in its onboard memory. * Setting this to 0 disables RX descriptor prefetch. * HTHRESH - MAC will only prefetch if there are at least this many descriptors * available in host memory. * If PTHRESH is 0, this should also be 0. * WTHRESH - RX descriptor writeback threshold - MAC will delay writing back * descriptors until either it has this many to write back, or the * ITR timer expires.
*/ #define IGBVF_RX_PTHRESH 16 #define IGBVF_RX_HTHRESH 8 #define IGBVF_RX_WTHRESH 1
/* this is the size past which hardware will drop packets when setting LPE=0 */ #define MAXIMUM_ETHERNET_VLAN_SIZE 1522
#define IGBVF_FC_PAUSE_TIME 0x0680 /* 858 usec */
/* How many Tx Descriptors do we need to call netif_wake_queue ? */ #define IGBVF_TX_QUEUE_WAKE 32 /* How many Rx Buffers do we bundle into one write to the hardware ? */ #define IGBVF_RX_BUFFER_WRITE 16 /* Must be power of 2 */
/* wrappers around a pointer to a socket buffer, * so a DMA handle can be stored along with the buffer
*/ struct igbvf_buffer {
dma_addr_t dma; struct sk_buff *skb; union { /* Tx */ struct { unsignedlong time_stamp; union e1000_adv_tx_desc *next_to_watch;
u16 length;
u16 mapped_as_page;
}; /* Rx */ struct { struct page *page;
u64 page_dma; unsignedint page_offset;
};
};
};
union igbvf_desc { union e1000_adv_rx_desc rx_desc; union e1000_adv_tx_desc tx_desc; struct e1000_adv_tx_context_desc tx_context_desc;
};
struct igbvf_ring { struct igbvf_adapter *adapter; /* backlink */ union igbvf_desc *desc; /* pointer to ring memory */
dma_addr_t dma; /* phys address of ring */ unsignedint size; /* length of ring in bytes */ unsignedint count; /* number of desc. in ring */
u16 next_to_use;
u16 next_to_clean;
u16 head;
u16 tail;
/* array of buffer information structs */ struct igbvf_buffer *buffer_info; struct napi_struct napi;
/* OS defined structs */ struct net_device *netdev; struct pci_dev *pdev;
/* structs defined in e1000_hw.h */ struct e1000_hw hw;
/* The VF counters don't clear on read so we have to get a base * count on driver start up and always subtract that base on * the first update, thus the flag..
*/ struct e1000_vf_stats stats;
u64 zero_base;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.