Code Review
/
vpp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
tunnel: support copying TTL and flow label from inner to outer
[vpp.git]
/
src
/
vnet
/
ip
/
ip4_packet.h
diff --git
a/src/vnet/ip/ip4_packet.h
b/src/vnet/ip/ip4_packet.h
index
0653092
..
513a744
100644
(file)
--- 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);
}
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)
{
always_inline void
ip4_header_set_df (ip4_header_t * ip4)
{