net/sfc: use correct function to free scattered packet on Rx
authorAndrew Rybchenko <arybchenko@solarflare.com>
Thu, 30 Mar 2017 15:16:15 +0000 (16:16 +0100)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 4 Apr 2017 17:02:59 +0000 (19:02 +0200)
Put to mempool does not free chained segments.

Fixes: e0b063941e03 ("net/sfc: support scattered Rx DMA")
Cc: stable@dpdk.org
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
drivers/net/sfc/sfc_rx.c

index 403e991..3a0e175 100644 (file)
@@ -282,8 +282,7 @@ sfc_efx_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t nb_pkts)
 
                if (scatter_pkt != NULL) {
                        if (rte_pktmbuf_chain(scatter_pkt, m) != 0) {
-                               rte_mempool_put(rxq->refill_mb_pool,
-                                               scatter_pkt);
+                               rte_pktmbuf_free(scatter_pkt);
                                goto discard;
                        }
                        /* The packet to deliver */