session: add support for application namespacing
[vpp.git] / src / vnet / buffer.h
index 52dada3..7567b87 100644 (file)
   _( 2, L4_CHECKSUM_CORRECT)                           \
   _( 3, VLAN_2_DEEP)                                   \
   _( 4, VLAN_1_DEEP)                                   \
+  _( 8, SPAN_CLONE)                                    \
   _( 6, HANDOFF_NEXT_VALID)                            \
   _( 7, LOCALLY_ORIGINATED)                            \
-  _( 8, SPAN_CLONE)
+  _( 8, IS_IP4)                                                \
+  _( 9, IS_IP6)                                                \
+  _(10, OFFLOAD_IP_CKSUM)                              \
+  _(11, OFFLOAD_TCP_CKSUM)                             \
+  _(12, OFFLOAD_UDP_CKSUM)                              \
+  _(13, IS_NATED)
 
 #define VNET_BUFFER_FLAGS_VLAN_BITS \
   (VNET_BUFFER_F_VLAN_1_DEEP | VNET_BUFFER_F_VLAN_2_DEEP)
@@ -120,8 +126,14 @@ typedef struct
             protocol and ports. */
          u32 flow_hash;
 
-         /* next protocol */
-         u32 save_protocol;
+         union
+         {
+           /* next protocol */
+           u32 save_protocol;
+
+           /* Hint for transport protocols */
+           u32 fib_index;
+         };
 
          /* Rewrite length */
          u32 save_rewrite_length;
@@ -168,6 +180,7 @@ typedef struct
       u8 l2_len;               /* ethernet header length */
       u8 shg;                  /* split-horizon group */
       u16 l2fib_sn;            /* l2fib bd/int seq_num */
+      u8 bd_age;               /* aging enabled */
     } l2;
 
     /* l2tpv3 softwire encap, only valid there */
@@ -279,6 +292,12 @@ typedef struct
       u8 flags;
     } tcp;
 
+    /* SNAT */
+    struct
+    {
+      u32 flags;
+    } snat;
+
     u32 unused[6];
   };
 } vnet_buffer_opaque_t;