On Sunday, December 02, 2012 06:09:06 PM Michael S. Tsirkin wrote:
> On Tue, Nov 27, 2012 at 06:16:00PM +0800, Jason Wang wrote:
> > This patch implement the {set|get}_channels method of ethool to allow user
> > to change the number of queues dymaically when the device is running.
On Tuesday, November 27, 2012 08:49:19 AM Stephen Hemminger wrote:
> On Tue, 27 Nov 2012 14:45:13 +0800
>
> Jason Wang wrote:
> > On 11/27/2012 01:37 AM, Stephen Hemminger wrote:
> > > On Mon, 26 Nov 2012 15:56:52 +0800
> > >
> > > Jason Wang wrote:
On 12/03/2012 05:47 PM, Michael S. Tsirkin wrote:
> On Mon, Dec 03, 2012 at 02:05:27PM +0800, Jason Wang wrote:
>> On Monday, December 03, 2012 12:34:08 PM Rusty Russell wrote:
>>> Jason Wang writes:
>>>> +static const struct ethtool_ops virtnet_ethtool_ops;
>&
On 12/03/2012 06:14 PM, Michael S. Tsirkin wrote:
> On Tue, Nov 27, 2012 at 06:15:59PM +0800, Jason Wang wrote:
>> > - if (!try_fill_recv(&vi->rq, GFP_KERNEL))
>> > - schedule_delayed_work(&vi->rq.refill, 0);
>> > + for (i = 0; i &l
On Monday, December 03, 2012 01:18:48 PM Michael S. Tsirkin wrote:
> On Mon, Dec 03, 2012 at 01:15:01PM +0800, Jason Wang wrote:
> > > > +
> > > >
> > > > + /* Work struct for refilling if we run low on memory. */
> > > >
> > > > +
On Tuesday, December 04, 2012 02:13:11 PM Rusty Russell wrote:
> Jason Wang writes:
> > On Monday, December 03, 2012 12:25:42 PM Rusty Russell wrote:
> >> > +
> >> > +/* Work struct for refilling if we run low on memory. */
> >> > +s
On Monday, December 03, 2012 01:11:18 PM Michael S. Tsirkin wrote:
> On Mon, Dec 03, 2012 at 06:01:58PM +0800, Jason Wang wrote:
> > On 12/03/2012 05:47 PM, Michael S. Tsirkin wrote:
> > > On Mon, Dec 03, 2012 at 02:05:27PM +0800, Jason Wang wrote:
> > >> On Monday,
On Tuesday, December 04, 2012 09:35:03 AM Michael S. Tsirkin wrote:
> On Mon, Dec 03, 2012 at 06:30:49PM +0800, Jason Wang wrote:
> > On 12/03/2012 06:14 PM, Michael S. Tsirkin wrote:
> > > On Tue, Nov 27, 2012 at 06:15:59PM +0800, Jason Wang wrote:
> > >> >
ml.org/lkml/2012/6/25/120
- RFC V2: http://lwn.net/Articles/467283/
Perf Numbers:
Will do some basic test and post as a reply to this mail.
Jason Wang (3):
virtio-net: separate fields of sending/receiving queue from
virtnet_info
virtio_net: multiqueue support
virtio-net: change the nu
-off-by: Jason Wang
---
drivers/net/virtio_net.c | 271 +-
1 files changed, 149 insertions(+), 122 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c
index 8262232..266f712 100644
--- a/drivers/net/virtio_net.c
+++ b/drivers
processor id.
- smp affinity hint were set to the vcpu that owns the queue pairs.
Signed-off-by: Krishna Kumar
Signed-off-by: Jason Wang
---
drivers/net/virtio_net.c| 472 ++-
include/uapi/linux/virtio_net.h | 16 ++
2 files changed, 385 insertions
This patch implement the ethtool_{set|get}_channels method of ethool to allow
user to change the number of queues dymaically when the device is running. This
would let the user to configure it on demand.
Signed-off-by: Jason Wang
---
drivers/net/virtio_net.c | 44
On Monday, December 03, 2012 08:01:11 AM Stephen Hemminger wrote:
> On Mon, 03 Dec 2012 14:45:46 +0800
>
> Jason Wang wrote:
> > On Tuesday, November 27, 2012 08:49:19 AM Stephen Hemminger wrote:
> > > On Tue, 27 Nov 2012 14:45:13 +0800
> > >
> > > Jaso
On Tuesday, December 04, 2012 03:24:22 PM Michael S. Tsirkin wrote:
> I found some bugs, see below.
> Also some style nitpicking, this is not mandatory to address.
Thanks for the reviewing.
>
> On Tue, Dec 04, 2012 at 07:07:57PM +0800, Jason Wang wrote:
> > This addes mul
On Tuesday, December 04, 2012 03:49:59 PM Michael S. Tsirkin wrote:
> On Tue, Dec 04, 2012 at 07:07:58PM +0800, Jason Wang wrote:
> > This patch implement the ethtool_{set|get}_channels method of ethool to
> > allow user to change the number of queues dymaically when the device
On 12/04/2012 11:11 PM, Michael S. Tsirkin wrote:
> On Tue, Dec 04, 2012 at 10:45:33PM +0800, Jason Wang wrote:
>> On Tuesday, December 04, 2012 03:24:22 PM Michael S. Tsirkin wrote:
>>> I found some bugs, see below.
>>> Also some style nitpicking, this is not mandator
V2: http://lwn.net/Articles/467283/
Perf Numbers:
Will do some basic test and post as a reply to this mail.
Jason Wang (3):
virtio-net: separate fields of sending/receiving queue from
virtnet_info
virtio_net: multiqueue support
virtio-net: support changing the number of queue pairs t
-off-by: Jason Wang
---
drivers/net/virtio_net.c | 282 ++
1 files changed, 158 insertions(+), 124 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c
index 8262232..0dcaee7 100644
--- a/drivers/net/virtio_net.c
+++ b/drivers
.
- smp affinity hint to the cpu that owns the queue pairs.
This could be used with the flow steering support of the device to guarantee the
packets of a single flow is handled by the same cpu.
Signed-off-by: Krishna Kumar
Signed-off-by: Jason Wang
---
drivers/net/virtio_net.c| 473
This patch implements the ethtool_{set|get}_channels method of virtio-net to
allow user to change the number of queues when the device is running on demand.
Signed-off-by: Jason Wang
---
drivers/net/virtio_net.c | 43 +++
1 files changed, 43 insertions
-off-by: Jason Wang
---
drivers/net/virtio_net.c | 282 ++
1 files changed, 158 insertions(+), 124 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c
index 90ac97d..02a7102 100644
--- a/drivers/net/virtio_net.c
+++ b/drivers
.
- smp affinity hint to the cpu that owns the queue pairs.
This could be used with the flow steering support of the device to guarantee the
packets of a single flow is handled by the same cpu.
Signed-off-by: Krishna Kumar
Signed-off-by: Jason Wang
---
drivers/net/virtio_net.c| 473
This patch implements the ethtool_{set|get}_channels method of virtio-net to
allow user to change the number of queues when the device is running on demand.
Signed-off-by: Jason Wang
---
drivers/net/virtio_net.c | 43 +++
1 files changed, 43 insertions
On Friday, December 07, 2012 04:18:56 PM Michael S. Tsirkin wrote:
> Add multiqueue support to virtio network device.
> Add a new feature flag VIRTIO_NET_F_MQ for this feature, a new
> configuration field max_virtqueue_pairs to detect supported number of
> virtqueues as well as a new command VIRTIO
r looking at this.
> Cc: Rusty Russell
> Cc: "Michael S. Tsirkin"
> Cc: Jason Wang
> Cc: virtualization@lists.linux-foundation.org
> Cc: net...@vger.kernel.org
> Signed-off-by: Wanlong Gao
> ---
> drivers/net/virtio_net.c | 39
sabling the virtqueue
>> affinity after doing cpu hotplug.
>>
>> Cc: Rusty Russell
>> Cc: "Michael S. Tsirkin"
>> Cc: Jason Wang
>> Cc: virtualization@lists.linux-foundation.org
>> Cc: net...@vger.kernel.org
>> Signed-off-by: Wanlong Gao
On 12/26/2012 06:19 PM, Wanlong Gao wrote:
> On 12/26/2012 06:06 PM, Jason Wang wrote:
>> On 12/26/2012 03:06 PM, Wanlong Gao wrote:
>>> Add a cpu notifier to virtio-net, so that we can reset the
>>> virtqueue affinity if the cpu hotplug happens. It improve
>>>
Fix the leaking of oldubufs and fd refcnt when fail to initialized used ring.
Signed-off-by: Jason Wang
---
drivers/vhost/net.c | 14 +++---
1 files changed, 11 insertions(+), 3 deletions(-)
diff --git a/drivers/vhost/net.c b/drivers/vhost/net.c
index ebd08b2..629d6b5 100644
--- a
() report errors to the caller, which could be used
caller or userspace.
Signed-off-by: Jason Wang
---
drivers/vhost/net.c | 75 +
drivers/vhost/vhost.c | 16 +-
drivers/vhost/vhost.h | 11 ++-
3 files changed, 50 insertions
On 12/27/2012 06:01 PM, Wanlong Gao wrote:
> On 12/27/2012 02:39 PM, Jason Wang wrote:
>> > Currently, polling error were ignored in vhost. This may lead some issues
>> > (e.g
>> > kenrel crash when passing a tap fd to vhost before calling TUNSETIFF). Fix
>&g
On 12/27/2012 09:03 PM, Michael S. Tsirkin wrote:
> On Thu, Dec 27, 2012 at 02:39:20PM +0800, Jason Wang wrote:
>> Currently, polling error were ignored in vhost. This may lead some issues
>> (e.g
>> kenrel crash when passing a tap fd to vhost before calling TUNSETIFF
On 12/27/2012 09:14 PM, Michael S. Tsirkin wrote:
> On Thu, Dec 27, 2012 at 02:39:19PM +0800, Jason Wang wrote:
>> Fix the leaking of oldubufs and fd refcnt when fail to initialized used ring.
>>
>> Signed-off-by: Jason Wang
>> ---
>> drivers/vhost/net.c | 14 +
estore the state before the ioctl when vhost_init_used() fails
- log the error when meet polling errors in the data path
- don't put into waitqueue when tun_chr_poll() return POLLERR
Jason Wang (2):
vhost_net: correct error handling in vhost_net_set_backend()
vhost: handle polling error
Currently, when vhost_init_used() fails the sock refcnt and ubufs were
leaked. Correct this by calling vhost_init_used() before assign ubufs and
restore the oldsock when it fails.
Signed-off-by: Jason Wang
---
drivers/vhost/net.c | 16 +++-
1 files changed, 11 insertions(+), 5
in vhost_net since
it was replaced by the checking of poll->wqh.
Signed-off-by: Jason Wang
---
drivers/vhost/net.c | 74
drivers/vhost/vhost.c | 31 +++-
drivers/vhost/vhost.h |2 +-
3 files changed, 49 insertions(
On 01/06/2013 09:22 PM, Michael S. Tsirkin wrote:
> On Sun, Jan 06, 2013 at 03:18:38PM +0800, Jason Wang wrote:
>> Polling errors were ignored by vhost/vhost_net, this may lead to crash when
>> trying to remove vhost from waitqueue when after the polling is failed. Solve
>
tifier block to virtnet_info is suggested by
> Jason, thank you.
>
> Cc: Rusty Russell
> Cc: "Michael S. Tsirkin"
> Cc: Jason Wang
> Cc: Eric Dumazet
> Cc: virtualization@lists.linux-foundation.org
> Cc: net...@vger.kernel.org
> Signed-off-by:
On 01/07/2013 03:48 PM, Wanlong Gao wrote:
> On 01/07/2013 03:28 PM, Jason Wang wrote:
>> On 01/07/2013 03:15 PM, Wanlong Gao wrote:
>>> Add a cpu notifier to virtio-net, so that we can reset the
>>> virtqueue affinity if the cpu hotplug happens. It improve
>>>
On 01/07/2013 10:55 PM, Michael S. Tsirkin wrote:
> On Mon, Jan 07, 2013 at 12:38:17PM +0800, Jason Wang wrote:
>> On 01/06/2013 09:22 PM, Michael S. Tsirkin wrote:
>>> On Sun, Jan 06, 2013 at 03:18:38PM +0800, Jason Wang wrote:
>>>> Polling errors were ignored by vho
from CPU to the preferable virtual-queue.
>
> Cc: Rusty Russell
> Cc: "Michael S. Tsirkin"
> Cc: Jason Wang
> Cc: Eric Dumazet
> Cc: virtualization@lists.linux-foundation.org
> Cc: net...@vger.kernel.org
> Signed-off-by: Wanlo
On 01/09/2013 09:52 AM, Wanlong Gao wrote:
> On 01/08/2013 06:26 PM, Jason Wang wrote:
>> On 01/08/2013 06:07 PM, Wanlong Gao wrote:
>>> As Michael mentioned, set affinity and select queue will not work very
>>> well when CPU IDs are not consecutive, this can happen wi
On 01/10/2013 10:45 PM, ak...@redhat.com wrote:
> From: Amos Kong
>
> We will send vq command to set mac address in virtnet_set_mac_address()
> a little fix of coding style
Maybe what you need is just a forward declaration.
>
> Signed-off-by: Amos Kong
> ---
> drivers/net/virtio_net.c | 89
> +
On 01/10/2013 10:45 PM, ak...@redhat.com wrote:
> From: Amos Kong
>
> Currently we write MAC address to pci config space byte by byte,
> this means that we have an intermediate step where mac is wrong.
> This patch introduced a new control command to set MAC address
> in one time.
>
> VIRTIO_NET_F
On 01/11/2013 03:12 AM, Ben Hutchings wrote:
> On Thu, 2013-01-10 at 11:19 +1030, Rusty Russell wrote:
>> Wanlong Gao writes:
>>> On 01/09/2013 07:31 AM, Rusty Russell wrote:
Wanlong Gao writes:
> */
> static u16 virtnet_select_queue(struct net_device *dev, struct sk_buff
> *
from CPU to the preferable virtual-queue.
Looks like ixgbe is trying to handling a similar issue recently by
trying to reuse XPS when the channels and cpus are not equal. I wonder
whether we can use the same method.
>
> Cc: Rusty Russell
> Cc: "Michael S. Tsirkin"
> Cc: Ja
On 01/13/2013 07:10 PM, Michael S. Tsirkin wrote:
> On Mon, Jan 07, 2013 at 11:04:32PM +0800, Jason Wang wrote:
>> On 01/07/2013 10:55 PM, Michael S. Tsirkin wrote:
>>> On Mon, Jan 07, 2013 at 12:38:17PM +0800, Jason Wang wrote:
>>>> On 01/06/2013 09:22 PM, Michael
On 01/14/2013 02:57 PM, Michael S. Tsirkin wrote:
> On Mon, Jan 14, 2013 at 10:59:02AM +0800, Jason Wang wrote:
>> On 01/13/2013 07:10 PM, Michael S. Tsirkin wrote:
>>> On Mon, Jan 07, 2013 at 11:04:32PM +0800, Jason Wang wrote:
>>>> On 01/07/2013 10:55 PM, Michael
On Wednesday, January 16, 2013 01:57:01 PM ak...@redhat.com wrote:
> From: Amos Kong
>
> Currently we write MAC address to pci config space byte by byte,
> this means that we have an intermediate step where mac is wrong.
> This patch introduced a new control command to set MAC address
> in one ti
On Wednesday, January 16, 2013 02:16:47 PM ak...@redhat.com wrote:
> From: Amos Kong
>
> In virtio-net guest driver, currently we write MAC address to
> pci config space byte by byte, this means that we have an
> intermediate step where mac is wrong. This patch introduced
> a new control command
from CPU to the preferable virtual-queue.
>
> Cc: Rusty Russell
> Cc: "Michael S. Tsirkin"
> Cc: Jason Wang
> Cc: Eric Dumazet
> Cc: virtualization@lists.linux-foundation.org
> Cc: net...@vger.kernel.org
> Signed-off-by: Wanlong Gao
> ---
> V4->V5:
usty Russell
> Cc: "Michael S. Tsirkin"
> Cc: Jason Wang
> Cc: Eric Dumazet
> Cc: virtualization@lists.linux-foundation.org
> Cc: net...@vger.kernel.org
> Signed-off-by: Wanlong Gao
> ---
> V4->V5:
> New method to deal with the cpu
On 01/18/2013 02:25 PM, Wanlong Gao wrote:
> On 01/18/2013 02:18 PM, Jason Wang wrote:
>> On 01/18/2013 01:32 PM, Wanlong Gao wrote:
>>> As Michael mentioned, set affinity and select queue will not work very
>>> well when CPU IDs are not consecutive, this can happen wi
from CPU to the preferable virtual-queue.
>
> Cc: Rusty Russell
> Cc: "Michael S. Tsirkin"
> Cc: Jason Wang
> Cc: Eric Dumazet
> Cc: virtualization@lists.linux-foundation.org
> Cc: net...@vger.kernel.org
> Signed-off-by: Wanlong Gao
> ---
> V5->V6:
&g
On 01/21/2013 07:25 PM, Wanlong Gao wrote:
> Split out the clean affinity function to virtnet_clean_affinity().
>
> Cc: Rusty Russell
> Cc: "Michael S. Tsirkin"
> Cc: Jason Wang
> Cc: Eric Dumazet
> Cc: virtualization@lists.linux-foundation.org
> Cc: net.
On 01/25/2013 12:20 PM, Wanlong Gao wrote:
> On 01/25/2013 11:28 AM, Jason Wang wrote:
>> On 01/21/2013 07:25 PM, Wanlong Gao wrote:
>>> Split out the clean affinity function to virtnet_clean_affinity().
>>>
>>> Cc: Rusty Russell
>>> Cc: "Mic
On 01/25/2013 01:40 PM, Wanlong Gao wrote:
> On 01/25/2013 01:13 PM, Jason Wang wrote:
>> On 01/25/2013 12:20 PM, Wanlong Gao wrote:
>>> On 01/25/2013 11:28 AM, Jason Wang wrote:
>>>> On 01/21/2013 07:25 PM, Wanlong Gao wrote:
>>>>> Split out the clea
On 01/25/2013 02:42 PM, Wanlong Gao wrote:
> On 01/25/2013 02:12 PM, Jason Wang wrote:
>> On 01/25/2013 01:40 PM, Wanlong Gao wrote:
>>> On 01/25/2013 01:13 PM, Jason Wang wrote:
>>>> On 01/25/2013 12:20 PM, Wanlong Gao wrote:
>>>>> On 01/25/2013 11:28
from CPU to the preferable virtual-queue.
>
> Cc: Rusty Russell
> Cc: "Michael S. Tsirkin"
> Cc: Jason Wang
> Cc: Eric Dumazet
> Cc: "David S. Miller"
> Cc: virtualization@lists.linux-foundation.org
> Cc: net...@vger.kernel.org
> Signed-off-by:
On 01/25/2013 05:05 PM, Wanlong Gao wrote:
> On 01/25/2013 05:00 PM, Jason Wang wrote:
>> On 01/25/2013 04:36 PM, Wanlong Gao wrote:
>>> As Michael mentioned, set affinity and select queue will not work very
>>> well when CPU IDs are not consecutive, this can happen wi
On 02/21/2013 04:30 PM, Wanlong Gao wrote:
> On 02/19/2013 03:56 PM, Rusty Russell wrote:
>> It's a bit cleaner to hand multiple sgs, rather than one big one.
>>
>> Signed-off-by: Rusty Russell
>> ---
>> drivers/net/virtio_net.c | 50
>> ++
>> 1 file
simpler.
Signed-off-by: Jason Wang
---
drivers/vhost/net.c | 60
drivers/vhost/vhost.c |3 ++
2 files changed, 13 insertions(+), 50 deletions(-)
diff --git a/drivers/vhost/net.c b/drivers/vhost/net.c
index 959b1cd..d1a03dd 100644
--- a
On 03/11/2013 12:50 AM, Michael S. Tsirkin wrote:
> On Thu, Mar 07, 2013 at 12:31:56PM +0800, Jason Wang wrote:
>> After commit 2b8b328b61c799957a456a5a8dab8cc7dea68575 (vhost_net: handle
>> polling
>> errors when setting backend), we in fact track the polling state thr
On 03/11/2013 03:09 PM, Jason Wang wrote:
> On 03/11/2013 12:50 AM, Michael S. Tsirkin wrote:
>> On Thu, Mar 07, 2013 at 12:31:56PM +0800, Jason Wang wrote:
>>> After commit 2b8b328b61c799957a456a5a8dab8cc7dea68575 (vhost_net: handle
>>> polling
>>> errors whe
On 03/11/2013 04:29 PM, Michael S. Tsirkin wrote:
> On Mon, Mar 11, 2013 at 03:09:10PM +0800, Jason Wang wrote:
>> On 03/11/2013 12:50 AM, Michael S. Tsirkin wrote:
>>> On Thu, Mar 07, 2013 at 12:31:56PM +0800, Jason Wang wrote:
>>>> After commit 2b8b328b61c799957a456
18.36/3230.11/+3.6% |
zerocopy enabled:
sessions|transaction rates|normalize|
before/after/+improvements
1 | 7318.33/11929.76/+63.0%| 521.86/843.30/+61.6% |
25| 167264.88/242422.15/+44.9% | 2181.60/2788.16/+27.8% |
50| 272181.02/294347.04/+8.1% | 3071.56/3257.85/+6.1% |
Signed-off-b
On 05/07/2013 08:44 PM, Michael S. Tsirkin wrote:
> On Tue, May 07, 2013 at 02:13:44PM +0930, Rusty Russell wrote:
>> "Michael S. Tsirkin" writes:
>>> On Mon, May 06, 2013 at 03:41:36PM +0930, Rusty Russell wrote:
Asias He writes:
> Asias He (3):
> vhost: Remove vhost_enable_zcopy
virtualization@lists.linux-foundation.org;
> k...@vger.kernel.org; net...@vger.kernel.org; linux-ker...@vger.kernel.org;
> Jason Wang
> Subject: Re: [PATCH] virtio-net: Reporting traffic queue distribution
> statistics through ethtool
>
> On Sun, May 19, 2013 at 04:09:48PM +, Narasim
@vger.kernel.org; net...@vger.kernel.org; linux-ker...@vger.kernel.org;
> Jason Wang
> Subject: Re: [PATCH] virtio-net: Reporting traffic queue distribution
> statistics through ethtool
>
> On Sun, May 19, 2013 at 10:56:16PM +, Narasimhan, Sriram wrote:
>> Hi Michael,
&g
Commit 55257d72bd1c51f25106350f4983ec19f62ed1fa (virtio-net: fill only rx
queues which are being used) forgets to enable napi for new enabled queues which
breaks the multiqueue receiving. This patch fixes it.
Cc: Sasha Levin
Signed-off-by: Jason Wang
---
drivers/net/virtio_net.c |4 +++-
1
On 05/22/2013 01:22 PM, Jason Wang wrote:
> Commit 55257d72bd1c51f25106350f4983ec19f62ed1fa (virtio-net: fill only rx
> queues which are being used) forgets to enable napi for new enabled queues
> which
> breaks the multiqueue receiving. This patch fixes it.
>
> Cc: Sasha Levi
fixes this by enabling napi for all possible queues during open.
Cc: Sasha Levin
Signed-off-by: Jason Wang
---
Changes from V1:
- enable napi in open instead of virtnet_set_queues() to avoid kernel BUG() when
trying to do napi_enable() for a already enabled queue
---
drivers/net/virtio_net.c
On 05/23/2013 04:50 PM, Michael S. Tsirkin wrote:
> Hey guys,
> I've updated the kvm networking todo wiki with current projects.
> Will try to keep it up to date more often.
> Original announcement below.
Thanks a lot. I've added the tasks I'm currently working on to the wiki.
btw. I notice the v
4/0x160
> [] register_virtio_driver+0x20/0x40
>
> v2: change msix_vectors uncoditionaly in vp_free_vectors
>
> Cc: Rusty Russell
> Cc: "Michael S. Tsirkin"
> Cc: Jason Wang
> Signed-off-by: Andrew Vagin
> Signed-off-by: Andrey Vagin
> ---
> driver
&vq->mutex);
> vhost_zerocopy_signal_used(n, vq);
> mutex_unlock(&vq->mutex);
> @@ -1091,7 +1096,7 @@ err_used:
> vq->private_data = oldsock;
> vhost_net_enable_vq(n, vq);
> if (ubufs)
> - vhost_net_ubuf_pu
Signed-off-by: Jason Wang
---
drivers/net/virtio_net.c |5 +
1 files changed, 1 insertions(+), 4 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c
index c9e0038..47b4882 100644
--- a/drivers/net/virtio_net.c
+++ b/drivers/net/virtio_net.c
@@ -901,7 +901,6
t be able to get rid of a
> barrier here. Deferring this optimization until we do some
> benchmarking.
>
> Signed-off-by: Michael S. Tsirkin
> ---
Tested-by: Jason Wang
Acked-by: Jason Wang
> drivers/virtio/virtio_ring.c | 56
> ++--
n particular, used event can move backwards,
> causing us to lose interrupts.
> In a debug build, this can trigger panic within START_USE.
>
> Jason Wang reports that he can trigger the races artificially,
> by adding udelay() in virtqueue_enable_cb() after virtio_mb().
>
> Howev
On 07/19/2013 04:16 AM, Amit Shah wrote:
> We used to keep the port's char device structs and the /sys entries
> around till the last reference to the port was dropped. This is
> actually unnecessary, and resulted in buggy behaviour:
>
> 1. Open port in guest
> 2. Hot-unplug port
> 3. Hot-plug a p
On 07/19/2013 04:16 AM, Amit Shah wrote:
> If a port gets unplugged while a user is blocked on read(), -ENODEV is
> returned. However, subsequent read()s returned 0, indicating there's no
> host-side connection (but not indicating the device went away).
>
> This also happened when a port was unplu
On 07/19/2013 01:02 PM, Amit Shah wrote:
> On (Fri) 19 Jul 2013 [11:21:47], Jason Wang wrote:
>> On 07/19/2013 04:16 AM, Amit Shah wrote:
>
>>> diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c
>>> index b04ec95..6bf0df3 100644
>>&
On 07/19/2013 01:45 PM, Amit Shah wrote:
> On (Fri) 19 Jul 2013 [13:07:49], Jason Wang wrote:
>> On 07/19/2013 04:16 AM, Amit Shah wrote:
>>> If a port gets unplugged while a user is blocked on read(), -ENODEV is
>>> returned. However, subsequent read()s returned 0, ind
On 07/19/2013 04:16 AM, Amit Shah wrote:
> Between poll() being called and processed, the port can be unplugged.
> Check if this happened, and bail out.
>
> Signed-off-by: Amit Shah
> ---
> drivers/char/virtio_console.c | 4
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/char/vir
On 07/19/2013 03:48 PM, Amit Shah wrote:
> On (Fri) 19 Jul 2013 [15:03:50], Jason Wang wrote:
>> On 07/19/2013 04:16 AM, Amit Shah wrote:
>>> Between poll() being called and processed, the port can be unplugged.
>>> Check if this happened, and bail out.
>&
to stable, and to me it
> looks like all are stable candidates.
>
> v2
> * add patch 11: Jason found a use-after-free in port unplug
> * patch 7 introduced a regression where the wake_up_interruptible was
>done before guest_connected and host_connected were set to false
>
>
On 07/22/2013 01:45 PM, Rusty Russell wrote:
> Amit Shah writes:
>> On (Fri) 19 Jul 2013 [18:17:32], Jason Wang wrote:
>>> On 07/19/2013 03:48 PM, Amit Shah wrote:
>>>> On (Fri) 19 Jul 2013 [15:03:50], Jason Wang wrote:
>>>>> On 07/19/2013 04:16 AM,
On 07/23/2013 01:26 PM, Rusty Russell wrote:
> Jason Wang writes:
>> On 07/22/2013 01:45 PM, Rusty Russell wrote:
>>> Amit Shah writes:
>>>> On (Fri) 19 Jul 2013 [18:17:32], Jason Wang wrote:
>>>>> On 07/19/2013 03:48 PM, Amit Shah wrote:
>>>
ned-off-by: Jason Wang
---
arch/x86/include/asm/xen/hypervisor.h | 16 +---
1 files changed, 1 insertions(+), 15 deletions(-)
diff --git a/arch/x86/include/asm/xen/hypervisor.h
b/arch/x86/include/asm/xen/hypervisor.h
index 125f344..d866959 100644
--- a/arch/x86/include/asm/xen/hy
Tosatti
Cc: Gleb Natapov
Cc: Paolo Bonzini
Cc: Frederic Weisbecker
Cc: linux-ker...@vger.kernel.org
Cc: de...@linuxdriverproject.org
Cc: k...@vger.kernel.org
Cc: xen-de...@lists.xensource.com
Cc: virtualization@lists.linux-foundation.org
Signed-off-by: Jason Wang
---
arch/x86/include/asm
: Jason Wang
---
arch/x86/include/asm/xen/hypervisor.h | 16 +---
1 files changed, 1 insertions(+), 15 deletions(-)
diff --git a/arch/x86/include/asm/xen/hypervisor.h
b/arch/x86/include/asm/xen/hypervisor.h
index 125f344..d866959 100644
--- a/arch/x86/include/asm/xen/hypervisor.h
On 07/25/2013 04:54 PM, Jason Wang wrote:
> We try to handle the hypervisor compatibility mode by detecting hypervisor
> through a specific order. This is not robust, since hypervisors may implement
> each others features.
>
> This patch tries to handle this situation by always ch
None of its caller use its return value, so let it return void.
Signed-off-by: Jason Wang
---
drivers/vhost/net.c |5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/vhost/net.c b/drivers/vhost/net.c
index 969a859..280ee66 100644
--- a/drivers/vhost/net.c
+++ b
Hi all:
This series tries to unify and simplify vhost codes especially for zerocopy.
Plase review.
Thanks
Jason Wang (6):
vhost_net: make vhost_zerocopy_signal_used() returns void
vhost_net: use vhost_add_used_and_signal_n() in
vhost_zerocopy_signal_used()
vhost: switch to use
Switch to use vhost_add_used_and_signal_n() to avoid multiple calls to
vhost_add_used_and_signal(). With the patch we will call at most 2 times
(consider done_idx warp around) compared to N times w/o this patch.
Signed-off-by: Jason Wang
---
drivers/vhost/net.c | 13 -
1 files
Currently, even if the packet length is smaller than VHOST_GOODCOPY_LEN, if
upend_idx != done_idx we still set zcopy_used to true and rollback this choice
later. This could be avoided by determine zerocopy once by checking all
conditions at one time before.
Signed-off-by: Jason Wang
---
drivers
Let vhost_add_used() to use vhost_add_used_n() to reduce the code duplication.
Signed-off-by: Jason Wang
---
drivers/vhost/vhost.c | 43 ++-
1 files changed, 2 insertions(+), 41 deletions(-)
diff --git a/drivers/vhost/vhost.c b/drivers/vhost/vhost.c
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
oming from guest. Guest can easily exceeds the limitation.
- We've already check upend_idx != done_idx and switch to non zerocopy then. So
even if all vq->heads were used, we can still does the packet transmission.
So remove this check completely.
Signed-off-by: Jason Wang
---
driver
On 08/16/2013 05:54 PM, Michael S. Tsirkin wrote:
> On Fri, Aug 16, 2013 at 01:16:26PM +0800, Jason Wang wrote:
>> > Switch to use vhost_add_used_and_signal_n() to avoid multiple calls to
>> > vhost_add_used_and_signal(). With the patch we will call at most 2 times
>>
On 08/16/2013 05:56 PM, Michael S. Tsirkin wrote:
> On Fri, Aug 16, 2013 at 01:16:27PM +0800, Jason Wang wrote:
>> > Let vhost_add_used() to use vhost_add_used_n() to reduce the code
>> > duplication.
>> >
>> > Signed-off-by: Jason Wang
> Does compiler
On 08/16/2013 06:00 PM, Michael S. Tsirkin wrote:
> On Fri, Aug 16, 2013 at 01:16:29PM +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
>>
401 - 500 of 5822 matches
Mail list logo