Re: [RFC 2/4] virtio_ring: virtqueue_disable_and_recycle let the callback detach bufs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 16 Nov 2023 16:11:13 +0800, Jason Wang <jasowang@xxxxxxxxxx> wrote:
> On Tue, Nov 14, 2023 at 7:31 PM Xuan Zhuo <xuanzhuo@xxxxxxxxxxxxxxxxx> wrote:
> >
> > Now, inside virtqueue_disable_and_recycle, the recycle() just has two
> > parameters(vq, buf) after detach operate.
> >
> > But if we are in premapped mode, we may need to get some dma info when
> > detach buf like virtqueue_get_buf_ctx_dma().
> >
> > So we call recycle directly, this callback detaches bufs self. It should
> > complete the work of detaching all the unused buffers.
> >
> > Signed-off-by: Xuan Zhuo <xuanzhuo@xxxxxxxxxxxxxxxxx>
> > ---
> >  drivers/net/virtio/main.c    | 31 ++++++++++++++++++++++---------
>
> Btw, is it better to do this before the restructure, or anything I missed?


#1 is for get_buf from virtio core.
This is for the next pacth. (get unused buf)

So this is #2.

Thanks.

>
> Thanks
>





[Index of Archives]     [KVM Development]     [Libvirt Development]     [Libvirt Users]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux