netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jason Wang <jasowang@redhat.com>
To: Toshiaki Makita <makita.toshiaki@lab.ntt.co.jp>,
	"David S. Miller" <davem@davemloft.net>,
	"Michael S. Tsirkin" <mst@redhat.com>
Cc: netdev@vger.kernel.org, virtualization@lists.linux-foundation.org
Subject: Re: [PATCH v2 net 7/7] virtio_net: Differentiate sk_buff and xdp_frame on freeing
Date: Tue, 29 Jan 2019 10:49:45 +0800	[thread overview]
Message-ID: <9df542d3-c0b5-5170-1913-9174a2c37a8e@redhat.com> (raw)
In-Reply-To: <5f114c25-1f42-996b-134c-962b64597e74@lab.ntt.co.jp>


On 2019/1/29 上午10:35, Toshiaki Makita wrote:
> On 2019/01/29 11:23, Jason Wang wrote:
>> On 2019/1/29 上午8:45, Toshiaki Makita wrote:
> ...
>>> @@ -2666,10 +2696,10 @@ static void free_unused_bufs(struct
>>> virtnet_info *vi)
>>>        for (i = 0; i < vi->max_queue_pairs; i++) {
>>>            struct virtqueue *vq = vi->sq[i].vq;
>>>            while ((buf = virtqueue_detach_unused_buf(vq)) != NULL) {
>>> -            if (!is_xdp_raw_buffer_queue(vi, i))
>>> +            if (!is_xdp_frame(buf))
>>
>> I believe this is the last user of is_xdp_raw_buffer_queue(), maybe you
>> can sent a patch on top to remove it.
> Actually patch2 added new users of it ;)


Right, I missed that.

Thanks


>
>>
>>>                    dev_kfree_skb(buf);
>>>                else
>>> -                xdp_return_frame(buf);
>>> +                xdp_return_frame(ptr_to_xdp(buf));
>>>            }
>>>        }
>>>    
>>
>> Acked-by: Jason Wang <jasowang@redhat.com>
>>
> Thanks!
>

  reply	other threads:[~2019-01-29  2:50 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-29  0:45 [PATCH v2 net 0/7] virtio_net: Fix problems around XDP tx and napi_tx Toshiaki Makita
2019-01-29  0:45 ` [PATCH v2 net 1/7] virtio_net: Don't enable NAPI when interface is down Toshiaki Makita
2019-01-29  0:45 ` [PATCH v2 net 2/7] virtio_net: Don't call free_old_xmit_skbs for xdp_frames Toshiaki Makita
2019-01-29  0:45 ` [PATCH v2 net 3/7] virtio_net: Fix not restoring real_num_rx_queues Toshiaki Makita
2019-01-29  0:45 ` [PATCH v2 net 4/7] virtio_net: Fix out of bounds access of sq Toshiaki Makita
2019-01-29  0:45 ` [PATCH v2 net 5/7] virtio_net: Don't process redirected XDP frames when XDP is disabled Toshiaki Makita
2019-01-29  2:20   ` Jason Wang
2019-01-29 22:50   ` Michael S. Tsirkin
2019-01-29  0:45 ` [PATCH v2 net 6/7] virtio_net: Use xdp_return_frame to free xdp_frames on destroying vqs Toshiaki Makita
2019-01-29  0:45 ` [PATCH v2 net 7/7] virtio_net: Differentiate sk_buff and xdp_frame on freeing Toshiaki Makita
2019-01-29  2:23   ` Jason Wang
2019-01-29  2:35     ` Toshiaki Makita
2019-01-29  2:49       ` Jason Wang [this message]
2019-01-29 22:51   ` Michael S. Tsirkin
2019-01-30 22:03 ` [PATCH v2 net 0/7] virtio_net: Fix problems around XDP tx and napi_tx David Miller

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=9df542d3-c0b5-5170-1913-9174a2c37a8e@redhat.com \
    --to=jasowang@redhat.com \
    --cc=davem@davemloft.net \
    --cc=makita.toshiaki@lab.ntt.co.jp \
    --cc=mst@redhat.com \
    --cc=netdev@vger.kernel.org \
    --cc=virtualization@lists.linux-foundation.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 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).