From: Philip Prindeville <philipp@redfish-solutions•com>
To: netdev@vger•kernel.org
Subject: Question about IP_TOS and DSCP handling
Date: Fri, 20 Nov 2009 15:55:49 -0700 [thread overview]
Message-ID: <4B071E75.1030103@redfish-solutions.com> (raw)
I'm looking at net/ipv4/ip_sockglue.c circa line 512 (this is in 2.6.27.38):
case IP_TOS: /* This sets both TOS and Precedence */
if (sk->sk_type == SOCK_STREAM) {
val &= ~3;
val |= inet->tos & 3;
}
if (inet->tos != val) {
inet->tos = val;
sk->sk_priority = rt_tos2priority(val);
sk_dst_reset(sk);
}
break;
and it doesn't look like the kernel handles DSCP marking. Is that
correct? (Also, not clear why SOCK_STREAM gets handled differently...)
Looking at rt_tos2priority(), which uses IPTOS_TOS(x), it doesn't look
like that would be the correct thing to do.
Also, include/linux/ip.h no longer meshes with
/usr/include/netinet/in.h. Please see:
http://sourceware.org/bugzilla/show_bug.cgi?id=10789
I'm trying to add DSCP marking to Thunderbird, Firefox, Apache, and a
few other applications but I wanted to make sure that my test platforms
would handle it correctly first.
Thanks,
-Philip
reply other threads:[~2009-11-20 22:55 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=4B071E75.1030103@redfish-solutions.com \
--to=philipp@redfish-solutions$(echo .)com \
--cc=netdev@vger$(echo .)kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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