Re: [PATCH V2 5/6] vhost_net: poll vhost queue after marking DMA is done

2014-02-12 Thread Michael S. Tsirkin
On Wed, Feb 12, 2014 at 03:38:18PM +0800, Qin Chuanyu wrote: > another question is that vhost_zerocopy_callback is called by kfree_skb, > it may called in different thread context. > vhost_poll_queue is called decided by ubufs->kref.refcount, this may > cause there isn't any thread call vhost_poll

Re: [PATCH V2 5/6] vhost_net: poll vhost queue after marking DMA is done

2014-02-12 Thread Jason Wang
On 02/12/2014 03:38 PM, Qin Chuanyu wrote: > On 2013/8/30 12:29, Jason Wang wrote: >> We used to poll vhost queue before making DMA is done, this is racy >> if vhost >> thread were waked up before marking DMA is done which can result the >> signal to >> be missed. Fix this by always poll the vhost

Re: [PATCH V2 5/6] vhost_net: poll vhost queue after marking DMA is done

2014-02-11 Thread Qin Chuanyu
On 2013/8/30 12:29, Jason Wang wrote: We used to poll vhost queue before making DMA is done, this is racy if vhost thread were waked up before marking DMA is done which can result the signal to be missed. Fix this by always poll the vhost thread before DMA is done. Signed-off-by: Jason Wang ---

Re: [PATCH V2 5/6] vhost_net: poll vhost queue after marking DMA is done

2013-09-01 Thread Jason Wang
On 08/31/2013 12:44 AM, Ben Hutchings wrote: > On Fri, 2013-08-30 at 12:29 +0800, Jason Wang wrote: >> We used to poll vhost queue before making DMA is done, this is racy if vhost >> thread were waked up before marking DMA is done which can result the signal >> to >> be missed. Fix this by always

Re: [PATCH V2 5/6] vhost_net: poll vhost queue after marking DMA is done

2013-08-30 Thread Ben Hutchings
On Fri, 2013-08-30 at 12:29 +0800, Jason Wang wrote: > We used to poll vhost queue before making DMA is done, this is racy if vhost > thread were waked up before marking DMA is done which can result the signal to > be missed. Fix this by always poll the vhost thread before DMA is done. Does this b

[PATCH V2 5/6] vhost_net: poll vhost queue after marking DMA is done

2013-08-29 Thread Jason Wang
We used to poll vhost queue before making DMA is done, this is racy if vhost thread were waked up before marking DMA is done which can result the signal to be missed. Fix this by always poll the vhost thread before DMA is done. Signed-off-by: Jason Wang --- drivers/vhost/net.c |9 +