Home
last modified time | relevance | path

Searched refs:prctl (Results 26 - 50 of 361) sorted by relevance

12345678910>>...15

/third_party/musl/src/hook/linux/
H A Dmusl_preinit_common.c41 .prctl = MuslMalloc(prctl),
53 .prctl = MuslMalloc(prctl),
/third_party/ltp/testcases/kernel/security/cap_bound/
H A Dcap_bounds_r.c33 #include <sys/prctl.h>
57 ret = prctl(PR_CAPBSET_READ, i); in main()
64 "prctl(PR_CAPBSET_READ, %d) returned %d\n", i, in main()
72 ret = prctl(PR_CAPBSET_READ, -1); in main()
79 "prctl(PR_CAPBSET_READ, -1) returned %d\n", in main()
89 ret = prctl(PR_CAPBSET_READ, MAX(INSANE, CAP_LAST_CAP + 1)); in main()
95 tst_resm(TFAIL, "prctl(PR_CAPBSET_READ, %d) returned %d\n", in main()
H A Dcap_bset_inh_bounds.c35 #include <sys/prctl.h>
53 ret = prctl(PR_CAPBSET_READ, CAP_SYS_ADMIN); in main()
82 ret = prctl(PR_CAPBSET_DROP, CAP_SYS_ADMIN); in main()
/third_party/musl/libc-test/src/functionalext/supplement/linux/
H A Dprctl.c16 #include <sys/prctl.h>
29 int result = prctl(PR_SET_NAME, (unsigned long)"TestThread"); in prctl_0100()
32 result = prctl(PR_GET_NAME, (unsigned long)buf); in prctl_0100()
/third_party/ltp/testcases/kernel/syscalls/prctl/
H A Dprctl01.c17 #include <sys/prctl.h>
25 TEST(prctl(PR_SET_PDEATHSIG, SIGUSR2)); in verify_prctl()
27 tst_res(TFAIL | TTERRNO, "prctl(PR_SET_PDEATHSIG) failed"); in verify_prctl()
31 tst_res(TPASS, "prctl(PR_SET_PDEATHSIG) succeeded"); in verify_prctl()
33 TEST(prctl(PR_GET_PDEATHSIG, &get_sig)); in verify_prctl()
35 tst_res(TFAIL | TTERRNO, "prctl(PR_GET_PDEATHSIG) failed"); in verify_prctl()
41 "prctl(PR_GET_PDEATHSIG) got expected death signal"); in verify_prctl()
43 tst_res(TFAIL, "prctl(PR_GET_PDEATHSIG) got death signal %d, expected %d", in verify_prctl()
H A Dprctl06.h12 #include <sys/prctl.h>
16 #include <lapi/prctl.h>
28 TEST(prctl(PR_GET_NO_NEW_PRIVS, 0, 0, 0, 0)); in check_no_new_privs()
31 "%s prctl(PR_GET_NO_NEW_PRIVS) expected %d got %d", in check_no_new_privs()
35 "%s prctl(PR_GET_NO_NEW_PRIVS) expected %d got %ld", in check_no_new_privs()
H A Dprctl05.c10 * Test PR_GET_NAME and PR_SET_NAME of prctl(2).
23 #include <sys/prctl.h>
28 #include "lapi/prctl.h"
45 TEST(prctl(PR_SET_NAME, tc->setname)); in verify_prctl()
47 tst_res(TFAIL | TTERRNO, "prctl(PR_SET_NAME) failed"); in verify_prctl()
50 tst_res(TPASS, "prctl(PR_SET_NAME, '%s') succeeded", tc->setname); in verify_prctl()
52 TEST(prctl(PR_GET_NAME, buf)); in verify_prctl()
54 tst_res(TFAIL | TTERRNO, "prctl(PR_GET_NAME) failed"); in verify_prctl()
60 "prctl(PR_GET_NAME) failed, expected %s, got %s", in verify_prctl()
64 tst_res(TPASS, "prctl(PR_GET_NAM in verify_prctl()
[all...]
H A Dprctl10.c19 #include <sys/prctl.h>
24 #include "lapi/prctl.h"
74 TST_EXP_PASS_SILENT(prctl(PR_SET_TSC, tc->read_stat)); in verify_prctl()
75 TST_EXP_PASS_SILENT(prctl(PR_GET_TSC, &tsc_val)); in verify_prctl()
H A Dprctl03.c10 * Test PR_SET_CHILD_SUBREAPER and PR_GET_CHILD_SUBREAPER of prctl(2).
25 * "prctl: add PR_{SET,GET}_CHILD_SUBREAPER to allow simple process supervision"
34 #include <sys/prctl.h>
37 #include "lapi/prctl.h"
45 TEST(prctl(PR_GET_CHILD_SUBREAPER, &get_val)); in check_get_subreaper()
47 tst_res(TFAIL | TTERRNO, "prctl(PR_GET_CHILD_SUBREAPER) failed"); in check_get_subreaper()
52 tst_res(TPASS, "prctl(PR_GET_CHILD_SUBREAPER) got expected %d", in check_get_subreaper()
55 tst_res(TFAIL, "prctl(PR_GET_CHILD_SUBREAPER) got %d, expected %d", in check_get_subreaper()
68 TEST(prctl(PR_SET_CHILD_SUBREAPER, 1)); in verify_prctl()
72 "prctl() does in verify_prctl()
[all...]
/third_party/musl/libc-test/src/functionalext/supplement/linux/linux_gtest/
H A Dlinux_prctl_test.cpp3 #include <sys/prctl.h>
14 * @tc.desc: This test verifies that after calling the prctl function to set the thread name, the thread name is
15 * obtained by calling the prctl function and compared with the set thread name to ensure that the function of
22 int setResult = prctl(PR_SET_NAME, static_cast<const void*>(threadName)); in HWTEST_F()
26 int getResult = prctl(PR_GET_NAME, static_cast<void*>(buffer)); in HWTEST_F()
/kernel/linux/linux-6.6/tools/testing/selftests/seccomp/
H A Dseccomp_benchmark.c17 #include <sys/prctl.h>
167 ret = prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0); in main()
171 ret = prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, &bitmap_prog); in main()
178 ret = prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, &bitmap_prog); in main()
185 ret = prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, &prog); in main()
192 ret = prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, &bitmap_prog); in main()
/kernel/linux/linux-5.10/samples/seccomp/
H A Ddropper.c10 * applications using prctl(PR_SET_SECCOMP, 2, ...).
25 #include <sys/prctl.h>
45 if (prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0)) { in install_filter()
46 perror("prctl(NO_NEW_PRIVS)"); in install_filter()
49 if (prctl(PR_SET_SECCOMP, 2, &prog)) { in install_filter()
50 perror("prctl(PR_SET_SECCOMP)"); in install_filter()
/kernel/linux/linux-6.6/samples/seccomp/
H A Ddropper.c10 * applications using prctl(PR_SET_SECCOMP, 2, ...).
25 #include <sys/prctl.h>
49 if (prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0)) { in install_filter()
50 perror("prctl(NO_NEW_PRIVS)"); in install_filter()
53 if (prctl(PR_SET_SECCOMP, 2, &prog)) { in install_filter()
54 perror("prctl(PR_SET_SECCOMP)"); in install_filter()
/kernel/linux/linux-5.10/tools/testing/selftests/seccomp/
H A Dseccomp_benchmark.c13 #include <sys/prctl.h>
101 ret = prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0); in main()
105 ret = prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, &prog); in main()
115 ret = prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, &prog); in main()
/third_party/musl/libc-test/src/functionalext/unittest/
H A Dunit_test_mock_fatal_message.c15 #include <sys/prctl.h>
18 int prctl(int op, ...) in prctl() function
/kernel/linux/linux-5.10/tools/testing/selftests/powerpc/pmu/
H A Dper_event_excludes.c13 #include <sys/prctl.h>
74 prctl(PR_TASK_PERF_EVENTS_ENABLE); in per_event_excludes()
80 prctl(PR_TASK_PERF_EVENTS_DISABLE); in per_event_excludes()
/kernel/linux/linux-6.6/tools/testing/selftests/arm64/signal/testcases/
H A Dssve_regs.c11 #include <sys/prctl.h>
31 vl = prctl(PR_SME_SET_VL, vq * 16); in sme_get_vls()
72 ret = prctl(PR_SME_SET_VL, vl); in do_one_sme_vl()
H A Dsve_regs.c11 #include <sys/prctl.h>
31 vl = prctl(PR_SVE_SET_VL, vq * 16); in sve_get_vls()
67 if (prctl(PR_SVE_SET_VL, vl) == -1) { in do_one_sve_vl()
H A Dza_regs.c11 #include <sys/prctl.h>
31 vl = prctl(PR_SME_SET_VL, vq * 16); in sme_get_vls()
73 if (prctl(PR_SME_SET_VL, vl) != vl) { in do_one_sme_vl()
H A Dza_no_regs.c11 #include <sys/prctl.h>
31 vl = prctl(PR_SME_SET_VL, vq * 16); in sme_get_vls()
61 if (prctl(PR_SME_SET_VL, vl) != vl) { in do_one_sme_vl()
/kernel/linux/linux-6.6/tools/testing/selftests/arm64/mte/
H A Dcheck_prctl.c9 #include <sys/prctl.h>
19 ret = prctl(PR_SET_TAGGED_ADDR_CTRL, val, 0, 0, 0); in set_tagged_addr_ctrl()
30 ret = prctl(PR_GET_TAGGED_ADDR_CTRL, 0, 0, 0, 0); in get_tagged_addr_ctrl()
/kernel/linux/linux-6.6/tools/testing/selftests/powerpc/pmu/
H A Dper_event_excludes.c13 #include <sys/prctl.h>
74 prctl(PR_TASK_PERF_EVENTS_ENABLE); in per_event_excludes()
80 prctl(PR_TASK_PERF_EVENTS_DISABLE); in per_event_excludes()
/third_party/pulseaudio/src/pulsecore/
H A Dthread-posix.c30 #include <sys/prctl.h>
71 prctl(PR_SET_NAME, t->name); in internal_thread_func()
184 prctl(PR_SET_NAME, name); in pa_thread_set_name()
197 if (prctl(PR_GET_NAME, t->name) >= 0) in pa_thread_get_name()
/third_party/libfuse/util/
H A Dmount.fuse.c22 #include <sys/prctl.h>
189 if (prctl(PR_SET_SECUREBITS, in drop_and_lock_capabilities()
203 int cap_status = prctl(PR_CAPBSET_READ, cap); in drop_and_lock_capabilities()
217 if (prctl(PR_CAPBSET_DROP, cap) == -1) { in drop_and_lock_capabilities()
228 if (prctl(PR_SET_NO_NEW_PRIVS, 1, 0, 0, 0) == -1) { in drop_and_lock_capabilities()
398 if (prctl(PR_SET_SECUREBITS, in main()
/third_party/musl/porting/linux/user/src/linux/
H A Dprctl.c1 #include <sys/prctl.h>
12 int prctl(int op, ...) in __libc_prctl()

Completed in 11 milliseconds

12345678910>>...15