Home
last modified time | relevance | path

Searched refs:CLONE_NEWNET (Results 1 – 25 of 32) sorted by relevance

12

/linux-6.12.1/tools/testing/selftests/uevent/
Duevent_filtering.c138 if (post_flags & CLONE_NEWNET) { in uevent_listener()
139 ret = unshare(CLONE_NEWNET); in uevent_listener()
285 if (pre_flags & CLONE_NEWNET) { in do_test()
286 ret = unshare(CLONE_NEWNET); in do_test()
403 ret = do_test(CLONE_NEWNET, 0, true, sync_fd); in TEST()
432 ret = do_test(CLONE_NEWUSER | CLONE_NEWNET, 0, false, sync_fd); in TEST()
447 ret = do_test(0, CLONE_NEWNET, true, sync_fd); in TEST()
478 ret = do_test(0, CLONE_NEWUSER | CLONE_NEWNET, true, sync_fd); in TEST()
/linux-6.12.1/tools/testing/selftests/net/af_unix/
Dunix_connect.c53 .flags = CLONE_NEWNET, in FIXTURE_VARIANT_ADD()
62 .flags = CLONE_NEWNET, in FIXTURE_VARIANT_ADD()
89 .flags = CLONE_NEWNET, in FIXTURE_VARIANT_ADD()
98 .flags = CLONE_NEWNET, in FIXTURE_VARIANT_ADD()
Dscm_rights.c105 ret = unshare(CLONE_NEWNET); in FIXTURE_SETUP()
/linux-6.12.1/tools/testing/selftests/proc/
Dsetns-dcache.c54 if (unshare(CLONE_NEWNET) == -1) { in main()
75 if (unshare(CLONE_NEWNET) == -1) { in main()
104 if (setns(nsfd, CLONE_NEWNET) == -1) { in main()
/linux-6.12.1/tools/testing/selftests/bpf/prog_tests/
Dflow_dissector_reattach.c76 err = unshare(CLONE_NEWNET); in unshare_net()
84 setns(old_net, CLONE_NEWNET); in unshare_net()
455 err = setns(old_net, CLONE_NEWNET); in test_link_update_netns_gone()
539 err = setns(old_net, CLONE_NEWNET); in test_link_get_info()
567 setns(old_net, CLONE_NEWNET); in test_link_get_info()
647 err = setns(init_net, CLONE_NEWNET); in serial_test_flow_dissector_reattach()
671 err = setns(saved_net, CLONE_NEWNET); in serial_test_flow_dissector_reattach()
Dsk_assign.c50 if (CHECK_FAIL(unshare(CLONE_NEWNET))) in configure_stack()
294 if (CHECK_FAIL(setns(self_net, CLONE_NEWNET))) in test_sk_assign()
Dbind_perm.c14 if (!ASSERT_OK(unshare(CLONE_NEWNET), "create netns")) in create_netns()
Dtcp_custom_syncookie.c35 if (!ASSERT_OK(unshare(CLONE_NEWNET), "create netns")) in setup_netns()
Dconnect_ping.c101 if (!ASSERT_OK(unshare(CLONE_NEWNET | CLONE_NEWNS), "unshare")) in test_connect_ping()
Dxdp_bonding.c37 ASSERT_OK(setns(root_netns_fd, CLONE_NEWNET), "restore_root_netns"); in restore_root_netns()
50 err = setns(nsfd, CLONE_NEWNET); in setns_by_name()
Dbtf_skc_cls_ingress.c30 if (CHECK(unshare(CLONE_NEWNET), "create netns", in prepare_netns()
Dbpf_iter_setsockopt.c13 if (!ASSERT_OK(unshare(CLONE_NEWNET), "create netns")) in create_netns()
Dsetget_sockopt.c25 if (!ASSERT_OK(unshare(CLONE_NEWNET), "create netns")) in create_netns()
Dsock_fields.c50 if (!ASSERT_OK(unshare(CLONE_NEWNET), "create netns")) in create_netns()
Dtcp_hdr_options.c45 if (!ASSERT_OK(unshare(CLONE_NEWNET), "create netns")) in create_netns()
/linux-6.12.1/kernel/
Dnsproxy.c158 CLONE_NEWPID | CLONE_NEWNET | in copy_namespaces()
220 CLONE_NEWNET | CLONE_NEWPID | CLONE_NEWCGROUP | in unshare_nsproxy_namespaces()
279 CLONE_NEWNET | CLONE_NEWTIME | CLONE_NEWUSER | in check_setns_flags()
304 if (flags & CLONE_NEWNET) in check_setns_flags()
478 if (flags & CLONE_NEWNET) { in validate_nsset()
/linux-6.12.1/tools/testing/selftests/net/tcp_ao/lib/
Dsetup.c125 if (unshare(CLONE_NEWNET) != 0) in unshare_open_netns()
133 if (setns(fd, CLONE_NEWNET)) in switch_ns()
147 if (setns(fd, CLONE_NEWNET)) in switch_close_ns()
/linux-6.12.1/tools/testing/selftests/net/
Dso_netns_cookie.c41 if (unshare(CLONE_NEWNET)) in main()
Dso_incoming_cpu.c71 ASSERT_EQ(unshare(CLONE_NEWNET), 0); in setup_netns()
/linux-6.12.1/tools/testing/selftests/pidfd/
Dpidfd_setns_test.c93 …[PIDFD_NS_NET] = { "net", CLONE_NEWNET, PIDFD_GET_NET_NAMESPACE, …
227 if (self->nsfds[PIDFD_NS_NET] >= 0 && unshare(CLONE_NEWNET) < 0) in FIXTURE_SETUP()
272 if (self->nsfds[PIDFD_NS_NET] >= 0 && unshare(CLONE_NEWNET) < 0) { in FIXTURE_SETUP()
326 if (self->nsfds[PIDFD_NS_NET] >= 0 && unshare(CLONE_NEWNET) < 0) { in FIXTURE_SETUP()
502 ASSERT_NE(setns(self->child_pidfd_exited, CLONE_NEWUSER | CLONE_NEWNET), in TEST_F()
/linux-6.12.1/tools/perf/trace/beauty/include/uapi/linux/
Dsched.h33 #define CLONE_NEWNET 0x40000000 /* New network namespace */ macro
/linux-6.12.1/include/uapi/linux/
Dsched.h33 #define CLONE_NEWNET 0x40000000 /* New network namespace */ macro
/linux-6.12.1/tools/testing/selftests/mount/
Dunprivileged-remount-test.c28 #ifndef CLONE_NEWNET
29 # define CLONE_NEWNET 0x40000000 macro
/linux-6.12.1/include/net/
Dnet_namespace.h214 if (flags & CLONE_NEWNET) in copy_net_ns()
/linux-6.12.1/tools/testing/selftests/bpf/
Dnetwork_helpers.c525 err = setns(nsfd, CLONE_NEWNET); in open_netns()
545 if (setns(token->orig_netns_fd, CLONE_NEWNET)) in close_netns()

12