[17/17] net/pfe: fix for 32 bit and PPC compilation
Checks
Commit Message
From: Sachin Saxena <sachin.saxena@nxp.com>
This patch fixes compilation for 32 bit and power PC
compiler.
Fixes: 36220514de01 ("net/pfe: add Rx/Tx")
Cc: stable@dpdk.org
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Signed-off-by: Sachin Saxena <sachin.saxena@nxp.com>
---
drivers/net/pfe/pfe_hif.c | 3 ++-
drivers/net/pfe/pfe_hif_lib.c | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
@@ -309,7 +309,8 @@ client_put_rxpacket(struct hif_rx_queue *queue,
if (readl(&desc->ctrl) & CL_DESC_OWN) {
- mbuf = rte_cpu_to_le_64(rte_pktmbuf_alloc(pool));
+ mbuf = (struct rte_mbuf *)
+ rte_cpu_to_le_64((uintptr_t)rte_pktmbuf_alloc(pool));
if (unlikely(!mbuf)) {
PFE_PMD_WARN("Buffer allocation failure\n");
return NULL;
@@ -50,7 +50,8 @@ pfe_hif_shm_init(struct hif_shm *hif_shm, struct rte_mempool *mb_pool)
hif_shm->rx_buf_pool_cnt = HIF_RX_DESC_NT;
for (i = 0; i < hif_shm->rx_buf_pool_cnt; i++) {
- mbuf = rte_cpu_to_le_64(rte_pktmbuf_alloc(mb_pool));
+ mbuf = (struct rte_mbuf *)
+ rte_cpu_to_le_64((uintptr_t)rte_pktmbuf_alloc(mb_pool));
if (mbuf)
hif_shm->rx_buf_pool[i] = mbuf;
else