Skip to content

Commit 81273eb

Browse files
hramamurthy12kuba-moo
authored andcommitted
gve: unlink old napi only if page pool exists
Commit de70981 ("gve: unlink old napi when stopping a queue using queue API") unlinks the old napi when stopping a queue. But this breaks QPL mode of the driver which does not use page pool. Fix this by checking that there's a page pool associated with the ring. Cc: stable@vger.kernel.org Fixes: de70981 ("gve: unlink old napi when stopping a queue using queue API") Reviewed-by: Joshua Washington <joshwash@google.com> Signed-off-by: Harshitha Ramamurthy <hramamurthy@google.com> Reviewed-by: Simon Horman <horms@kernel.org> Link: https://patch.msgid.link/20250317214141.286854-1-hramamurthy@google.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
1 parent c60d101 commit 81273eb

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/net/ethernet/google/gve/gve_rx_dqo.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,8 @@ void gve_rx_stop_ring_dqo(struct gve_priv *priv, int idx)
114114
if (!gve_rx_was_added_to_block(priv, idx))
115115
return;
116116

117-
page_pool_disable_direct_recycling(rx->dqo.page_pool);
117+
if (rx->dqo.page_pool)
118+
page_pool_disable_direct_recycling(rx->dqo.page_pool);
118119
gve_remove_napi(priv, ntfy_idx);
119120
gve_rx_remove_from_block(priv, idx);
120121
gve_rx_reset_ring_dqo(priv, idx);

0 commit comments

Comments
 (0)