From: Alexander Lobakin <aleksander.lobakin@intel.com>
To: Bui Quang Minh <minhquangbui99@gmail.com>
Cc: <netdev@vger.kernel.org>, Alexei Starovoitov <ast@kernel.org>,
"Daniel Borkmann" <daniel@iogearbox.net>,
"David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
Jesper Dangaard Brouer <hawk@kernel.org>,
John Fastabend <john.fastabend@gmail.com>,
Eric Dumazet <edumazet@google.com>,
Paolo Abeni <pabeni@redhat.com>, Simon Horman <horms@kernel.org>,
Maciej Fijalkowski <maciej.fijalkowski@intel.com>,
<bpf@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [REPOST PATCH net-next] xsk: add missing virtual address conversion for page
Date: Wed, 21 May 2025 14:53:22 +0200 [thread overview]
Message-ID: <73e378b8-a51a-473a-a8db-c8e989e2ee0a@intel.com> (raw)
In-Reply-To: <20250521090035.92592-1-minhquangbui99@gmail.com>
From: Bui Quang Minh <minhquangbui99@gmail.com>
Date: Wed, 21 May 2025 16:00:35 +0700
> In commit 7ead4405e06f ("xsk: convert xdp_copy_frags_from_zc() to use
> page_pool_dev_alloc()"), when converting from netmem to page, I missed a
> call to page_address() around skb_frag_page(frag) to get the virtual
> address of the page. This commit uses skb_frag_address() helper to fix
> the issue.
>
> Signed-off-by: Bui Quang Minh <minhquangbui99@gmail.com>
As for the code, then:
Reviewed-by: Alexander Lobakin <aleksander.lobakin@intel.com>
But you need to add "Fixes:" tag pointing to the commit you mention.
> ---
> net/core/xdp.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/net/core/xdp.c b/net/core/xdp.c
> index e6f22ba61c1e..491334b9b8be 100644
> --- a/net/core/xdp.c
> +++ b/net/core/xdp.c
> @@ -709,8 +709,7 @@ static noinline bool xdp_copy_frags_from_zc(struct sk_buff *skb,
> return false;
> }
>
> - memcpy(page_address(page) + offset,
> - skb_frag_page(frag) + skb_frag_off(frag),
> + memcpy(page_address(page) + offset, skb_frag_address(frag),
> LARGEST_ALIGN(len));
> __skb_fill_page_desc_noacc(sinfo, i, page, offset, len);
Thanks,
Olek
prev parent reply other threads:[~2025-05-21 12:53 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-21 9:00 [REPOST PATCH net-next] xsk: add missing virtual address conversion for page Bui Quang Minh
2025-05-21 12:53 ` Alexander Lobakin [this message]
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=73e378b8-a51a-473a-a8db-c8e989e2ee0a@intel.com \
--to=aleksander.lobakin@intel.com \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hawk@kernel.org \
--cc=horms@kernel.org \
--cc=john.fastabend@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maciej.fijalkowski@intel.com \
--cc=minhquangbui99@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).