diff --git a/sys/netinet/ip_ecn.h b/sys/netinet/ip_ecn.h --- a/sys/netinet/ip_ecn.h +++ b/sys/netinet/ip_ecn.h @@ -44,7 +44,7 @@ #define ECN_NOCARE (-1) /* no consideration to ECN */ #ifdef _KERNEL -extern void ip_ecn_ingress(int, u_int8_t *, const u_int8_t *); -extern int ip_ecn_egress(int, const u_int8_t *, u_int8_t *); +extern void ip_ecn_ingress(int, uint8_t *, const uint8_t *); +extern int ip_ecn_egress(int, const uint8_t *, uint8_t *); #endif #endif diff --git a/sys/netinet/ip_ecn.c b/sys/netinet/ip_ecn.c --- a/sys/netinet/ip_ecn.c +++ b/sys/netinet/ip_ecn.c @@ -92,7 +92,7 @@ * modify outer ECN (TOS) field on ingress operation (tunnel encapsulation). */ void -ip_ecn_ingress(int mode, u_int8_t *outer, const u_int8_t *inner) +ip_ecn_ingress(int mode, uint8_t *outer, const uint8_t *inner) { if (!outer || !inner) @@ -124,7 +124,7 @@ * the caller should drop the packet if the return value is 0. */ int -ip_ecn_egress(int mode, const u_int8_t *outer, u_int8_t *inner) +ip_ecn_egress(int mode, const uint8_t *outer, uint8_t *inner) { if (!outer || !inner) @@ -158,9 +158,9 @@ #ifdef INET6 void -ip6_ecn_ingress(int mode, u_int32_t *outer, const u_int32_t *inner) +ip6_ecn_ingress(int mode, uint32_t *outer, const uint32_t *inner) { - u_int8_t outer8, inner8; + uint8_t outer8, inner8; if (!outer || !inner) panic("NULL pointer passed to ip6_ecn_ingress"); @@ -168,13 +168,13 @@ inner8 = (ntohl(*inner) >> 20) & 0xff; ip_ecn_ingress(mode, &outer8, &inner8); *outer &= ~htonl(0xff << 20); - *outer |= htonl((u_int32_t)outer8 << 20); + *outer |= htonl((uint32_t)outer8 << 20); } int -ip6_ecn_egress(int mode, const u_int32_t *outer, u_int32_t *inner) +ip6_ecn_egress(int mode, const uint32_t *outer, uint32_t *inner) { - u_int8_t outer8, inner8, oinner8; + uint8_t outer8, inner8, oinner8; if (!outer || !inner) panic("NULL pointer passed to ip6_ecn_egress"); @@ -185,7 +185,7 @@ return (0); if (inner8 != oinner8) { *inner &= ~htonl(0xff << 20); - *inner |= htonl((u_int32_t)inner8 << 20); + *inner |= htonl((uint32_t)inner8 << 20); } return (1); } diff --git a/sys/netinet6/ip6_ecn.h b/sys/netinet6/ip6_ecn.h --- a/sys/netinet6/ip6_ecn.h +++ b/sys/netinet6/ip6_ecn.h @@ -37,6 +37,6 @@ */ #ifdef _KERNEL -extern void ip6_ecn_ingress(int, u_int32_t *, const u_int32_t *); -extern int ip6_ecn_egress(int, const u_int32_t *, u_int32_t *); +extern void ip6_ecn_ingress(int, uint32_t *, const uint32_t *); +extern int ip6_ecn_egress(int, const uint32_t *, uint32_t *); #endif