Re: [net-next PATCH v3 3/6] octeontx2-pf: AF_XDP zero copy receive support

From: Paolo Abeni
Date: Tue Jan 14 2025 - 07:47:01 EST


On 1/10/25 10:38 AM, Suman Ghosh wrote:
> @@ -1337,8 +1358,12 @@ void otx2_aura_pool_free(struct otx2_nic *pfvf)
> pool = &pfvf->qset.pool[pool_id];
> qmem_free(pfvf->dev, pool->stack);
> qmem_free(pfvf->dev, pool->fc_addr);
> - page_pool_destroy(pool->page_pool);
> - pool->page_pool = NULL;
> + if (pool->page_pool) {
> + page_pool_destroy(pool->page_pool);
> + pool->page_pool = NULL;
> + }

It looks like the above delta is not needed: page_pool_destroy() handles
correctly NULL value for the page pool.

/P