X-Git-Url: https://gerrit.fd.io/r/gitweb?p=vpp.git;a=blobdiff_plain;f=src%2Fvnet%2Fip%2Fip4_packet.h;h=513a7449b54b06c2475ed0d65ff0f2c7fd58ddf0;hp=06530926120fc145d9d1ed5af63e39b9d3a56605;hb=a91cb4590;hpb=7d527a2292bdabc84ff070f5b27f35c0e858cddd diff --git a/src/vnet/ip/ip4_packet.h b/src/vnet/ip/ip4_packet.h index 06530926120..513a7449b54 100644 --- a/src/vnet/ip/ip4_packet.h +++ b/src/vnet/ip/ip4_packet.h @@ -359,6 +359,18 @@ ip4_header_get_ecn (const ip4_header_t * ip4) return (ip4->tos & IP_PACKET_TC_FIELD_ECN_MASK); } +always_inline u8 +ip4_header_get_ttl (const ip4_header_t *ip4) +{ + return (ip4->ttl); +} + +always_inline void +ip4_header_set_ttl (ip4_header_t *ip4, u8 ttl) +{ + ip4->ttl = ttl; +} + always_inline void ip4_header_set_df (ip4_header_t * ip4) {