From: Simon Horman <horms@kernel.org>
To: Jiawen Wu <jiawenwu@trustnetic.com>
Cc: netdev@vger.kernel.org, andrew+netdev@lunn.ch,
davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
pabeni@redhat.com, michal.kubiak@intel.com,
mengyuanlou@net-swift.com, duanqiangwen@net-swift.com,
stable@vger.kernel.org
Subject: Re: [PATCH net 1/3] net: libwx: remove duplicate page_pool_put_full_page()
Date: Wed, 9 Jul 2025 12:47:07 +0100 [thread overview]
Message-ID: <20250709114707.GX452973@horms.kernel.org> (raw)
In-Reply-To: <20250709064025.19436-2-jiawenwu@trustnetic.com>
On Wed, Jul 09, 2025 at 02:40:23PM +0800, Jiawen Wu wrote:
...
> diff --git a/drivers/net/ethernet/wangxun/libwx/wx_lib.c b/drivers/net/ethernet/wangxun/libwx/wx_lib.c
> index 55e252789db3..7e3d7fb61a52 100644
> --- a/drivers/net/ethernet/wangxun/libwx/wx_lib.c
> +++ b/drivers/net/ethernet/wangxun/libwx/wx_lib.c
> @@ -174,10 +174,6 @@ static void wx_dma_sync_frag(struct wx_ring *rx_ring,
> skb_frag_off(frag),
> skb_frag_size(frag),
> DMA_FROM_DEVICE);
> -
> - /* If the page was released, just unmap it. */
> - if (unlikely(WX_CB(skb)->page_released))
> - page_pool_put_full_page(rx_ring->page_pool, rx_buffer->page, false);
> }
>
> static struct wx_rx_buffer *wx_get_rx_buffer(struct wx_ring *rx_ring,
> @@ -227,10 +223,6 @@ static void wx_put_rx_buffer(struct wx_ring *rx_ring,
> struct sk_buff *skb,
> int rx_buffer_pgcnt)
> {
> - if (!IS_ERR(skb) && WX_CB(skb)->dma == rx_buffer->dma)
> - /* the page has been released from the ring */
> - WX_CB(skb)->page_released = true;
> -
> /* clear contents of rx_buffer */
> rx_buffer->page = NULL;
> rx_buffer->skb = NULL;
> @@ -2423,9 +2415,6 @@ static void wx_clean_rx_ring(struct wx_ring *rx_ring)
> if (rx_buffer->skb) {
> struct sk_buff *skb = rx_buffer->skb;
>
> - if (WX_CB(skb)->page_released)
> - page_pool_put_full_page(rx_ring->page_pool, rx_buffer->page, false);
> -
> dev_kfree_skb(skb);
> }
>
I think the page_released member of wx_cb.
It seems to be unused now.
next prev parent reply other threads:[~2025-07-09 11:47 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-09 6:40 [PATCH net 0/3] Fix Rx fatal errors Jiawen Wu
2025-07-09 6:40 ` [PATCH net 1/3] net: libwx: remove duplicate page_pool_put_full_page() Jiawen Wu
2025-07-09 11:47 ` Simon Horman [this message]
2025-07-09 6:40 ` [PATCH net 2/3] net: libwx: fix the using of Rx buffer DMA Jiawen Wu
2025-07-09 11:43 ` Simon Horman
2025-07-09 6:40 ` [PATCH net 3/3] net: libwx: properly reset Rx ring descriptor Jiawen Wu
2025-07-09 11:43 ` Simon Horman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250709114707.GX452973@horms.kernel.org \
--to=horms@kernel.org \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=duanqiangwen@net-swift.com \
--cc=edumazet@google.com \
--cc=jiawenwu@trustnetic.com \
--cc=kuba@kernel.org \
--cc=mengyuanlou@net-swift.com \
--cc=michal.kubiak@intel.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.