aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet
diff options
context:
space:
mode:
Diffstat (limited to 'src/vnet')
-rw-r--r--src/vnet/ethernet/interface.c3
-rw-r--r--src/vnet/interface.c4
-rw-r--r--src/vnet/interface.h28
-rw-r--r--src/vnet/interface_funcs.h2
-rw-r--r--src/vnet/interface_output.c5
-rw-r--r--src/vnet/ip/ip_checksum.c23
6 files changed, 9 insertions, 56 deletions
diff --git a/src/vnet/ethernet/interface.c b/src/vnet/ethernet/interface.c
index 408b0eb0dc4..1c13c405a61 100644
--- a/src/vnet/ethernet/interface.c
+++ b/src/vnet/ethernet/interface.c
@@ -659,9 +659,6 @@ VNET_DEVICE_CLASS (ethernet_simulated_device_class) = {
};
/* *INDENT-ON* */
-VLIB_DEVICE_TX_FUNCTION_MULTIARCH (ethernet_simulated_device_class,
- simulated_ethernet_interface_tx);
-
/*
* Maintain a bitmap of allocated loopback instance numbers.
*/
diff --git a/src/vnet/interface.c b/src/vnet/interface.c
index 37f27ea49ea..12204bd5718 100644
--- a/src/vnet/interface.c
+++ b/src/vnet/interface.c
@@ -837,7 +837,7 @@ vnet_register_interface (vnet_main_t * vnm,
/* The new class may differ from the old one.
* Functions have to be updated. */
node = vlib_get_node (vm, hw->output_node_index);
- node->function = vnet_interface_output_node_multiarch_select ();
+ node->function = vnet_interface_output_node;
node->format_trace = format_vnet_interface_output_trace;
/* *INDENT-OFF* */
foreach_vlib_main ({
@@ -887,7 +887,7 @@ vnet_register_interface (vnet_main_t * vnm,
r.flags = 0;
r.name = output_node_name;
- r.function = vnet_interface_output_node_multiarch_select ();
+ r.function = vnet_interface_output_node;
r.format_trace = format_vnet_interface_output_trace;
{
diff --git a/src/vnet/interface.h b/src/vnet/interface.h
index 2e32a790996..174e5347ad2 100644
--- a/src/vnet/interface.h
+++ b/src/vnet/interface.h
@@ -302,30 +302,8 @@ CLIB_MARCH_SFX (devclass##_tx_fn_multiarch_register) (void) \
} \
uword CLIB_CPU_OPTIMIZED CLIB_MARCH_SFX (devclass##_tx_fn)
-#define VLIB_DEVICE_TX_FUNCTION_CLONE_TEMPLATE(arch, fn, tgt) \
- uword \
- __attribute__ ((flatten)) \
- __attribute__ ((target (tgt))) \
- CLIB_CPU_OPTIMIZED \
- fn ## _ ## arch ( vlib_main_t * vm, \
- vlib_node_runtime_t * node, \
- vlib_frame_t * frame) \
- { return fn (vm, node, frame); }
-
-#define VLIB_DEVICE_TX_FUNCTION_MULTIARCH_CLONE(fn) \
- foreach_march_variant(VLIB_DEVICE_TX_FUNCTION_CLONE_TEMPLATE, fn)
-
-#if CLIB_DEBUG > 0
-#define VLIB_MULTIARCH_CLONE_AND_SELECT_FN(fn,...)
+/* FIXME to be removed */
#define VLIB_DEVICE_TX_FUNCTION_MULTIARCH(dev, fn)
-#else
-#define VLIB_DEVICE_TX_FUNCTION_MULTIARCH(dev, fn) \
- VLIB_DEVICE_TX_FUNCTION_MULTIARCH_CLONE(fn) \
- CLIB_MULTIARCH_SELECT_FN(fn, static inline) \
- static void __attribute__((__constructor__)) \
- __vlib_device_tx_function_multiarch_select_##dev (void) \
- { dev.tx_function = fn ## _multiarch_select(); }
-#endif
/**
* Link Type: A description of the protocol of packets on the link.
@@ -872,6 +850,10 @@ void vnet_pcap_drop_trace_filter_add_del (u32 error_index, int is_add);
int vnet_interface_name_renumber (u32 sw_if_index, u32 new_show_dev_instance);
+uword vnet_interface_output_node (vlib_main_t * vm,
+ vlib_node_runtime_t * node,
+ vlib_frame_t * frame);
+
#endif /* included_vnet_interface_h */
/*
diff --git a/src/vnet/interface_funcs.h b/src/vnet/interface_funcs.h
index c4c66179bb5..9a674b180b9 100644
--- a/src/vnet/interface_funcs.h
+++ b/src/vnet/interface_funcs.h
@@ -418,8 +418,6 @@ typedef struct
} vnet_interface_output_runtime_t;
/* Interface output function. */
-void *vnet_interface_output_node_multiarch_select (void);
-
word vnet_sw_interface_compare (vnet_main_t * vnm, uword sw_if_index0,
uword sw_if_index1);
word vnet_hw_interface_compare (vnet_main_t * vnm, uword hw_if_index0,
diff --git a/src/vnet/interface_output.c b/src/vnet/interface_output.c
index e814efa608a..beeb62a2db4 100644
--- a/src/vnet/interface_output.c
+++ b/src/vnet/interface_output.c
@@ -446,7 +446,7 @@ vnet_interface_output_node_inline (vlib_main_t * vm,
return n_buffers;
}
-static uword
+uword
vnet_interface_output_node (vlib_main_t * vm, vlib_node_runtime_t * node,
vlib_frame_t * frame)
{
@@ -463,9 +463,6 @@ vnet_interface_output_node (vlib_main_t * vm, vlib_node_runtime_t * node,
/* do_tx_offloads */ 1);
}
-VLIB_NODE_FUNCTION_MULTIARCH_CLONE (vnet_interface_output_node);
-CLIB_MULTIARCH_SELECT_FN (vnet_interface_output_node);
-
/* Use buffer's sw_if_index[VNET_TX] to choose output interface. */
static uword
vnet_per_buffer_interface_output (vlib_main_t * vm,
diff --git a/src/vnet/ip/ip_checksum.c b/src/vnet/ip/ip_checksum.c
index 36467a2eb01..d586649646d 100644
--- a/src/vnet/ip/ip_checksum.c
+++ b/src/vnet/ip/ip_checksum.c
@@ -120,34 +120,13 @@ do { \
* function which uses the function pointer we set up in
* ip_checksum_init().
*/
-#if CLIB_DEBUG > 0
-#define IP_INCREMENTAL_CHECKSUM_CLONE_TEMPLATE(arch, fn)
-#define IP_INCREMENTAL_CHECKSUM_MULTIARCH_CLONE(fn)
-#else
-#define IP_INCREMENTAL_CHECKSUM_CLONE_TEMPLATE(arch, fn, tgt) \
- uword \
- __attribute__ ((flatten)) \
- __attribute__ ((target (tgt))) \
- CLIB_CPU_OPTIMIZED \
- fn ## _ ## arch (ip_csum_t sum, \
- void *_data, \
- uword n_bytes) \
- { return fn (sum, _data, n_bytes); }
-
-#define IP_INCREMENTAL_CHECKSUM_MULTIARCH_CLONE(fn) \
- foreach_march_variant(IP_INCREMENTAL_CHECKSUM_CLONE_TEMPLATE,fn)
-#endif
-
-IP_INCREMENTAL_CHECKSUM_MULTIARCH_CLONE (_ip_incremental_checksum);
-
-CLIB_MULTIARCH_SELECT_FN (_ip_incremental_checksum, static inline);
ip_csum_t (*vnet_incremental_checksum_fp) (ip_csum_t, void *, uword);
static clib_error_t *
ip_checksum_init (vlib_main_t * vm)
{
- vnet_incremental_checksum_fp = _ip_incremental_checksum_multiarch_select ();
+ vnet_incremental_checksum_fp = _ip_incremental_checksum;
return 0;
}