X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=drivers%2Fnet%2Fenic%2Fenic_main.c;h=07a98101985985c8ce973778b2800a0ca2a4f652;hb=e9d39be873d710e1b5d1ccf6926eca44475a6f34;hp=3b8719f89fb49afe8cc55cfc961d94015b564538;hpb=ab351fe1c95cc56f3c73066b1697f5590ef5c301;p=dpdk.git diff --git a/drivers/net/enic/enic_main.c b/drivers/net/enic/enic_main.c index 3b8719f89f..07a9810198 100644 --- a/drivers/net/enic/enic_main.c +++ b/drivers/net/enic/enic_main.c @@ -31,7 +31,6 @@ * POSSIBILITY OF SUCH DAMAGE. * */ -#ident "$Id$" #include @@ -59,6 +58,7 @@ #include "vnic_cq.h" #include "vnic_intr.h" #include "vnic_nic.h" +#include "enic_vnic_wq.h" static inline int enic_is_sriov_vf(struct enic *enic) { @@ -152,15 +152,18 @@ unsigned int enic_cleanup_wq(struct enic *enic, struct vnic_wq *wq) -1 /*wq_work_to_do*/, enic_wq_service, NULL); } +void enic_post_wq_index(struct vnic_wq *wq) +{ + enic_vnic_post_wq_index(wq); +} -int enic_send_pkt(struct enic *enic, struct vnic_wq *wq, - struct rte_mbuf *tx_pkt, unsigned short len, - uint8_t sop, uint8_t eop, - uint16_t ol_flags, uint16_t vlan_tag) +void enic_send_pkt(struct enic *enic, struct vnic_wq *wq, + struct rte_mbuf *tx_pkt, unsigned short len, + uint8_t sop, uint8_t eop, uint8_t cq_entry, + uint16_t ol_flags, uint16_t vlan_tag) { struct wq_enet_desc *desc = vnic_wq_next_desc(wq); uint16_t mss = 0; - uint8_t cq_entry = eop; uint8_t vlan_tag_insert = 0; uint64_t bus_addr = (dma_addr_t) (tx_pkt->buf_physaddr + RTE_PKTMBUF_HEADROOM); @@ -191,14 +194,12 @@ int enic_send_pkt(struct enic *enic, struct vnic_wq *wq, vlan_tag, 0 /* loopback */); - vnic_wq_post(wq, (void *)tx_pkt, bus_addr, len, - sop, eop, - 1 /*desc_skip_cnt*/, - cq_entry, - 0 /*compressed send*/, - 0 /*wrid*/); - - return 0; + enic_vnic_post_wq(wq, (void *)tx_pkt, bus_addr, len, + sop, + 1 /*desc_skip_cnt*/, + cq_entry, + 0 /*compressed send*/, + 0 /*wrid*/); } void enic_dev_stats_clear(struct enic *enic) @@ -539,7 +540,7 @@ enic_alloc_consistent(__rte_unused void *priv, size_t size, *dma_handle = 0; rz = rte_memzone_reserve_aligned((const char *)name, - size, 0, 0, ENIC_ALIGN); + size, SOCKET_ID_ANY, 0, ENIC_ALIGN); if (!rz) { pr_err("%s : Failed to allocate memory requested for %s", __func__, name);