]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
mlx5: access ->pp through netmem_desc instead of page
authorByungchul Park <byungchul@sk.com>
Mon, 21 Jul 2025 02:18:33 +0000 (11:18 +0900)
committerJakub Kicinski <kuba@kernel.org>
Thu, 24 Jul 2025 00:46:55 +0000 (17:46 -0700)
To eliminate the use of struct page in page pool, the page pool users
should use netmem descriptor and APIs instead.

Make mlx5 access ->pp through netmem_desc instead of page.

Signed-off-by: Byungchul Park <byungchul@sk.com>
Link: https://patch.msgid.link/20250721021835.63939-11-byungchul@sk.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/mellanox/mlx5/core/en/xdp.c

index 5ce1b463b7a8dd7969e391618658d66f6e836cc1..5d51600935a6f8139d01194e770b51a3854c97a6 100644 (file)
@@ -710,7 +710,8 @@ static void mlx5e_free_xdpsq_desc(struct mlx5e_xdpsq *sq,
                                /* No need to check page_pool_page_is_pp() as we
                                 * know this is a page_pool page.
                                 */
-                               page_pool_recycle_direct(page->pp, page);
+                               page_pool_recycle_direct(pp_page_to_nmdesc(page)->pp,
+                                                        page);
                        } while (++n < num);
 
                        break;