diff options
-rw-r--r-- | include/net/page_pool.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/include/net/page_pool.h b/include/net/page_pool.h index f09b3f1994e6..f07c518ef8a5 100644 --- a/include/net/page_pool.h +++ b/include/net/page_pool.h @@ -156,12 +156,12 @@ static inline void page_pool_recycle_direct(struct page_pool *pool, bool __page_pool_request_shutdown(struct page_pool *pool); static inline bool page_pool_request_shutdown(struct page_pool *pool) { - /* When page_pool isn't compiled-in, net/core/xdp.c doesn't - * allow registering MEM_TYPE_PAGE_POOL, but shield linker. - */ + bool safe_to_remove = false; + #ifdef CONFIG_PAGE_POOL - return __page_pool_request_shutdown(pool); + safe_to_remove = __page_pool_request_shutdown(pool); #endif + return safe_to_remove; } /* Disconnects a page (from a page_pool). API users can have a need |