[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20100914190156.GA16037@redhat.com>
Date: Tue, 14 Sep 2010 21:01:56 +0200
From: "Michael S. Tsirkin" <mst@...hat.com>
To: Shirley Ma <mashirle@...ibm.com>
Cc: Arnd Bergmann <arnd@...db.de>, Avi Kivity <avi@...hat.com>,
"Xin, Xiaohui" <xiaohui.xin@...el.com>,
David Miller <davem@...emloft.net>, netdev@...r.kernel.org,
kvm@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH 2/2] macvtap: TX zero copy between guest and host
kernel
On Tue, Sep 14, 2010 at 11:49:03AM -0700, Shirley Ma wrote:
> On Tue, 2010-09-14 at 20:27 +0200, Michael S. Tsirkin wrote:
> > As others said, the harder issues for TX are in determining that it's
> > safe
> > to unpin the memory, and how much memory is it safe to pin to beging
> > with. For RX we have some more complexity.
>
> I think unpin the memory is in kfree_skb() whenever the last reference
> is gone for TX. What we discussed about here is when/how vhost get
> notified to update ring buffer descriptors. Do I misunderstand something
> here?
Right, that's a better way to put it.
> > Well it's up to you of course, but this is not what I would try:
> > if you look at the
> > patchset vhost changes is not the largest part of it,
> > so this sounds a bit like effort duplication.
> >
> > TX only is also much less interesting than full zero copy.
>
> It's not true. From the performance, TX only has gained big improvement.
> We need to identify how much gain from TX zero copy, and how much gain
> from RX zero copy.
I was speaking from the code point of view:
since we'll want both TX and RX eventually it's nice to
see that some thought was given to RX even if we only merge
TX as a first step.
>From the product POV, RX is already slower (more interrupts, etc)
than TX so speeding it up might be more important,
but I agree, every bit helps.
> > I think that you should be able to simply combine
> > the two drivers together, add an ioctl to
> > enable/disable zero copy mode of operation.
>
> That could work. But what's the purpose to have two drivers if one
> driver can handle it?
>
> Thanks
> Shirley
This was just an idea: I thought it's a good way for people interested
in this zero copy thing to combine forces and avoid making
the same mistakes, but it's not a must of course.
--
MST
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists