* Question about IP_TOS and DSCP handling
@ 2009-11-20 22:55 Philip Prindeville
0 siblings, 0 replies; only message in thread
From: Philip Prindeville @ 2009-11-20 22:55 UTC (permalink / raw)
To: netdev
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
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2009-11-20 22:55 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-11-20 22:55 Question about IP_TOS and DSCP handling Philip Prindeville
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox