vxlan: multiarch optimization of vxlan 64/34564/3
authorRay Kinsella <mdr@ashroe.eu>
Wed, 17 Nov 2021 10:03:04 +0000 (10:03 +0000)
committerDamjan Marion <dmarion@me.com>
Tue, 23 Nov 2021 12:58:42 +0000 (12:58 +0000)
Fixing the mutliarch versions of vxlan, geneve and friends. Ensures that
main struct is correctly sized for all multiarch permutations.

Type: fix
Fixes: 290526e3c

Signed-off-by: Ray Kinsella <mdr@ashroe.eu>
Change-Id: I7c4c435763a5dcb0c3b429cd4f361d373d480c03

src/plugins/geneve/geneve.h
src/plugins/gtpu/gtpu.h
src/vnet/ip/vtep.h
src/vnet/vxlan-gpe/vxlan_gpe.h
src/vnet/vxlan/vxlan.h

index 0cc1421..deb51ab 100644 (file)
@@ -187,9 +187,7 @@ typedef struct
 
   u16 msg_id_base;
   /* cache for last 8 geneve tunnel */
-#ifdef CLIB_HAVE_VEC512
   vtep4_cache_t vtep4_u512;
-#endif
 
 } geneve_main_t;
 
index 59e3401..72d0923 100644 (file)
@@ -237,9 +237,7 @@ typedef struct
   vnet_main_t *vnet_main;
   u32 flow_id_start;
   /* cache for last 8 gtpu tunnel */
-#ifdef CLIB_HAVE_VEC512
   vtep4_cache_t vtep4_u512;
-#endif
 
 } gtpu_main_t;
 
index 92e8002..8b2c7fe 100644 (file)
@@ -111,13 +111,13 @@ vtep4_check (vtep_table_t * t, vlib_buffer_t * b0, ip4_header_t * ip40,
   return VTEP_CHECK_PASS;
 }
 
-#ifdef CLIB_HAVE_VEC512
 typedef struct
 {
   vtep4_key_t vtep4_cache[8];
   int idx;
 } vtep4_cache_t;
 
+#ifdef CLIB_HAVE_VEC512
 always_inline u8
 vtep4_check_vector (vtep_table_t * t, vlib_buffer_t * b0, ip4_header_t * ip40,
                    vtep4_key_t * last_k4, vtep4_cache_t * vtep4_u512)
index 5d21ee6..2cbbb6c 100644 (file)
@@ -237,9 +237,7 @@ typedef struct
   vnet_main_t *vnet_main;
 
   /* cache for last 8 vxlan_gpe tunnel */
-#ifdef CLIB_HAVE_VEC512
   vtep4_cache_t vtep4_u512;
-#endif
 
   /** List of next nodes for the decap indexed on protocol */
   uword decap_next_node_list[VXLAN_GPE_PROTOCOL_MAX];
index be819ab..d6dad7a 100644 (file)
@@ -191,9 +191,7 @@ typedef struct
   u32 flow_id_start;
 
   /* cache for last 8 vxlan tunnel */
-#ifdef CLIB_HAVE_VEC512
   vtep4_cache_t vtep4_u512;
-#endif
 
 } vxlan_main_t;