On Thu, Jan 09, 2025 at 12:03:24AM +0530, Suman Ghosh wrote: > For XDP, page_pool APIs are getting used now. But the memory type was > not getting set due to which XDP_REDIRECT and hence AF_XDP was not > working. This patch ads the memory type MEM_TYPE_PAGE_POOL as the memory > model of the XDP program. > > Signed-off-by: Suman Ghosh <sumang@xxxxxxxxxxx> ... > diff --git a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_txrx.c b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_txrx.c ... > @@ -109,6 +109,11 @@ static void otx2_xdp_snd_pkt_handler(struct otx2_nic *pfvf, > otx2_dma_unmap_page(pfvf, sg->dma_addr[0], > sg->size[0], DMA_TO_DEVICE); > page = virt_to_page(phys_to_virt(pa)); > + if (page->pp) { > + page_pool_recycle_direct(page->pp, page); > + return; > + } > + > put_page(page); > } > Hi Suman, It is included indirectly in the following patch, [v2 2/6] octeontx2-pf: Don't unmap page pool buffer used by XDP, but I believe you need the following in order for this to compile: #include <net/page_pool/helpers.h> ... pw-bot: changes-requested