go.net/ipv4: drop DIffServ and ECN constants, add ICMPType
This CL removes DiffServ and ECN constants assigned by IANA because
for now we don't have an appropriate package to put those constants
as part of API. There were used for the type-of-service field of IPv4
header and the traffic class field of IPv6 header.
Also adds ICMPType for convenience, makes use of internal IANA
protocol number constants instead of syscall's to prevent churning of
package syscall in the near future.
R=dave
CC=golang-dev
https://golang.org/cl/9353045
diff --git a/ipv4/doc.go b/ipv4/doc.go
index 05be70d..ffdb9ff 100644
--- a/ipv4/doc.go
+++ b/ipv4/doc.go
@@ -8,9 +8,7 @@
// The package provides IP-level socket options that allow
// manipulation of IPv4 facilities. The IPv4 and basic host
// requirements for IPv4 are defined in RFC 791, RFC 1112 and RFC
-// 1122. A series of RFC 2474, RFC 2475, RFC 2597, RFC 2598 and RFC
-// 3168 describe how to use the type-of-service field in a DiffServ,
-// differentiated services environment.
+// 1122.
//
//
// Unicasting
@@ -38,7 +36,7 @@
// The outgoing packets will be labeled DiffServ assured forwarding
// class 1 low drop precedence, as known as AF11 packets.
//
-// err := ipv4.NewConn(c).SetTOS(ipv4.DSCP_AF11)
+// err := ipv4.NewConn(c).SetTOS(DiffServAF11)
// if err != nil {
// // error handling
// }
@@ -125,7 +123,7 @@
//
// The application can also send both unicast and multicast packets.
//
-// p.SetTOS(ipv4.DSCP_CS0)
+// p.SetTOS(DiffServCS0)
// p.SetTTL(16)
// _, err = p.WriteTo(data, nil, src)
// if err != nil {