Lines Matching defs:veth
3 * ipsec.c - Check xfrm on veth inside a net-ns.
18 #include <linux/veth.h>
54 /* /30 mask for one veth connection */
278 const char veth_type[] = "veth";
426 static int tunnel_set_route(int route_sock, uint32_t *route_seq, char *veth,
435 if (ip4_route_set(route_sock, (*route_seq)++, veth, tunsrc, tundst)) {
443 static int init_child(int nsfd, char *veth, unsigned int src, unsigned int dst)
459 if (ip4_addr_set(route_sock, route_seq++, veth, intsrc, PREFIX_LEN)) {
464 if (link_set_up(route_sock, route_seq++, veth)) {
465 printk("Failed to bring up %s", veth);
469 if (tunnel_set_route(route_sock, &route_seq, veth, tunsrc, tundst)) {
470 printk("Failed to add tunnel route on %s", veth);
1814 static int start_child(unsigned int nr, char *veth, int test_desc_fd[2])
1820 if (init_child(nsfd_childa, veth, child_ip(nr), grchild_ip(nr)))
1823 if (init_child(nsfd_childb, veth, grchild_ip(nr), child_ip(nr)))
2166 char veth[VETH_LEN];
2168 snprintf(veth, VETH_LEN, VETH_FMT, i);
2170 if (veth_add(route_sock, route_seq++, veth, nsfd_childa, veth, nsfd_childb)) {
2172 ksft_exit_fail_msg("Failed to create veth device");
2175 if (start_child(i, veth, test_desc_fd)) {