All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gregory Haskins <ghaskins@novell.com>
To: "Michael S. Tsirkin" <mst@redhat.com>
Cc: alacrityvm-devel@lists.sourceforge.net, herbert.xu@redhat.com,
	linux-kernel@vger.kernel.org, netdev@vger.kernel.org
Subject: Re: [RFC PATCH] net: add dataref destructor to sk_buff
Date: Tue, 10 Nov 2009 13:36:23 -0500	[thread overview]
Message-ID: <4AF9B2A7.3050802@novell.com> (raw)
In-Reply-To: <20091110173644.GA8888@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 1394 bytes --]

Michael S. Tsirkin wrote:
> On Tue, Nov 10, 2009 at 10:45:16AM -0500, Gregory Haskins wrote:
>> I am not a stack expert, but I was under the impression that we use this
>> model for userspace pages today as well using the wmem callbacks in
>> skb->destructor().  If so, I do not see how you could do something like
>> detach a page from a pskb and still expect to have a proper event that
>> delineates the io-completion to the higher layers.
> 
> I think linux only cares about that for accounting purposes (stuff like
> socket sndbuff size). If someone takes over the page, the socket can
> stop worrying about it.

Only if there isn't zero-copy.

> 
>> So the questions are:
>>
>> 1) do we in fact map userspace pages to pskbs today?
> 
> I don't think so.

What about things like sendfile()?  There has to be *some* way to
synchronize with the io-completion event,  I would think.  Whatever that
is, I'd like to tap into it.

>>> which pages?
>>
>> You said that there are paths that get_page() out of shinfo without
>> holding a shinfo reference.
> 
> Without zero copy, application does not care about these,
> they have been allocated by kernel.

Agreed in the non-zero copy case.  I am not yet convinced that we do not
do zero copy in some form, however. Ill have to dig through the code
when I get a chance to confirm.

Kind Regards,
-Greg




[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 267 bytes --]

  reply	other threads:[~2009-11-10 18:36 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-02 14:20 [RFC PATCH] net: add dataref destructor to sk_buff Gregory Haskins
2009-11-06  5:08 ` David Miller
2009-11-06 16:08   ` Gregory Haskins
2009-11-10 11:53 ` Michael S. Tsirkin
2009-11-10 12:40   ` Gregory Haskins
2009-11-10 13:17     ` Michael S. Tsirkin
2009-11-10 14:11       ` Gregory Haskins
2009-11-10 14:36         ` Michael S. Tsirkin
2009-11-10 15:45           ` Gregory Haskins
2009-11-10 17:36             ` Michael S. Tsirkin
2009-11-10 18:36               ` Gregory Haskins [this message]
2009-11-10 21:40                 ` Evgeniy Polyakov
2009-11-14  1:12             ` Herbert Xu
2009-11-14  1:33               ` Gregory Haskins
2009-11-14  2:21                 ` Herbert Xu
2009-11-14  2:27                   ` Gregory Haskins
2009-11-14  2:43                     ` Herbert Xu
2009-11-14  2:45                     ` Stephen Hemminger
2009-11-14  2:51                       ` Herbert Xu
2009-11-14  5:27                       ` Gregory Haskins
2009-11-16 19:59                         ` Stephen Hemminger
2009-11-16 20:18                           ` Gregory Haskins
2009-11-14  3:09                     ` David Miller
2009-11-14  3:04                 ` David Miller
2009-11-16 14:22                   ` Gregory Haskins
2009-11-17  1:02                     ` Herbert Xu
2009-11-17 12:33                       ` Gregory Haskins
2009-11-16 17:08                   ` Avi Kivity
2009-11-10 14:45         ` Michael S. Tsirkin
2009-11-10 15:47           ` Gregory Haskins

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4AF9B2A7.3050802@novell.com \
    --to=ghaskins@novell.com \
    --cc=alacrityvm-devel@lists.sourceforge.net \
    --cc=herbert.xu@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mst@redhat.com \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.