Re: [PATCHv7] add mergeable buffers support to vhost_net

2010-05-10 Thread David Stevens
Since datalen carries the difference and will be negative by that amount from the original loop, what about just adding something like: } if (headcount) heads[headcount-1].len += datalen; [and really, headcount 0 since datalen 0, so just:

Re: [PATCHv7] add mergeable buffers support to vhost_net

2010-05-10 Thread David Stevens
netdev-ow...@vger.kernel.org wrote on 05/10/2010 10:25:57 AM: On Mon, May 10, 2010 at 10:09:03AM -0700, David Stevens wrote: Since datalen carries the difference and will be negative by that amount from the original loop, what about just adding something like

Re: [PATCHv7] add mergeable buffers support to vhost_net

2010-05-03 Thread David Stevens
Michael S. Tsirkin m...@redhat.com wrote on 05/03/2010 03:34:11 AM: On Wed, Apr 28, 2010 at 01:57:12PM -0700, David L Stevens wrote: This patch adds mergeable receive buffer support to vhost_net. Signed-off-by: David L Stevens dlstev...@us.ibm.com I've been doing some more testing

Re: [PATCHv7] add mergeable buffers support to vhost_net

2010-05-03 Thread David Stevens
Michael S. Tsirkin m...@redhat.com wrote on 05/03/2010 08:56:14 AM: On Mon, May 03, 2010 at 08:39:08AM -0700, David Stevens wrote: Michael S. Tsirkin m...@redhat.com wrote on 05/03/2010 03:34:11 AM: On Wed, Apr 28, 2010 at 01:57:12PM -0700, David L Stevens wrote: This patch adds

Re: [PATCHv7] add mergeable buffers support to vhost_net

2010-04-30 Thread David Stevens
Michael S. Tsirkin m...@redhat.com wrote on 04/29/2010 06:45:15 AM: On Wed, Apr 28, 2010 at 01:57:12PM -0700, David L Stevens wrote: This patch adds mergeable receive buffer support to vhost_net. Signed-off-by: David L Stevens dlstev...@us.ibm.com I have applied this, thanks very much!

Re: [PATCH v4] Add mergeable RX bufs support to vhost

2010-04-22 Thread David Stevens
Michael S. Tsirkin m...@redhat.com wrote on 04/22/2010 05:02:25 AM: On Mon, Apr 19, 2010 at 03:12:19PM -0700, David L Stevens wrote: This patch adds the mergeable RX buffers feature to vhost. Signed-off-by: David L Stevens dlstev...@us.ibm.com Looks pretty clean to me. Could you send

Re: [PATCH v3] Add Mergeable receive buffer support to vhost_net

2010-04-07 Thread David Stevens
Thanks! There's some whitespace damage, are you sending with your new sendmail setup? It seems to have worked for qemu patches ... Yes, I saw some line wraps in what I received, but I checked the original draft to be sure and they weren't there. Possibly from the relay; Sigh. @@

Re: [PATCH v2] Add Mergeable RX buffer feature to vhost_net

2010-03-31 Thread David Stevens
Michael S. Tsirkin m...@redhat.com wrote on 03/31/2010 05:02:28 AM: attached patch seems to be whiespace damaged as well. Does the origin pass checkpatch.pl for you? Yes, but I probably broke it in the transfer -- will be more careful with the next revision. +

Re: [RFC][ PATCH 1/3] vhost-net: support multiple buffer heads in receiver

2010-03-10 Thread David Stevens
Michael S. Tsirkin m...@redhat.com wrote on 03/07/2010 11:45:33 PM: +static int skb_head_len(struct sk_buff_head *skq) +{ + struct sk_buff *head; + + head = skb_peek(skq); + if (head) + return head-len; + return 0; +} +

Re: [RFC][ PATCH 1/3] vhost-net: support multiple buffer heads in receiver

2010-03-07 Thread David Stevens
Michael S. Tsirkin m...@redhat.com wrote on 03/07/2010 07:31:30 AM: On Tue, Mar 02, 2010 at 05:20:15PM -0700, David Stevens wrote: This patch generalizes buffer handling functions to NULL, NULL); + head.iov_base = (void *)vhost_get_vq_desc

