net/bnxt: support port representor data path
[dpdk.git] / drivers / net / bnxt / bnxt_rxr.h
index bf86002..e60c97f 100644 (file)
@@ -188,6 +188,7 @@ struct bnxt_sw_rx_bd {
 struct bnxt_rx_ring_info {
        uint16_t                rx_prod;
        uint16_t                ag_prod;
+       uint16_t                rx_cons; /* Needed for representor */
        struct bnxt_db_info     rx_db;
        struct bnxt_db_info     ag_db;
 
@@ -226,8 +227,10 @@ uint16_t bnxt_recv_pkts_vec(void *rx_queue, struct rte_mbuf **rx_pkts,
 int bnxt_rxq_vec_setup(struct bnxt_rx_queue *rxq);
 #endif
 
-uint32_t bnxt_get_cfa_code_or_mark_id(struct bnxt *bp,
-                                     struct rx_pkt_cmpl_hi *rxcmp1);
+void bnxt_set_mark_in_mbuf(struct bnxt *bp,
+                          struct rx_pkt_cmpl_hi *rxcmp1,
+                          struct rte_mbuf *mbuf);
+
 #define BNXT_RX_META_CFA_CODE_SHIFT            19
 #define BNXT_CFA_CODE_META_SHIFT               16
 #define BNXT_RX_META_CFA_CODE_INT_ACT_REC_BIT  0x8000000
@@ -236,5 +239,7 @@ uint32_t bnxt_get_cfa_code_or_mark_id(struct bnxt *bp,
 #define BNXT_CFA_META_FMT_SHFT                 4
 #define BNXT_CFA_META_FMT_EM_EEM_SHFT          1
 #define BNXT_CFA_META_FMT_EEM                  3
+#define BNXT_CFA_META_EEM_TCAM_SHIFT           31
+#define BNXT_CFA_META_EM_TEST(x) ((x) >> BNXT_CFA_META_EEM_TCAM_SHIFT)
 
 #endif