Skip to content

Commit 85720e0

Browse files
Jiawen WuPaolo Abeni
authored andcommitted
net: libwx: fix the creation of page_pool
'rx_ring->size' means the count of ring descriptors multiplied by the size of one descriptor. When increasing the count of ring descriptors, it may exceed the limit of pool size. [ 864.209610] page_pool_create_percpu() gave up with errno -7 [ 864.209613] txgbe 0000:11:00.0: Page pool creation failed: -7 Fix to set the pool_size to the count of ring descriptors. Fixes: 850b971 ("net: libwx: Allocate Rx and Tx resources") Cc: [email protected] Signed-off-by: Jiawen Wu <[email protected]> Reviewed-by: Simon Horman <[email protected]> Reviewed-by: Mina Almasry <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Paolo Abeni <[email protected]>
1 parent 8d89661 commit 85720e0

File tree

1 file changed

+1
-1
lines changed
  • drivers/net/ethernet/wangxun/libwx

1 file changed

+1
-1
lines changed

drivers/net/ethernet/wangxun/libwx/wx_lib.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2623,7 +2623,7 @@ static int wx_alloc_page_pool(struct wx_ring *rx_ring)
26232623
struct page_pool_params pp_params = {
26242624
.flags = PP_FLAG_DMA_MAP | PP_FLAG_DMA_SYNC_DEV,
26252625
.order = 0,
2626-
.pool_size = rx_ring->size,
2626+
.pool_size = rx_ring->count,
26272627
.nid = dev_to_node(rx_ring->dev),
26282628
.dev = rx_ring->dev,
26292629
.dma_dir = DMA_FROM_DEVICE,

0 commit comments

Comments
 (0)