From: Rick Jones <rick.jones2@hp.com>
To: Linux Network Development list <netdev@vger.kernel.org>
Subject: why does DCCP SO_REUSEADDR have to be SOL_DCCP?
Date: Fri, 01 Feb 2008 17:42:23 -0800 [thread overview]
Message-ID: <47A3CA7F.8040300@hp.com> (raw)
Hi -
I'm tweaking the netperf omni tests to be able to run over DCCP. I've
run across a not-unorecedented problem with getaddrinfo() not groking
either SOCK_DCCP or IPPROTO_DCCP in the hints, and that I can more or
less live with - I had to do a kludge for getaddrinfo() for IPPROTO_SCTP
under Linux at one point and I can see how the two are not necessarily
going to be in sync.
And I've worked-around no user-level include files (ie without setting
__KERNEL__) define the DCCP stuff, and that is OK too, albeit somewhat
inconvenient.
My question though is why on earth does an SO_REUSEADDR setsockopt()
against a DCCP socket have to be SOL_DCCP? SCTP and TCP are quite happy
with SOL_SOCKET, and it might be foolish consistency, but since the
option _does_ begin with SO_ I'd have expected it to work for
SOL_SOCKET, but (again RHEL5.1, yes, I do plan on getting upstream but
have to satisfy several masters) it doesn't seem to be the case - a
subsequent listen() or connect() call after an SOL_SOCKET SO_REUSEADDR
against a DCCP socket leaves one SOL as it were...
Of course the setsockopt(SO_REUSEADDR) against the DCCP socket using
SOL_SOCKET itself doesn't fail, only the later listen() or connect() call...
happy benchmarking,
rick jones
next reply other threads:[~2008-02-02 1:42 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-02 1:42 Rick Jones [this message]
2008-02-02 2:52 ` why does DCCP SO_REUSEADDR have to be SOL_DCCP? Arnaldo Carvalho de Melo
2008-02-02 3:02 ` Arnaldo Carvalho de Melo
2008-02-04 18:46 ` Rick Jones
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=47A3CA7F.8040300@hp.com \
--to=rick.jones2@hp.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).