net: add rte prefix to ether structures
[dpdk.git] / app / test-pmd / macswap.c
index a8384d5..36d3857 100644 (file)
@@ -77,8 +77,8 @@ pkt_burst_mac_swap(struct fwd_stream *fs)
        struct rte_mbuf  *pkts_burst[MAX_PKT_BURST];
        struct rte_port  *txp;
        struct rte_mbuf  *mb;
-       struct ether_hdr *eth_hdr;
-       struct ether_addr addr;
+       struct rte_ether_hdr *eth_hdr;
+       struct rte_ether_addr addr;
        uint16_t nb_rx;
        uint16_t nb_tx;
        uint16_t i;
@@ -120,7 +120,7 @@ pkt_burst_mac_swap(struct fwd_stream *fs)
                        rte_prefetch0(rte_pktmbuf_mtod(pkts_burst[i + 1],
                                                       void *));
                mb = pkts_burst[i];
-               eth_hdr = rte_pktmbuf_mtod(mb, struct ether_hdr *);
+               eth_hdr = rte_pktmbuf_mtod(mb, struct rte_ether_hdr *);
 
                /* Swap dest and src mac addresses. */
                ether_addr_copy(&eth_hdr->d_addr, &addr);
@@ -129,7 +129,7 @@ pkt_burst_mac_swap(struct fwd_stream *fs)
 
                mb->ol_flags &= IND_ATTACHED_MBUF | EXT_ATTACHED_MBUF;
                mb->ol_flags |= ol_flags;
-               mb->l2_len = sizeof(struct ether_hdr);
+               mb->l2_len = sizeof(struct rte_ether_hdr);
                mb->l3_len = sizeof(struct ipv4_hdr);
                mb->vlan_tci = txp->tx_vlan_id;
                mb->vlan_tci_outer = txp->tx_vlan_id_outer;