New upstream version 16.11.5
[deb_dpdk.git] / drivers / net / enic / enic.h
index 865cd76..46f20b2 100644 (file)
 #define DRV_DESCRIPTION                "Cisco VIC Ethernet NIC Poll-mode Driver"
 #define DRV_COPYRIGHT          "Copyright 2008-2015 Cisco Systems, Inc"
 
-#define ENIC_WQ_MAX            8
-/* With Rx scatter support, we use two RQs on VIC per RQ used by app. Both
- * RQs use the same CQ.
- */
-#define ENIC_RQ_MAX            16
-#define ENIC_CQ_MAX            (ENIC_WQ_MAX + (ENIC_RQ_MAX / 2))
-#define ENIC_INTR_MAX          (ENIC_CQ_MAX + 2)
-
 #define VLAN_ETH_HLEN           18
 
 #define ENICPMD_SETTING(enic, f) ((enic->config.flags & VENETF_##f) ? 1 : 0)
@@ -102,6 +94,7 @@ struct enic_fdir {
 struct enic_soft_stats {
        rte_atomic64_t rx_nombuf;
        rte_atomic64_t rx_packet_errors;
+       rte_atomic64_t tx_oversized;
 };
 
 struct enic_memzone_entry {
@@ -138,17 +131,17 @@ struct enic {
        unsigned int flags;
        unsigned int priv_flags;
 
-       /* work queue */
-       struct vnic_wq wq[ENIC_WQ_MAX];
-       unsigned int wq_count;
+       /* work queue (len = conf_wq_count) */
+       struct vnic_wq *wq;
+       unsigned int wq_count; /* equals eth_dev nb_tx_queues */
 
-       /* receive queue */
-       struct vnic_rq rq[ENIC_RQ_MAX];
-       unsigned int rq_count;
+       /* receive queue (len = conf_rq_count) */
+       struct vnic_rq *rq;
+       unsigned int rq_count; /* equals eth_dev nb_rx_queues */
 
-       /* completion queue */
-       struct vnic_cq cq[ENIC_CQ_MAX];
-       unsigned int cq_count;
+       /* completion queue (len = conf_cq_count) */
+       struct vnic_cq *cq;
+       unsigned int cq_count; /* equals rq_count + wq_count */
 
        /* interrupt resource */
        struct vnic_intr intr;
@@ -301,8 +294,7 @@ int enic_link_update(struct enic *enic);
 void enic_fdir_info(struct enic *enic);
 void enic_fdir_info_get(struct enic *enic, struct rte_eth_fdir_info *stats);
 void copy_fltr_v1(struct filter_v2 *fltr, struct rte_eth_fdir_input *input,
-                 struct rte_eth_fdir_masks *masks);
-void copy_fltr_v2(__rte_unused struct filter_v2 *fltr,
-                 __rte_unused struct rte_eth_fdir_input *input,
                  __rte_unused struct rte_eth_fdir_masks *masks);
+void copy_fltr_v2(struct filter_v2 *fltr, struct rte_eth_fdir_input *input,
+                 struct rte_eth_fdir_masks *masks);
 #endif /* _ENIC_H_ */