[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3e4c3524-9b6a-3435-96ea-70dd65be8893@kernel.org>
Date: Thu, 31 Aug 2023 16:19:47 -0600
From: David Ahern <dsahern@...nel.org>
To: Eric Dumazet <edumazet@...gle.com>, "David S . Miller"
<davem@...emloft.net>, Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>
Cc: netdev@...r.kernel.org, eric.dumazet@...il.com,
Bailey Forrest <bcf@...gle.com>, Willem de Bruijn <willemb@...gle.com>,
Catherine Sullivan <csully@...gle.com>
Subject: Re: [PATCH net] gve: fix frag_list chaining
On 8/31/23 3:38 PM, Eric Dumazet wrote:
> gve_rx_append_frags() is able to build skbs chained with frag_list,
> like GRO engine.
>
> Problem is that shinfo->frag_list should only be used
> for the head of the chain.
>
> All other links should use skb->next pointer.
>
> Otherwise, built skbs are not valid and can cause crashes.
>
> Equivalent code in GRO (skb_gro_receive()) is:
>
> if (NAPI_GRO_CB(p)->last == p)
> skb_shinfo(p)->frag_list = skb;
> else
> NAPI_GRO_CB(p)->last->next = skb;
> NAPI_GRO_CB(p)->last = skb;
>
> Fixes: 9b8dd5e5ea48 ("gve: DQO: Add RX path")
> Signed-off-by: Eric Dumazet <edumazet@...gle.com>
> Cc: Bailey Forrest <bcf@...gle.com>
> Cc: Willem de Bruijn <willemb@...gle.com>
> Cc: Catherine Sullivan <csully@...gle.com>
> ---
> drivers/net/ethernet/google/gve/gve_rx_dqo.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
Reviewed-by: David Ahern <dsahern@...nel.org>
Powered by blists - more mailing lists