From: David Daney <ddaney@caviumnetworks.com>
To: netdev@vger.kernel.org
Subject: Weird locking in __release_sock()?
Date: Wed, 22 Jun 2011 16:31:13 -0700 [thread overview]
Message-ID: <4E027B41.3040009@caviumnetworks.com> (raw)
Hi,
In net/core/sock.c the function __release_sock() appears to drop the
socket lock, and then feed the backlogged skbs to sk_backlog_rcv().
In the case of an IPv4 TCP socket, sk_backlog_rcv() calls
tcp_v4_do_rcv(), which is documented like this:
/* The socket must have it's spinlock held when we get
* here.
.
.
.
*/
Q: How can this be correct?
Perhaps I am missing something. In any event, thanks in advance
shedding some light on the locking situation.
David Daney
next reply other threads:[~2011-06-22 23:31 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-22 23:31 David Daney [this message]
2011-06-22 23:42 ` Weird locking in __release_sock()? David Miller
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=4E027B41.3040009@caviumnetworks.com \
--to=ddaney@caviumnetworks.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;
as well as URLs for NNTP newsgroup(s).