Code Review
/
vpp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
ipsec: Support async mode per-SA
[vpp.git]
/
src
/
vnet
/
devices
/
pipe
/
pipe.c
diff --git
a/src/vnet/devices/pipe/pipe.c
b/src/vnet/devices/pipe/pipe.c
index
c6d3f65
..
ec50f63
100644
(file)
--- a/
src/vnet/devices/pipe/pipe.c
+++ b/
src/vnet/devices/pipe/pipe.c
@@
-21,7
+21,7
@@
* @file
* @brief Pipe Interfaces.
*
* @file
* @brief Pipe Interfaces.
*
- * A pipe interface, like the UNIX pipe, is a pair of interfaces
+ * A pipe interface, like the UNIX pipe, is a pair of
vpp
interfaces
* that are joined.
*/
const static pipe_t PIPE_INVALID = {
* that are joined.
*/
const static pipe_t PIPE_INVALID = {
@@
-30,7
+30,7
@@
const static pipe_t PIPE_INVALID = {
};
/**
};
/**
- * Various 'module' l
a
vel variables
+ * Various 'module' l
e
vel variables
*/
typedef struct pipe_main_t_
{
*/
typedef struct pipe_main_t_
{
@@
-40,7
+40,7
@@
typedef struct pipe_main_t_
uword *instances;
/**
uword *instances;
/**
- * the per-swif-index array of pipes. Each end of the pipe is stored againt
+ * the per-swif-index array of pipes. Each end of the pipe is stored again
s
t
* its respective sw_if_index
*/
pipe_t *pipes;
* its respective sw_if_index
*/
pipe_t *pipes;
@@
-51,7
+51,7
@@
static pipe_main_t pipe_main;
/*
* The pipe rewrite is the same size as an ethernet header (since it
* is an ethernet interface and the DP is optimised for writing
/*
* The pipe rewrite is the same size as an ethernet header (since it
* is an ethernet interface and the DP is optimised for writing
- * sizeof(ethernet_header_t) rew
irtes. Hwo
ever, there are no MAC addresses
+ * sizeof(ethernet_header_t) rew
rites. How
ever, there are no MAC addresses
* since pipes don't have them.
*/
static u8 *
* since pipes don't have them.
*/
static u8 *
@@
-131,11
+131,7
@@
pipe_tx (vlib_main_t * vm, vlib_node_runtime_t * node, vlib_frame_t * frame)
{
u32 n_left_from, n_left_to_next, n_copy, *from, *to_next;
u32 next_index = VNET_PIPE_TX_NEXT_ETHERNET_INPUT;
{
u32 n_left_from, n_left_to_next, n_copy, *from, *to_next;
u32 next_index = VNET_PIPE_TX_NEXT_ETHERNET_INPUT;
- u32 i, sw_if_index = 0;
- u32 n_pkts = 0, n_bytes = 0;
- u32 thread_index = vm->thread_index;
- vnet_main_t *vnm = vnet_get_main ();
- vnet_interface_main_t *im = &vnm->interface_main;
+ u32 i, sw_if_index = 0, n_pkts = 0, n_bytes = 0;
vlib_buffer_t *b;
pipe_t *pipe;
vlib_buffer_t *b;
pipe_t *pipe;
@@
-169,15
+165,9
@@
pipe_tx (vlib_main_t * vm, vlib_node_runtime_t * node, vlib_frame_t * frame)
from += n_copy;
vlib_put_next_frame (vm, node, next_index, n_left_to_next);
from += n_copy;
vlib_put_next_frame (vm, node, next_index, n_left_to_next);
-
- /* increment TX interface stat */
- vlib_increment_combined_counter (im->combined_sw_if_counters +
- VNET_INTERFACE_COUNTER_TX,
- thread_index, sw_if_index, n_pkts,
- n_bytes);
}
}
- return
n_left_from
;
+ return
frame->n_vectors
;
}
static u8 *
}
static u8 *