mbuf: rename deprecated VLAN flags
[dpdk.git] / drivers / net / enic / enic_rxtx.c
index 5867acf..1d43bde 100644 (file)
@@ -243,7 +243,7 @@ enic_cq_rx_to_pkt_flags(struct cq_desc *cqd, struct rte_mbuf *mbuf)
 
        /* VLAN STRIPPED flag. The L2 packet type updated here also */
        if (bwflags & CQ_ENET_RQ_DESC_FLAGS_VLAN_STRIPPED) {
-               pkt_flags |= PKT_RX_VLAN_PKT | PKT_RX_VLAN_STRIPPED;
+               pkt_flags |= PKT_RX_VLAN | PKT_RX_VLAN_STRIPPED;
                mbuf->packet_type |= RTE_PTYPE_L2_ETHER;
        } else {
                if (vlan_tci != 0)
@@ -503,7 +503,8 @@ static inline void enic_free_wq_bufs(struct vnic_wq *wq, u16 completed_index)
                tail_idx = enic_ring_incr(desc_count, tail_idx);
        }
 
-       rte_mempool_put_bulk(pool, (void **)free, nb_free);
+       if (nb_free > 0)
+               rte_mempool_put_bulk(pool, (void **)free, nb_free);
 
        wq->tail_idx = tail_idx;
        wq->ring.desc_avail += nb_to_free;