Bug 1186 - Ipv4Header lacks DSCP and ECN
Ipv4Header lacks DSCP and ECN
Status: RESOLVED FIXED
Product: ns-3
Classification: Unclassified
Component: internet
pre-release
All All
: P5 normal
Assigned To: John Abraham
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-06-13 01:13 EDT by Tom Henderson
Modified: 2011-10-21 10:02 EDT (History)
3 users (show)

See Also:


Attachments
Patch for DSCP,ECN with test (14.91 KB, patch)
2011-10-20 18:20 EDT, John Abraham
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Henderson 2011-06-13 01:13:14 EDT

    
Comment 1 Tom Henderson 2011-06-13 01:14:47 EDT
Users can set the legacy TOS byte but it would be nice to provide setters/getters to the current usage of this byte since TOS has been deprecated for a long time.
Comment 2 Vedran Miletić 2011-06-27 05:03:49 EDT
+1
Comment 3 John Abraham 2011-10-20 18:20:13 EDT
Created attachment 1262 [details]
Patch for DSCP,ECN with test

Patch for DSCP,ECN with test

test output

DSCP Test
tos 0x1 DSCP-Type Default ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x21 DSCP-Type Class Selector 1 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x29 DSCP-Type Assured Forwarding 11 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x31 DSCP-Type Assured Forwarding 12 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x39 DSCP-Type Assured Forwarding 13 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x41 DSCP-Type Class Selector 2 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x49 DSCP-Type Assured Forwarding 21 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x51 DSCP-Type Assured Forwarding 22 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x59 DSCP-Type Assured Forwarding 23 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x61 DSCP-Type Class Selector 3 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x69 DSCP-Type Assured Forwarding 31 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x71 DSCP-Type Assured Forwarding 32 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x79 DSCP-Type Assured Forwarding 33 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x81 DSCP-Type Class Selector 4 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x89 DSCP-Type Assured Forwarding 41 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x91 DSCP-Type Assured Forwarding 42 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x99 DSCP-Type Assured Forwarding 43 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0xa1 DSCP-Type Class Selector 5 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0xb9 DSCP-Type Expedited Forwarding ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0xc1 DSCP-Type Class Selector 6 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0xe1 DSCP-Type Class Selector 7 ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
ECN Test
tos 0x0 DSCP-Type Default ECN-Type Not-ECT ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x1 DSCP-Type Default ECN-Type ECT (1) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x2 DSCP-Type Default ECN-Type ECT (0) ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
tos 0x3 DSCP-Type Default ECN-Type CE ttl 255 id 0 protocol 0 offset (bytes) 0 flags [none] length: 143 10.0.0.2 > 10.0.0.1
PASS ipv4-header 0.000ms
Comment 4 Tom Henderson 2011-10-21 00:24:01 EDT
Looks good, just fix naming s/DSCP/Dscp, s/ECN/Ecn; see
http://www.nsnam.org/developers/contributing-code/coding-style/#naming
Comment 5 John Abraham 2011-10-21 10:02:16 EDT
changeset 7566	aa5b5f290a0d