Re:[PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-04-08 Thread xiaohui . xin
From: Xin Xiaohui --- Michael, This is a small patch for the write logging issue with async queue. I have made a __vhost_get_vq_desc() func which may compute the log info with any valid buffer index. The __vhost_get_vq_desc() is coming from the code in vq_get_vq_desc(). And I use it to recompute

Re: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-04-07 Thread Michael S. Tsirkin
On Wed, Apr 07, 2010 at 09:36:36AM +0800, Xin, Xiaohui wrote: > Michael, > > > For the write logging, do you have a function in hand that we can > > > recompute the log? If that, I think I can use it to recompute the > > > log info when the logging is suddenly enabled. > > > For

RE: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-04-06 Thread Xin, Xiaohui
Michael, > > For the write logging, do you have a function in hand that we can > > recompute the log? If that, I think I can use it to recompute the > > log info when the logging is suddenly enabled. > > For the outstanding requests, do you mean all the user buffers have > >

Re: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-04-06 Thread Michael S. Tsirkin
On Tue, Apr 06, 2010 at 01:46:56PM +0800, Xin, Xiaohui wrote: > Michael, > > >>> For the write logging, do you have a function in hand that we can > > >>> recompute the log? If that, I think I can use it to recompute the > > >>>log info when the logging is suddenly enabled. > > >>> For the outstand

RE: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-04-05 Thread Xin, Xiaohui
Michael, > >>> For the write logging, do you have a function in hand that we can > >>> recompute the log? If that, I think I can use it to recompute the > >>>log info when the logging is suddenly enabled. > >>> For the outstanding requests, do you mean all the user buffers have > >>>submitted befor

Re: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-04-04 Thread Michael S. Tsirkin
On Fri, Apr 02, 2010 at 10:16:16AM +0800, Xin, Xiaohui wrote: > > >> For the write logging, do you have a function in hand that we can > >> recompute the log? If that, I think I can use it to recompute the > >>log info when the logging is suddenly enabled. > >> For the outstanding requests, do you

RE: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-04-01 Thread Xin, Xiaohui
>> For the write logging, do you have a function in hand that we can >> recompute the log? If that, I think I can use it to recompute the >>log info when the logging is suddenly enabled. >> For the outstanding requests, do you mean all the user buffers have >>submitted before the logging ioctl cha

Re: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-04-01 Thread Michael S. Tsirkin
On Thu, Apr 01, 2010 at 05:14:56PM +0800, Xin Xiaohui wrote: > The vhost-net backend now only supports synchronous send/recv > operations. The patch provides multiple submits and asynchronous > notifications. This is needed for zero-copy case. > > Signed-off-by: Xin Xiaohui > --- > > Michael, >

Re:[PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-04-01 Thread Xin Xiaohui
The vhost-net backend now only supports synchronous send/recv operations. The patch provides multiple submits and asynchronous notifications. This is needed for zero-copy case. Signed-off-by: Xin Xiaohui --- Michael, Now, I made vhost to alloc/destroy the kiocb, and transfer it from sendmsg/rec

Re: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-03-17 Thread Michael S. Tsirkin
On Wed, Mar 17, 2010 at 05:48:10PM +0800, Xin, Xiaohui wrote: > >> Michael, > >> I don't use the kiocb comes from the sendmsg/recvmsg, > > >since I have embeded the kiocb in page_info structure, > > >and allocate it when page_info allocated. > > >So what I suggested was that vhost allocates and tr

RE: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-03-17 Thread Xin, Xiaohui
>> Michael, >> I don't use the kiocb comes from the sendmsg/recvmsg, > >since I have embeded the kiocb in page_info structure, > >and allocate it when page_info allocated. >So what I suggested was that vhost allocates and tracks the iocbs, and >passes them to your device with sendmsg/ recvmsg call

Re: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-03-16 Thread Michael S. Tsirkin
On Tue, Mar 16, 2010 at 05:32:17PM +0800, Xin Xiaohui wrote: > The vhost-net backend now only supports synchronous send/recv > operations. The patch provides multiple submits and asynchronous > notifications. This is needed for zero-copy case. > > Signed-off-by: Xin Xiaohui > --- > > Michael, >

Re:[PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-03-16 Thread Xin Xiaohui
The vhost-net backend now only supports synchronous send/recv operations. The patch provides multiple submits and asynchronous notifications. This is needed for zero-copy case. Signed-off-by: Xin Xiaohui --- Michael, I don't use the kiocb comes from the sendmsg/recvmsg, since I have embeded the

Re: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-03-15 Thread Michael S. Tsirkin
On Mon, Mar 15, 2010 at 04:46:50PM +0800, Xin, Xiaohui wrote: > >> +/* The structure to notify the virtqueue for async socket */ > >> +struct vhost_notifier { > >> + struct list_head list; > > >+ struct vhost_virtqueue *vq; > > >+ int head; > > >+ int size; > > >+ int log; > > >+ void *ctrl;

RE: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-03-15 Thread Xin, Xiaohui
>> +/* The structure to notify the virtqueue for async socket */ >> +struct vhost_notifier { >> +struct list_head list; > >+struct vhost_virtqueue *vq; > >+int head; > >+int size; > >+int log; > >+void *ctrl; > >+void (*dtor)(struct vhost_notifier *); > >+}; > >+ >So IM

Re: [PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-03-07 Thread Michael S. Tsirkin
> +/* The structure to notify the virtqueue for async socket */ > +struct vhost_notifier { > + struct list_head list; > + struct vhost_virtqueue *vq; > + int head; > + int size; > + int log; > + void *ctrl; > + void (*dtor)(struct vhost_notifier *); > +}; > + So IMO, th

[PATCH v1 2/3] Provides multiple submits and asynchronous notifications.

2010-03-06 Thread xiaohui . xin
From: Xin Xiaohui The vhost-net backend now only supports synchronous send/recv operations. The patch provides multiple submits and asynchronous notifications. This is needed for zero-copy case. Signed-off-by: Xin Xiaohui --- drivers/vhost/net.c | 156 +++