From: "David S. Miller" <davem@redhat.com>
To: Olaf Kirch <okir@suse.de>
Cc: netdev@oss.sgi.com
Subject: Re: [PATCH] 2.6 UDP recvmsg vs POSIX
Date: Mon, 23 Feb 2004 09:42:16 -0800 [thread overview]
Message-ID: <20040223094216.66602afd.davem@redhat.com> (raw)
In-Reply-To: <20040223094209.GA12663@suse.de>
On Mon, 23 Feb 2004 10:42:10 +0100
Olaf Kirch <okir@suse.de> wrote:
> But that breaks poll/recvmsg on a blocking socket, because poll with
> assert POLLIN, but the recvmsg call with block.
There is nothing wrong with that, I even pinged Linus about this and he
agreed with me.
What stops another thread from pulling a packet from the
receive queue and thus emptying it? Nothing. POLLIN does not guarentee
a read will give you data right now, it never has and it never will.
Therefore, the only bug was returning -EAGAIN unconditionally and that's
what is fixed by the correct half of your changes.
TCP does the same thing Olaf, and there is no way I'm adding the gross poll
hacks there :-)
next prev parent reply other threads:[~2004-02-23 17:42 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-02-17 12:17 [PATCH] 2.6 UDP recvmsg vs POSIX Olaf Kirch
2004-02-18 4:30 ` Andi Kleen
2004-02-18 6:17 ` David S. Miller
2004-02-19 7:07 ` Andi Kleen
2004-02-21 21:08 ` David S. Miller
2004-02-23 9:42 ` Olaf Kirch
2004-02-23 17:42 ` David S. Miller [this message]
2004-02-24 9:32 ` Olaf Kirch
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=20040223094216.66602afd.davem@redhat.com \
--to=davem@redhat.com \
--cc=netdev@oss.sgi.com \
--cc=okir@suse.de \
/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).