From: David Miller <davem@davemloft.net>
To: gregory.haskins@gmail.com
Cc: herbert@gondor.apana.org.au, ghaskins@novell.com, mst@redhat.com,
alacrityvm-devel@lists.sourceforge.net,
linux-kernel@vger.kernel.org, netdev@vger.kernel.org
Subject: Re: [RFC PATCH] net: add dataref destructor to sk_buff
Date: Fri, 13 Nov 2009 19:09:54 -0800 (PST) [thread overview]
Message-ID: <20091113.190954.189642997.davem@davemloft.net> (raw)
In-Reply-To: <4AFE15AD.6000208@gmail.com>
From: Gregory Haskins <gregory.haskins@gmail.com>
Date: Fri, 13 Nov 2009 21:27:57 -0500
> Clearly there must be _some_ mechanism to synchronize (e.g.
> flush/barrier) though, right? Otherwise, that interface would seem to
> be quite prone to races and would likely be unusable. So what does
> said flush use to know when the buffer is free?
There is no such synchronization at all.
If some synchronization is required, it must be done at a higher
level.
For example, SAMBA can only use sendfile() to serve file contents when
the client holds an SMB "OP Lock" on the file. Luckily, by default
pretty much all SMB client implementations hold the OP Lock on a file
even just to read it (this is so that self-modifying autoexec.bat
scripts work :-)
But frankly most sendfile() consumers don't care, and the only thing
that really matters is that the checksum on the final TCP packet that
goes out is correct, and since we require card checksums to sendfile()
without copying, that is taken care of transparently.
next prev parent reply other threads:[~2009-11-14 3:09 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-02 14:20 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
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 [this message]
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=20091113.190954.189642997.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=alacrityvm-devel@lists.sourceforge.net \
--cc=ghaskins@novell.com \
--cc=gregory.haskins@gmail.com \
--cc=herbert@gondor.apana.org.au \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®