From: Ben Greear <greearb@candelatech.com>
To: LKML <linux-kernel@vger.kernel.org>
Subject: Requesting clarification on IPTOS_* values w/regard to RFC-1349
Date: Mon, 13 Aug 2001 16:30:05 -0700 [thread overview]
Message-ID: <3B7862FD.BBDF0C51@candelatech.com> (raw)
I have a hard time believing that the kernel is wrong
on something so basic, but I cannot reconcile RFC-1349
with include/linux/ip.h
Here is the snippet from RFC-1349, found here:
http://www.cis.ohio-state.edu/cgi-bin/rfc/rfc1349.html
****************************************************************************
3 Specification of the Type of Service Octet
The TOS facility is one of the features of the Type of Service
octet in the IP datagram header. The Type of Service
octet consists of three fields:
0 1 2 3 4 5 6 7
+-----+-----+-----+-----+-----+-----+-----+-----+
| | | |
| PRECEDENCE | TOS | MBZ |
| | | |
+-----+-----+-----+-----+-----+-----+-----+-----+
The first field, labeled "PRECEDENCE" above, is intended to denote the
importance or priority of the datagram. This
field is not discussed in detail in this memo.
****************************************************************************
However, include/linux/ip.h defines the values as if RFC-1349 numbered
the bits backwards. (It appears to me, for example, that the TOS_MASK
should be, in binary: 0111 1000, not 0001 1110 as ip.h shows.)
*************************************************
/* SOL_IP socket options */
#define IPTOS_TOS_MASK 0x1E
#define IPTOS_TOS(tos) ((tos)&IPTOS_TOS_MASK)
#define IPTOS_LOWDELAY 0x10
#define IPTOS_THROUGHPUT 0x08
#define IPTOS_RELIABILITY 0x04
#define IPTOS_MINCOST 0x02
*************************************************
Am I even more confused than normal, or is this really a problem?
Thanks,
Ben
--
Ben Greear <greearb@candelatech.com> <Ben_Greear@excite.com>
President of Candela Technologies Inc http://www.candelatech.com
ScryMUD: http://scry.wanfear.com http://scry.wanfear.com/~greear
next reply other threads:[~2001-08-13 23:28 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-08-13 23:30 Ben Greear [this message]
2001-08-13 23:50 ` Roland Dreier
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=3B7862FD.BBDF0C51@candelatech.com \
--to=greearb@candelatech.com \
--cc=linux-kernel@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
all inboxes | Powered by JetHome®