aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/ip
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2017-09-08 19:52:02 +0200
committerFlorin Coras <florin.coras@gmail.com>2017-09-09 20:11:03 +0000
commit56dd5438b04b869065d8e901c315496bb6777455 (patch)
tree517190c53cfd2725d716eda6dddf9a64ad814084 /src/vnet/ip
parent816122e303efb5012f6897bd53ff8fe28cd8fa1c (diff)
move unix_file_* code to vppinfra
This will allow us to use this code in client libraries without vlib. Change-Id: I8557b752496841ba588aa36b6082cbe2cd1867fe Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vnet/ip')
-rw-r--r--src/vnet/ip/punt.c8
-rw-r--r--src/vnet/ip/punt.h2
2 files changed, 5 insertions, 5 deletions
diff --git a/src/vnet/ip/punt.c b/src/vnet/ip/punt.c
index 67c54c3c5c1..1ea32fa0c78 100644
--- a/src/vnet/ip/punt.c
+++ b/src/vnet/ip/punt.c
@@ -550,7 +550,7 @@ VLIB_REGISTER_NODE (punt_socket_rx_node, static) =
format_punt_trace,};
static clib_error_t *
-punt_socket_read_ready (unix_file_t * uf)
+punt_socket_read_ready (clib_file_t * uf)
{
vlib_main_t *vm = vlib_get_main ();
punt_main_t *pm = &punt_main;
@@ -790,11 +790,11 @@ punt_config (vlib_main_t * vm, unformat_input_t * input)
}
/* Register socket */
- unix_main_t *um = &unix_main;
- unix_file_t template = { 0 };
+ clib_file_main_t *fm = &file_main;
+ clib_file_t template = { 0 };
template.read_function = punt_socket_read_ready;
template.file_descriptor = pm->socket_fd;
- pm->unix_file_index = unix_file_add (um, &template);
+ pm->clib_file_index = clib_file_add (fm, &template);
pm->is_configured = true;
diff --git a/src/vnet/ip/punt.h b/src/vnet/ip/punt.h
index 0103249cca0..9defa881782 100644
--- a/src/vnet/ip/punt.h
+++ b/src/vnet/ip/punt.h
@@ -72,7 +72,7 @@ typedef struct
char sun_path[sizeof (struct sockaddr_un)];
punt_client_t *clients_by_dst_port4;
punt_client_t *clients_by_dst_port6;
- u32 unix_file_index;
+ u32 clib_file_index;
bool is_configured;
vlib_node_t *interface_output_node;
u32 *ready_fds;