Re: [RFC][ PATCH 2/3] vhost-net: handle vnet_hdr processing for MRG_RX_BUF

2010-03-07 Thread David Stevens
Michael S. Tsirkin m...@redhat.com wrote on 03/07/2010 08:12:29 AM: On Tue, Mar 02, 2010 at 05:20:26PM -0700, David Stevens wrote: This patch adds vnet_hdr processing for mergeable buffer support to vhost-net. Signed-off-by: David L Stevens dlstev...@us.ibm.com diff -ruN net-next

Re: [RFC][ PATCH 3/3] vhost-net: Add mergeable RX buffer support to vhost-net

2010-03-07 Thread David Stevens
Michael S. Tsirkin m...@redhat.com wrote on 03/07/2010 08:26:33 AM: On Tue, Mar 02, 2010 at 05:20:34PM -0700, David Stevens wrote: This patch glues them all together and makes sure we notify whenever we don't have enough buffers to receive a max-sized packet, and adds the feature bit

[RFC][ PATCH 3/3] vhost-net: Add mergeable RX buffer support to vhost-net

2010-03-03 Thread David Stevens
This patch glues them all together and makes sure we notify whenever we don't have enough buffers to receive a max-sized packet, and adds the feature bit. Signed-off-by: David L Stevens dlstev...@us.ibm.com diff -ruN net-next-p2/drivers/vhost/net.c net-next-p3/drivers/vhost/net.c ---

[RFC][ PATCH 2/3] vhost-net: handle vnet_hdr processing for MRG_RX_BUF

2010-03-03 Thread David Stevens
This patch adds vnet_hdr processing for mergeable buffer support to vhost-net. Signed-off-by: David L Stevens dlstev...@us.ibm.com diff -ruN net-next-p1/drivers/vhost/net.c net-next-p2/drivers/vhost/net.c --- net-next-p1/drivers/vhost/net.c 2010-03-01 11:44:22.0 -0800 +++

[RFC][ PATCH 0/3] vhost-net: Add mergeable RX buffer support to vhost-net

2010-03-03 Thread David Stevens
These patches add support for mergeable receive buffers to vhost-net, allowing it to use multiple virtio buffer heads for a single receive packet. +-DLS Signed-off-by: David L Stevens dlstev...@us.ibm.com ___

[RFC][ PATCH 1/3] vhost-net: support multiple buffer heads in receiver

2010-03-03 Thread David Stevens
This patch generalizes buffer handling functions to support multiple buffer heads. In-line for viewing, attached for applying. Signed-off-by: David L Stevens dlstev...@us.ibm.com diff -ruN net-next-p0/drivers/vhost/net.c net-next-p1/drivers/vhost/net.c --- net-next-p0/drivers/vhost/net.c

Re: [RFC][ PATCH 0/3] vhost-net: Add mergeable RX buffer support to vhost-net

2010-03-03 Thread David Stevens
Michael S. Tsirkin m...@redhat.com wrote on 03/02/2010 11:54:32 PM: On Tue, Mar 02, 2010 at 04:20:03PM -0800, David Stevens wrote: These patches add support for mergeable receive buffers to vhost-net, allowing it to use multiple virtio buffer heads for a single receive packet

Re: [RFC][ PATCH 0/3] vhost-net: Add mergeable RX buffer support to vhost-net

2010-03-03 Thread David Stevens
Interesting. Since the feature in question is billed first of all a performance optimization... By whom? Although I see some improved performance, I think its real benefit is improving memory utilization on the guest. Instead of using 75K for an ARP packet, mergeable RX buffers only uses 4K.