[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3554649e61063491cc3a04222c7dff68d46c2f99.camel@redhat.com>
Date: Thu, 20 Jun 2024 12:20:44 +0200
From: Paolo Abeni <pabeni@...hat.com>
To: Xuan Zhuo <xuanzhuo@...ux.alibaba.com>, netdev@...r.kernel.org
Cc: "Michael S. Tsirkin" <mst@...hat.com>, Jason Wang <jasowang@...hat.com>,
Eugenio PĂ©rez <eperezma@...hat.com>, "David S. Miller"
<davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski
<kuba@...nel.org>, Alexei Starovoitov <ast@...nel.org>, Daniel Borkmann
<daniel@...earbox.net>, Jesper Dangaard Brouer <hawk@...nel.org>, John
Fastabend <john.fastabend@...il.com>, virtualization@...ts.linux.dev,
bpf@...r.kernel.org
Subject: Re: [PATCH net-next v6 07/10] virtio_net: xsk: rx: support fill
with xsk buffer
Hi,
On Tue, 2024-06-18 at 15:56 +0800, Xuan Zhuo wrote:
> @@ -1032,6 +1034,53 @@ static void check_sq_full_and_disable(struct virtnet_info *vi,
> }
> }
>
> +static void sg_fill_dma(struct scatterlist *sg, dma_addr_t addr, u32 len)
> +{
> + sg->dma_address = addr;
> + sg->length = len;
> +}
> +
> +static int virtnet_add_recvbuf_xsk(struct virtnet_info *vi, struct receive_queue *rq,
> + struct xsk_buff_pool *pool, gfp_t gfp)
> +{
> + struct xdp_buff **xsk_buffs;
> + dma_addr_t addr;
> + u32 len, i;
> + int err = 0;
Minor nit: the reverse xmas tree order is based on the full line len,
should be:
int err = 0;
u32 len, i;
[...]
> @@ -2226,6 +2281,7 @@ static bool try_fill_recv(struct virtnet_info *vi, struct receive_queue *rq,
> u64_stats_update_end_irqrestore(&rq->stats.syncp, flags);
> }
>
> + oom = err == -ENOMEM;
> return !oom;
Minor nit: 'oom' is used only in the above to lines. You could drop
such variable and just:
return err != -ENOMEM;
Please _do not_ repost just for the above, but please include such
changes if you should repost for other reasons.
Also try to include a detailed changelog in each patch after the tag
area and a '---' separator, it will simplify the review process.
Thanks,
Paolo
Powered by blists - more mailing lists