login
Header Space

 
 

Re: [PATCH 2/5] /dev/vring: simple userspace-kernel ringbuffer interface.

Score:
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Evgeniy Polyakov <johnpol@...>
Cc: <netdev@...>, Max Krasnyansky <maxk@...>, <virtualization@...>, <linux-kernel@...>
Date: Saturday, April 19, 2008 - 12:05 pm

On Saturday 19 April 2008 20:22:15 Evgeniy Polyakov wrote:
(rusty@rustcorp.com.au) wrote:

No; it's up to the caller to make sure that they are serialized.  In the case 
of tun that happens naturally.

There are two reasons not to grab the lock.  It turns out that if we tried to 
lock here, we'd deadlock, since the callbacks are called under the lock.  
Secondly, it's possible to implement an atomic vring_used_buffer variant, 
which could fail: this would avoid using the thread most of the time.

Hope that helps,
Rusty.
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH 0/5] High-speed tun receive and xmit, Rusty Russell, (Fri Apr 18, 12:33 am)
Re: [PATCH 2/5] /dev/vring: simple userspace-kernel ringbuff..., Rusty Russell, (Sat Apr 19, 12:05 pm)
Re: [PATCH 2/5] /dev/vring: simple userspace-kernel ringbuff..., Evgeniy Polyakov, (Sat Apr 19, 12:33 pm)
[PATCH 3/5] /dev/vring limit and base ioctls, Rusty Russell, (Fri Apr 18, 12:41 am)
[PATCH 4/5] tun: vringfd receive support., Rusty Russell, (Fri Apr 18, 12:42 am)
[PATCH 5/5] tun: vringfd xmit support., Rusty Russell, (Fri Apr 18, 12:43 am)
Re: [PATCH 5/5] tun: vringfd xmit support., pradeep singh rautela, (Fri Apr 18, 7:46 am)
Re: [PATCH 5/5] tun: vringfd xmit support., Ray Lee, (Fri Apr 18, 10:25 am)
Re: [PATCH 5/5] tun: vringfd xmit support., pradeep singh rautela, (Fri Apr 18, 2:01 pm)
Re: [PATCH 5/5] tun: vringfd xmit support., Andrew Morton, (Fri Apr 18, 7:31 am)
Re: [PATCH 5/5] tun: vringfd xmit support., Rusty Russell, (Fri Apr 18, 11:15 am)
Re: [PATCH 5/5] tun: vringfd xmit support., Andrew Morton, (Fri Apr 18, 9:54 pm)
Re: [PATCH 5/5] tun: vringfd xmit support., Andrew Morton, (Fri Apr 18, 3:06 pm)
Re: [PATCH 5/5] tun: vringfd xmit support., Rusty Russell, (Sat Apr 19, 10:41 am)
Re: [PATCH 5/5] tun: vringfd xmit support., Andrew Morton, (Sat Apr 19, 1:51 pm)
Re: [PATCH 5/5] tun: vringfd xmit support., Ray Lee, (Fri Apr 18, 12:24 pm)
speck-geostationary