l2: input performance

Type: improvement

- cache the values form the BD on the input config to avoid loading
- avoid the short write long read on the sequence number
- use vlib_buffer_enqueue_to_next

Signed-off-by: Neale Ranns <nranns@cisco.com>
Change-Id: I33442b9104b457e4c638d26e9ad3bc965687a0bc
diff --git a/src/vnet/dpo/dvr_dpo.c b/src/vnet/dpo/dvr_dpo.c
index 6dd5810..533ce4b 100644
--- a/src/vnet/dpo/dvr_dpo.c
+++ b/src/vnet/dpo/dvr_dpo.c
@@ -110,7 +110,8 @@
 
         config = l2input_intf_config (sw_if_index);
 
-        if (config->bridge || config->xconnect)
+        if (l2_input_is_bridge(config) ||
+            l2_input_is_xconnect(config))
         {
             dd->dd_reinject = DVR_REINJECT_L2;
         }